"""{{ repository_name }} repository interface for {{ module_name }} module."""
from abc import ABC, abstractmethod
from typing import List, Optional
from ..entities.{{ entity_file }} import {{ EntityName }}


class {{ RepositoryName }}Repository(ABC):
    """Abstract repository interface for {{ entity_name }} operations.
    
    This is an abstract base class that enforces implementation of all methods
    in concrete repository classes.
    """
    
    @abstractmethod
    async def get_by_id(self, id: str) -> Optional[{{ EntityName }}]:
        """Retrieve {{ entity_name }} by ID.
        
        Args:
            id: The unique identifier of the {{ entity_name }}
            
        Returns:
            The {{ entity_name }} entity if found, None otherwise
        """
        pass
    
    @abstractmethod
    async def save(self, entity: {{ EntityName }}) -> {{ EntityName }}:
        """Save {{ entity_name }} entity.
        
        Args:
            entity: The {{ entity_name }} entity to save
            
        Returns:
            The saved {{ entity_name }} entity with updated fields
        """
        pass
    
    @abstractmethod
    async def delete(self, id: str) -> bool:
        """Delete {{ entity_name }} by ID.
        
        Args:
            id: The unique identifier of the {{ entity_name }} to delete
            
        Returns:
            True if deletion was successful, False otherwise
        """
        pass
    
    @abstractmethod
    async def list_all(self) -> List[{{ EntityName }}]:
        """List all {{ entity_name }} entities.
        
        Returns:
            List of all {{ entity_name }} entities
        """
        pass