# @generated by protoc-gen-mypy.py.  Do not edit!
# mypy: disable-error-code=override
from google.protobuf.message import (  # type: ignore
    Message,
)

from typing import (
    Iterable,
    List,
    Optional as OptionalType,
    Tuple,
    cast,
)

from google.protobuf.internal.containers import (  # type: ignore
    RepeatedCompositeFieldContainer,
    RepeatedScalarFieldContainer,
)

from onnx.onnx_ml_pb2 import (
    SparseTensorProto,
    TensorProto,
)

class SequenceProto(Message):
    class DataType(int):
        @classmethod
        def Name(cls, number: int) -> str: ...
        @classmethod
        def Value(cls, name: str) -> int: ...
        @classmethod
        def keys(cls) -> List[str]: ...
        @classmethod
        def values(cls) -> List[int]: ...
        @classmethod
        def items(cls) -> List[Tuple[str, int]]: ...
    UNDEFINED = cast(DataType, 0)
    TENSOR = cast(DataType, 1)
    SPARSE_TENSOR = cast(DataType, 2)
    SEQUENCE = cast(DataType, 3)
    MAP = cast(DataType, 4)
    OPTIONAL = cast(DataType, 5)
    
    name = ... # type: str
    elem_type = ... # type: int
    
    @property
    def tensor_values(self) -> RepeatedCompositeFieldContainer[TensorProto]: ...
    
    @property
    def sparse_tensor_values(self) -> RepeatedCompositeFieldContainer[SparseTensorProto]: ...
    
    @property
    def sequence_values(self) -> RepeatedCompositeFieldContainer[SequenceProto]: ...
    
    @property
    def map_values(self) -> RepeatedCompositeFieldContainer[MapProto]: ...
    
    @property
    def optional_values(self) -> RepeatedCompositeFieldContainer[OptionalProto]: ...
    
    def __init__(self,
        name : OptionalType[str] = None,
        elem_type : OptionalType[int] = None,
        tensor_values : OptionalType[Iterable[TensorProto]] = None,
        sparse_tensor_values : OptionalType[Iterable[SparseTensorProto]] = None,
        sequence_values : OptionalType[Iterable[SequenceProto]] = None,
        map_values : OptionalType[Iterable[MapProto]] = None,
        optional_values : OptionalType[Iterable[OptionalProto]] = None,
        ) -> None: ...
    @classmethod
    def FromString(cls, s: bytes) -> SequenceProto: ...
    def MergeFrom(self, other_msg: Message) -> None: ...
    def CopyFrom(self, other_msg: Message) -> None: ...

class MapProto(Message):
    name = ... # type: str
    key_type = ... # type: int
    keys = ... # type: RepeatedScalarFieldContainer[int]
    string_keys = ... # type: RepeatedScalarFieldContainer[bytes]
    
    @property
    def values(self) -> SequenceProto: ...
    
    def __init__(self,
        name : OptionalType[str] = None,
        key_type : OptionalType[int] = None,
        keys : OptionalType[Iterable[int]] = None,
        string_keys : OptionalType[Iterable[bytes]] = None,
        values : OptionalType[SequenceProto] = None,
        ) -> None: ...
    @classmethod
    def FromString(cls, s: bytes) -> MapProto: ...
    def MergeFrom(self, other_msg: Message) -> None: ...
    def CopyFrom(self, other_msg: Message) -> None: ...

class OptionalProto(Message):
    class DataType(int):
        @classmethod
        def Name(cls, number: int) -> str: ...
        @classmethod
        def Value(cls, name: str) -> int: ...
        @classmethod
        def keys(cls) -> List[str]: ...
        @classmethod
        def values(cls) -> List[int]: ...
        @classmethod
        def items(cls) -> List[Tuple[str, int]]: ...
    UNDEFINED = cast(DataType, 0)
    TENSOR = cast(DataType, 1)
    SPARSE_TENSOR = cast(DataType, 2)
    SEQUENCE = cast(DataType, 3)
    MAP = cast(DataType, 4)
    OPTIONAL = cast(DataType, 5)
    
    name = ... # type: str
    elem_type = ... # type: int
    
    @property
    def tensor_value(self) -> TensorProto: ...
    
    @property
    def sparse_tensor_value(self) -> SparseTensorProto: ...
    
    @property
    def sequence_value(self) -> SequenceProto: ...
    
    @property
    def map_value(self) -> MapProto: ...
    
    @property
    def optional_value(self) -> OptionalProto: ...
    
    def __init__(self,
        name : OptionalType[str] = None,
        elem_type : OptionalType[int] = None,
        tensor_value : OptionalType[TensorProto] = None,
        sparse_tensor_value : OptionalType[SparseTensorProto] = None,
        sequence_value : OptionalType[SequenceProto] = None,
        map_value : OptionalType[MapProto] = None,
        optional_value : OptionalType[OptionalProto] = None,
        ) -> None: ...
    @classmethod
    def FromString(cls, s: bytes) -> OptionalProto: ...
    def MergeFrom(self, other_msg: Message) -> None: ...
    def CopyFrom(self, other_msg: Message) -> None: ...
