"""Base writer interface for output data.""" from abc import ABC, abstractmethod from typing import Any class BaseWriter(ABC): """Base class for data writers.""" @abstractmethod def write(self, data: Any) -> bool: """Write data to output destination.""" pass @abstractmethod def close(self): """Close writer and cleanup resources.""" pass @abstractmethod def is_ready(self) -> bool: """Check if writer is ready for writing.""" pass