Skip to main content

A simple json repository

Project description

json_repository

travis build Pypi Pypi - downloads month

Install

https://pypi.org/project/json-repository/ pip install json-repository

Examples

You can also go to tests to check a good how-to!

Creating custom repository

class Foo(object):
    foo = None
    bar = None
    id = None

class FoobarRepository(BaseJsonRepository):
  def __init__(self):
    super(FoobarRepository, self).__init__(Foo)

using created repository

  with FoobarRepository() as repo:
    for entity in repo.get_all():
      repo.delete(entity)
    repo.context.commit()

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Files for json-repository, version 0.2.0
Filename, size File type Python version Upload date Hashes
Filename, size json_repository-0.2.0-py3-none-any.whl (18.0 kB) File type Wheel Python version py3 Upload date Hashes View hashes
Filename, size json_repository-0.2.0.tar.gz (3.5 kB) File type Source Python version None Upload date Hashes View hashes

Supported by

Elastic Elastic Search Pingdom Pingdom Monitoring Google Google BigQuery Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN DigiCert DigiCert EV certificate StatusPage StatusPage Status page