"""
@generated by mypy-protobuf.  Do not edit manually!
isort:skip_file
"""
import builtins
import google.protobuf.descriptor
import google.protobuf.internal.containers
import google.protobuf.message
import typing
import typing_extensions

DESCRIPTOR: google.protobuf.descriptor.FileDescriptor

class P4Data(google.protobuf.message.Message):
    DESCRIPTOR: google.protobuf.descriptor.Descriptor
    BITSTRING_FIELD_NUMBER: builtins.int
    VARBIT_FIELD_NUMBER: builtins.int
    BOOL_FIELD_NUMBER: builtins.int
    TUPLE_FIELD_NUMBER: builtins.int
    STRUCT_FIELD_NUMBER: builtins.int
    HEADER_FIELD_NUMBER: builtins.int
    HEADER_UNION_FIELD_NUMBER: builtins.int
    HEADER_STACK_FIELD_NUMBER: builtins.int
    HEADER_UNION_STACK_FIELD_NUMBER: builtins.int
    ENUM_FIELD_NUMBER: builtins.int
    ERROR_FIELD_NUMBER: builtins.int
    ENUM_VALUE_FIELD_NUMBER: builtins.int
    bitstring: builtins.bytes
    """for bit<W>, int<W>"""

    @property
    def varbit(self) -> global___P4Varbit:
        """for varbit<W>"""
        pass
    bool: builtins.bool
    @property
    def tuple(self) -> global___P4StructLike: ...
    @property
    def struct(self) -> global___P4StructLike: ...
    @property
    def header(self) -> global___P4Header: ...
    @property
    def header_union(self) -> global___P4HeaderUnion: ...
    @property
    def header_stack(self) -> global___P4HeaderStack: ...
    @property
    def header_union_stack(self) -> global___P4HeaderUnionStack: ...
    enum: typing.Text
    """safe (non-serializable) enums only"""

    error: typing.Text
    enum_value: builtins.bytes
    """serializable enums only"""

    def __init__(self,
        *,
        bitstring: builtins.bytes = ...,
        varbit: typing.Optional[global___P4Varbit] = ...,
        bool: builtins.bool = ...,
        tuple: typing.Optional[global___P4StructLike] = ...,
        struct: typing.Optional[global___P4StructLike] = ...,
        header: typing.Optional[global___P4Header] = ...,
        header_union: typing.Optional[global___P4HeaderUnion] = ...,
        header_stack: typing.Optional[global___P4HeaderStack] = ...,
        header_union_stack: typing.Optional[global___P4HeaderUnionStack] = ...,
        enum: typing.Text = ...,
        error: typing.Text = ...,
        enum_value: builtins.bytes = ...,
        ) -> None: ...
    def HasField(self, field_name: typing_extensions.Literal["bitstring",b"bitstring","bool",b"bool","data",b"data","enum",b"enum","enum_value",b"enum_value","error",b"error","header",b"header","header_stack",b"header_stack","header_union",b"header_union","header_union_stack",b"header_union_stack","struct",b"struct","tuple",b"tuple","varbit",b"varbit"]) -> builtins.bool: ...
    def ClearField(self, field_name: typing_extensions.Literal["bitstring",b"bitstring","bool",b"bool","data",b"data","enum",b"enum","enum_value",b"enum_value","error",b"error","header",b"header","header_stack",b"header_stack","header_union",b"header_union","header_union_stack",b"header_union_stack","struct",b"struct","tuple",b"tuple","varbit",b"varbit"]) -> None: ...
    def WhichOneof(self, oneof_group: typing_extensions.Literal["data",b"data"]) -> typing.Optional[typing_extensions.Literal["bitstring","varbit","bool","tuple","struct","header","header_union","header_stack","header_union_stack","enum","error","enum_value"]]: ...
global___P4Data = P4Data

class P4Varbit(google.protobuf.message.Message):
    DESCRIPTOR: google.protobuf.descriptor.Descriptor
    BITSTRING_FIELD_NUMBER: builtins.int
    BITWIDTH_FIELD_NUMBER: builtins.int
    bitstring: builtins.bytes
    bitwidth: builtins.int
    """dynamic bitwidth of the field"""

    def __init__(self,
        *,
        bitstring: builtins.bytes = ...,
        bitwidth: builtins.int = ...,
        ) -> None: ...
    def ClearField(self, field_name: typing_extensions.Literal["bitstring",b"bitstring","bitwidth",b"bitwidth"]) -> None: ...
global___P4Varbit = P4Varbit

class P4StructLike(google.protobuf.message.Message):
    DESCRIPTOR: google.protobuf.descriptor.Descriptor
    MEMBERS_FIELD_NUMBER: builtins.int
    @property
    def members(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___P4Data]: ...
    def __init__(self,
        *,
        members: typing.Optional[typing.Iterable[global___P4Data]] = ...,
        ) -> None: ...
    def ClearField(self, field_name: typing_extensions.Literal["members",b"members"]) -> None: ...
global___P4StructLike = P4StructLike

class P4Header(google.protobuf.message.Message):
    DESCRIPTOR: google.protobuf.descriptor.Descriptor
    IS_VALID_FIELD_NUMBER: builtins.int
    BITSTRINGS_FIELD_NUMBER: builtins.int
    is_valid: builtins.bool
    """If the header is invalid (is_valid is "false"), then the bitstrings
    repeated field must be empty.
    """

    @property
    def bitstrings(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.bytes]: ...
    def __init__(self,
        *,
        is_valid: builtins.bool = ...,
        bitstrings: typing.Optional[typing.Iterable[builtins.bytes]] = ...,
        ) -> None: ...
    def ClearField(self, field_name: typing_extensions.Literal["bitstrings",b"bitstrings","is_valid",b"is_valid"]) -> None: ...
global___P4Header = P4Header

class P4HeaderUnion(google.protobuf.message.Message):
    DESCRIPTOR: google.protobuf.descriptor.Descriptor
    VALID_HEADER_NAME_FIELD_NUMBER: builtins.int
    VALID_HEADER_FIELD_NUMBER: builtins.int
    valid_header_name: typing.Text
    """An empty string indicates that none of the union members are valid and
    valid_header must therefore be unset.
    """

    @property
    def valid_header(self) -> global___P4Header: ...
    def __init__(self,
        *,
        valid_header_name: typing.Text = ...,
        valid_header: typing.Optional[global___P4Header] = ...,
        ) -> None: ...
    def HasField(self, field_name: typing_extensions.Literal["valid_header",b"valid_header"]) -> builtins.bool: ...
    def ClearField(self, field_name: typing_extensions.Literal["valid_header",b"valid_header","valid_header_name",b"valid_header_name"]) -> None: ...
global___P4HeaderUnion = P4HeaderUnion

class P4HeaderStack(google.protobuf.message.Message):
    DESCRIPTOR: google.protobuf.descriptor.Descriptor
    ENTRIES_FIELD_NUMBER: builtins.int
    @property
    def entries(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___P4Header]:
        """The length of this repeated field must always be equal to the compile-time
        size of the header stack, which is specified in P4Info.
        """
        pass
    def __init__(self,
        *,
        entries: typing.Optional[typing.Iterable[global___P4Header]] = ...,
        ) -> None: ...
    def ClearField(self, field_name: typing_extensions.Literal["entries",b"entries"]) -> None: ...
global___P4HeaderStack = P4HeaderStack

class P4HeaderUnionStack(google.protobuf.message.Message):
    DESCRIPTOR: google.protobuf.descriptor.Descriptor
    ENTRIES_FIELD_NUMBER: builtins.int
    @property
    def entries(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___P4HeaderUnion]:
        """The length of this repeated field must always be equal to the compile-time
        size of the header union stack, which is specified in P4Info.
        """
        pass
    def __init__(self,
        *,
        entries: typing.Optional[typing.Iterable[global___P4HeaderUnion]] = ...,
        ) -> None: ...
    def ClearField(self, field_name: typing_extensions.Literal["entries",b"entries"]) -> None: ...
global___P4HeaderUnionStack = P4HeaderUnionStack
