Metadata-Version: 2.1
Name: pylocaldatabase
Version: 1.0.2
Summary: A package to simplify the use of json as a way to store data in Python.
Home-page: https://github.com/fortmea/python-local-database
Author: João Walter Amadeu
Author-email: joao.amadeu@unifio.edu.br
Project-URL: Bug Tracker, https://github.com/fortmea/python-local-database/issues
Classifier: Programming Language :: Python :: 3
Classifier: License :: OSI Approved :: MIT License
Classifier: Operating System :: OS Independent
Requires-Python: >=3.0
Description-Content-Type: text/markdown
License-File: LICENSE

# Python Local Database

A python package made to simplify the use of json as a mean to organize and store data in python.

## Installation

Use the package manager [pip](https://pip.pypa.io/en/stable/) to install Python Local Database.

```bash
pip install pylocaldatabase
```

Release history and file downloads can be found [on the project's pypi page](https://pypi.org/project/pylocaldatabase/).

## Usage

```python
from pylocaldatabase import pylocaldatabase
# define database file and assign databasecontroller instance to var dbcontroll
dbcontroll = pylocaldatabase.databasecontroller(path="file.json")

# load data from file
dbcontroll.load()

# create database file 'file.json'
dbcontroll.makeDatabase()

# create document 
dbcontroll.insertDocument({}, "documentName")

# assign the document we created
document = dbcontroll.getDocument("documentName")

# insert Item to the document
document.insertItem("ItemName", {"Property":"Property Value"})

# read Item data
itemData = document.getItem("ItemName").get()

# save data 
dbcontroll.save()
```

## Contributing
Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.

Please make sure to update tests as appropriate.

## License
[MIT](https://choosealicense.com/licenses/mit/)
