"""Base protocol definitions for language handlers."""

from typing import Protocol, runtime_checkable


@runtime_checkable
class LanguageHandler(Protocol):
    """Protocol for language-specific handlers supporting multiple features.

    Handlers declare which features they support via boolean class attributes
    and implement the corresponding methods.
    """

    language: str

    supports_testgen: bool
    supports_optimizer: bool
    supports_code_repair: bool
    supports_jit_rewrite: bool
    supports_optimization_review: bool
    supports_explanations: bool
