16 lines
391 B
Python
16 lines
391 B
Python
from abc import ABC
|
|
|
|
from typing import Dict, Optional, List
|
|
|
|
|
|
class IDocumentStore(ABC):
|
|
|
|
async def save_to_db(self, collection: str, item: Dict, doc_id: Optional[str]) -> Optional[str]:
|
|
pass
|
|
|
|
async def get_all(self, collection: str) -> List[Dict]:
|
|
pass
|
|
|
|
async def get_doc_by_id(self, collection: str, doc_id: str) -> Optional[Dict]:
|
|
pass
|