# sage_setup: distribution = sagemath-objects
from collections.abc import Callable
from typing import Any, Optional

class DefaultConvertMap:
    def __init__(self, domain: Any, codomain: Any, category: Optional[Any] = None) -> None: ...
    def _repr_type(self) -> str: ...
    def _call_(self, x: Any) -> Any: ...
    def _call_with_args(self, x: Any, args: tuple = (), kwds: dict = {}) -> Any: ...

class DefaultConvertMap_unique(DefaultConvertMap):
    def _call_(self, x: Any) -> Any: ...
    def _call_with_args(self, x: Any, args: tuple = (), kwds: dict = {}) -> Any: ...

class NamedConvertMap:
    def __init__(self, domain: Any, codomain: Any, method_name: str) -> None: ...
    def _extra_slots(self) -> dict[str, Any]: ...
    def _update_slots(self, _slots: dict[str, Any]) -> None: ...
    def _call_(self, x: Any) -> Any: ...
    def _call_with_args(self, x: Any, args: tuple = (), kwds: dict = {}) -> Any: ...

class CallableConvertMap:
    def __init__(self, domain: Any, codomain: Any, func: Callable, parent_as_first_arg: Optional[bool] = None) -> None: ...
    def _extra_slots(self) -> dict[str, Any]: ...
    def _update_slots(self, _slots: dict[str, Any]) -> None: ...
    def _call_(self, x: Any) -> Any: ...
    def _call_with_args(self, x: Any, args: tuple = (), kwds: dict = {}) -> Any: ...

class CCallableConvertMap_class:
    def __init__(self, domain: Any, codomain: Any, name: Optional[str]) -> None: ...
    def _call_(self, x: Any) -> Any: ...
    def _repr_type(self) -> str: ...

def CCallableConvertMap(domain: Any, codomain: Any, func: Any, name: Optional[str]) -> CCallableConvertMap_class: ...

def _ccall_test_function(codomain: Any, x: Any) -> Any: ...

def test_CCallableConvertMap(domain: Any, name: Optional[str] = None) -> CCallableConvertMap_class: ...

class ListMorphism:
    def __init__(self, domain: Any, real_morphism: Any) -> None: ...
    def _extra_slots(self) -> dict[str, Any]: ...
    def _update_slots(self, _slots: dict[str, Any]) -> None: ...
    def _call_(self, x: Any) -> Any: ...
    def _call_with_args(self, x: Any, args: tuple = (), kwds: dict = {}) -> Any: ...

class TryMap:
    def __init__(self, morphism_preferred: Any, morphism_backup: Any, error_types: Optional[tuple] = None) -> None: ...
    def _extra_slots(self) -> dict[str, Any]: ...
    def _update_slots(self, _slots: dict[str, Any]) -> None: ...
    def _call_(self, x: Any) -> Any: ...
    def _call_with_args(self, x: Any, args: tuple = (), kwds: dict = {}) -> Any: ...
