from typing import Any
from typing import Optional

from . import attributes as attributes
from . import interfaces as interfaces
from .descriptor_props import SynonymProperty as SynonymProperty
from .properties import ColumnProperty as ColumnProperty
from .util import class_mapper as class_mapper
from .. import exc as exc
from .. import inspection as inspection
from .. import util as util

def add_class(classname: Any, cls: Any, decl_class_registry: Any) -> None: ...
def remove_class(
    classname: Any, cls: Any, decl_class_registry: Any
) -> None: ...

class _MultipleClassMarker:
    on_remove: Any = ...
    contents: Any = ...
    def __init__(
        self, classes: Any, on_remove: Optional[Any] = ...
    ) -> None: ...
    def remove_item(self, cls: Any) -> None: ...
    def __iter__(self) -> Any: ...
    def attempt_get(self, path: Any, key: Any): ...
    def add_item(self, item: Any) -> None: ...

class _ModuleMarker:
    parent: Any = ...
    name: Any = ...
    contents: Any = ...
    mod_ns: Any = ...
    path: Any = ...
    def __init__(self, name: Any, parent: Any) -> None: ...
    def __contains__(self, name: Any): ...
    def __getitem__(self, name: Any): ...
    def resolve_attr(self, key: Any): ...
    def get_module(self, name: Any): ...
    def add_class(self, name: Any, cls: Any): ...
    def remove_class(self, name: Any, cls: Any) -> None: ...

class _ModNS:
    def __init__(self, parent: Any) -> None: ...
    def __getattr__(self, key: Any): ...

class _GetColumns:
    cls: Any = ...
    def __init__(self, cls: Any) -> None: ...
    def __getattr__(self, key: Any): ...

class _GetTable:
    key: Any = ...
    metadata: Any = ...
    def __init__(self, key: Any, metadata: Any) -> None: ...
    def __getattr__(self, key: Any): ...

class _class_resolver:
    cls: Any = ...
    prop: Any = ...
    arg: Any = ...
    fallback: Any = ...
    favor_tables: Any = ...
    def __init__(
        self,
        cls: Any,
        prop: Any,
        fallback: Any,
        arg: Any,
        favor_tables: bool = ...,
    ) -> None: ...
    def __call__(self): ...
