recopytex/backend/repository/abstract_repository.py

24 lines
493 B
Python
Raw Normal View History

2022-12-21 13:10:04 +00:00
import abc
class AbstractRepository(abc.ABC):
@abc.abstractmethod
def add(self, element):
raise NotImplementedError
@abc.abstractmethod
2022-12-26 06:03:52 +00:00
def update(self, reference, element):
2022-12-21 13:10:04 +00:00
raise NotImplementedError
@abc.abstractmethod
def list(self):
raise NotImplementedError
@abc.abstractmethod
def get(self, reference):
raise NotImplementedError
@abc.abstractmethod
2022-12-26 06:03:52 +00:00
def delete(self, element):
2022-12-21 13:10:04 +00:00
raise NotImplementedError