Files
@ 4fce6b4feaa7
Branch filter:
Location: NPO-Accounting/experimental-accounting-api/accounting/storage/__init__.py - annotation
4fce6b4feaa7
1.1 KiB
text/x-python
[tests] Added bin/runtests
fc2c3a6b4339 fc2c3a6b4339 fc2c3a6b4339 fc2c3a6b4339 a0318ce82eca 124bd1706d79 02fc05aebdde 02fc05aebdde 124bd1706d79 124bd1706d79 124bd1706d79 a0318ce82eca a0318ce82eca 124bd1706d79 a0318ce82eca 124bd1706d79 a0318ce82eca 124bd1706d79 a0318ce82eca 124bd1706d79 a0318ce82eca 124bd1706d79 a0318ce82eca 124bd1706d79 a0318ce82eca 124bd1706d79 a0318ce82eca 124bd1706d79 a0318ce82eca 124bd1706d79 a0318ce82eca a0318ce82eca 751341c267ed 751341c267ed 751341c267ed 751341c267ed a0318ce82eca a0318ce82eca a0318ce82eca a0318ce82eca 02fc05aebdde 02fc05aebdde 02fc05aebdde 02fc05aebdde a0318ce82eca a0318ce82eca a0318ce82eca | # Part of accounting-api project:
# https://gitorious.org/conservancy/accounting-api
# License: AGPLv3-or-later
from abc import ABCMeta, abstractmethod
class Storage:
'''
ABC for accounting storage
'''
__metaclass__ = ABCMeta
def __init__(self, *args, **kw):
pass
@abstractmethod
def get_transactions(self, *args, **kw):
raise NotImplementedError
@abstractmethod
def get_transaction(self, *args, **kw):
raise NotImplementedError
@abstractmethod
def get_account(self, *args, **kw):
raise NotImplementedError
@abstractmethod
def get_accounts(self, *args, **kw):
raise NotImplementedError
@abstractmethod
def add_transaction(self, transaction):
raise NotImplementedError
@abstractmethod
def update_transaction(self, transaction):
raise NotImplementedError
@abstractmethod
def delete_transaction(self, transaction_id):
raise NotImplementedError
@abstractmethod
def reverse_transaction(self, transaction_id):
raise NotImplementedError
|