Re-organize directory structure (#4971)

See discussion in #2491

Co-authored-by: Ivan Levkivskyi <ilevkivskyi@dropbox.com>
This commit is contained in:
Ivan Levkivskyi
2021-01-27 12:00:39 +00:00
committed by GitHub
parent 869238e587
commit 16ae4c6120
1399 changed files with 601 additions and 97 deletions

View File

@@ -0,0 +1,3 @@
version = "0.1"
python2 = true
requires = ["types-futures", "types-typing-extensions"]

View File

View File

@@ -0,0 +1 @@
__version__: bytes

View File

@@ -0,0 +1,47 @@
"""
@generated by mypy-protobuf. Do not edit manually!
isort:skip_file
"""
from google.protobuf.descriptor import (
Descriptor as google___protobuf___descriptor___Descriptor,
FileDescriptor as google___protobuf___descriptor___FileDescriptor,
)
from google.protobuf.internal.well_known_types import (
Any as google___protobuf___internal___well_known_types___Any,
)
from google.protobuf.message import (
Message as google___protobuf___message___Message,
)
from typing import (
Optional as typing___Optional,
Text as typing___Text,
)
from typing_extensions import (
Literal as typing_extensions___Literal,
)
builtin___bool = bool
builtin___bytes = bytes
builtin___float = float
builtin___int = int
DESCRIPTOR: google___protobuf___descriptor___FileDescriptor = ...
class Any(google___protobuf___message___Message, google___protobuf___internal___well_known_types___Any):
DESCRIPTOR: google___protobuf___descriptor___Descriptor = ...
type_url: typing___Text = ...
value: builtin___bytes = ...
def __init__(self,
*,
type_url : typing___Optional[typing___Text] = None,
value : typing___Optional[builtin___bytes] = None,
) -> None: ...
def ClearField(self, field_name: typing_extensions___Literal[u"type_url",b"type_url",u"value",b"value"]) -> None: ...
type___Any = Any

View File

@@ -0,0 +1,114 @@
"""
@generated by mypy-protobuf. Do not edit manually!
isort:skip_file
"""
from google.protobuf.descriptor import (
Descriptor as google___protobuf___descriptor___Descriptor,
FileDescriptor as google___protobuf___descriptor___FileDescriptor,
)
from google.protobuf.internal.containers import (
RepeatedCompositeFieldContainer as google___protobuf___internal___containers___RepeatedCompositeFieldContainer,
)
from google.protobuf.message import (
Message as google___protobuf___message___Message,
)
from google.protobuf.source_context_pb2 import (
SourceContext as google___protobuf___source_context_pb2___SourceContext,
)
from google.protobuf.type_pb2 import (
Option as google___protobuf___type_pb2___Option,
SyntaxValue as google___protobuf___type_pb2___SyntaxValue,
)
from typing import (
Iterable as typing___Iterable,
Optional as typing___Optional,
Text as typing___Text,
)
from typing_extensions import (
Literal as typing_extensions___Literal,
)
builtin___bool = bool
builtin___bytes = bytes
builtin___float = float
builtin___int = int
DESCRIPTOR: google___protobuf___descriptor___FileDescriptor = ...
class Api(google___protobuf___message___Message):
DESCRIPTOR: google___protobuf___descriptor___Descriptor = ...
name: typing___Text = ...
version: typing___Text = ...
syntax: google___protobuf___type_pb2___SyntaxValue = ...
@property
def methods(self) -> google___protobuf___internal___containers___RepeatedCompositeFieldContainer[type___Method]: ...
@property
def options(self) -> google___protobuf___internal___containers___RepeatedCompositeFieldContainer[google___protobuf___type_pb2___Option]: ...
@property
def source_context(self) -> google___protobuf___source_context_pb2___SourceContext: ...
@property
def mixins(self) -> google___protobuf___internal___containers___RepeatedCompositeFieldContainer[type___Mixin]: ...
def __init__(self,
*,
name : typing___Optional[typing___Text] = None,
methods : typing___Optional[typing___Iterable[type___Method]] = None,
options : typing___Optional[typing___Iterable[google___protobuf___type_pb2___Option]] = None,
version : typing___Optional[typing___Text] = None,
source_context : typing___Optional[google___protobuf___source_context_pb2___SourceContext] = None,
mixins : typing___Optional[typing___Iterable[type___Mixin]] = None,
syntax : typing___Optional[google___protobuf___type_pb2___SyntaxValue] = None,
) -> None: ...
def HasField(self, field_name: typing_extensions___Literal[u"source_context",b"source_context"]) -> builtin___bool: ...
def ClearField(self, field_name: typing_extensions___Literal[u"methods",b"methods",u"mixins",b"mixins",u"name",b"name",u"options",b"options",u"source_context",b"source_context",u"syntax",b"syntax",u"version",b"version"]) -> None: ...
type___Api = Api
class Method(google___protobuf___message___Message):
DESCRIPTOR: google___protobuf___descriptor___Descriptor = ...
name: typing___Text = ...
request_type_url: typing___Text = ...
request_streaming: builtin___bool = ...
response_type_url: typing___Text = ...
response_streaming: builtin___bool = ...
syntax: google___protobuf___type_pb2___SyntaxValue = ...
@property
def options(self) -> google___protobuf___internal___containers___RepeatedCompositeFieldContainer[google___protobuf___type_pb2___Option]: ...
def __init__(self,
*,
name : typing___Optional[typing___Text] = None,
request_type_url : typing___Optional[typing___Text] = None,
request_streaming : typing___Optional[builtin___bool] = None,
response_type_url : typing___Optional[typing___Text] = None,
response_streaming : typing___Optional[builtin___bool] = None,
options : typing___Optional[typing___Iterable[google___protobuf___type_pb2___Option]] = None,
syntax : typing___Optional[google___protobuf___type_pb2___SyntaxValue] = None,
) -> None: ...
def ClearField(self, field_name: typing_extensions___Literal[u"name",b"name",u"options",b"options",u"request_streaming",b"request_streaming",u"request_type_url",b"request_type_url",u"response_streaming",b"response_streaming",u"response_type_url",b"response_type_url",u"syntax",b"syntax"]) -> None: ...
type___Method = Method
class Mixin(google___protobuf___message___Message):
DESCRIPTOR: google___protobuf___descriptor___Descriptor = ...
name: typing___Text = ...
root: typing___Text = ...
def __init__(self,
*,
name : typing___Optional[typing___Text] = None,
root : typing___Optional[typing___Text] = None,
) -> None: ...
def ClearField(self, field_name: typing_extensions___Literal[u"name",b"name",u"root",b"root"]) -> None: ...
type___Mixin = Mixin

View File

@@ -0,0 +1,136 @@
"""
@generated by mypy-protobuf. Do not edit manually!
isort:skip_file
"""
from google.protobuf.descriptor import (
Descriptor as google___protobuf___descriptor___Descriptor,
EnumDescriptor as google___protobuf___descriptor___EnumDescriptor,
FileDescriptor as google___protobuf___descriptor___FileDescriptor,
)
from google.protobuf.descriptor_pb2 import (
FileDescriptorProto as google___protobuf___descriptor_pb2___FileDescriptorProto,
GeneratedCodeInfo as google___protobuf___descriptor_pb2___GeneratedCodeInfo,
)
from google.protobuf.internal.containers import (
RepeatedCompositeFieldContainer as google___protobuf___internal___containers___RepeatedCompositeFieldContainer,
RepeatedScalarFieldContainer as google___protobuf___internal___containers___RepeatedScalarFieldContainer,
)
from google.protobuf.internal.enum_type_wrapper import (
_EnumTypeWrapper as google___protobuf___internal___enum_type_wrapper____EnumTypeWrapper,
)
from google.protobuf.message import (
Message as google___protobuf___message___Message,
)
from typing import (
Iterable as typing___Iterable,
NewType as typing___NewType,
Optional as typing___Optional,
Text as typing___Text,
cast as typing___cast,
)
from typing_extensions import (
Literal as typing_extensions___Literal,
)
builtin___bool = bool
builtin___bytes = bytes
builtin___float = float
builtin___int = int
DESCRIPTOR: google___protobuf___descriptor___FileDescriptor = ...
class Version(google___protobuf___message___Message):
DESCRIPTOR: google___protobuf___descriptor___Descriptor = ...
major: builtin___int = ...
minor: builtin___int = ...
patch: builtin___int = ...
suffix: typing___Text = ...
def __init__(self,
*,
major : typing___Optional[builtin___int] = None,
minor : typing___Optional[builtin___int] = None,
patch : typing___Optional[builtin___int] = None,
suffix : typing___Optional[typing___Text] = None,
) -> None: ...
def HasField(self, field_name: typing_extensions___Literal[u"major",b"major",u"minor",b"minor",u"patch",b"patch",u"suffix",b"suffix"]) -> builtin___bool: ...
def ClearField(self, field_name: typing_extensions___Literal[u"major",b"major",u"minor",b"minor",u"patch",b"patch",u"suffix",b"suffix"]) -> None: ...
type___Version = Version
class CodeGeneratorRequest(google___protobuf___message___Message):
DESCRIPTOR: google___protobuf___descriptor___Descriptor = ...
file_to_generate: google___protobuf___internal___containers___RepeatedScalarFieldContainer[typing___Text] = ...
parameter: typing___Text = ...
@property
def proto_file(self) -> google___protobuf___internal___containers___RepeatedCompositeFieldContainer[google___protobuf___descriptor_pb2___FileDescriptorProto]: ...
@property
def compiler_version(self) -> type___Version: ...
def __init__(self,
*,
file_to_generate : typing___Optional[typing___Iterable[typing___Text]] = None,
parameter : typing___Optional[typing___Text] = None,
proto_file : typing___Optional[typing___Iterable[google___protobuf___descriptor_pb2___FileDescriptorProto]] = None,
compiler_version : typing___Optional[type___Version] = None,
) -> None: ...
def HasField(self, field_name: typing_extensions___Literal[u"compiler_version",b"compiler_version",u"parameter",b"parameter"]) -> builtin___bool: ...
def ClearField(self, field_name: typing_extensions___Literal[u"compiler_version",b"compiler_version",u"file_to_generate",b"file_to_generate",u"parameter",b"parameter",u"proto_file",b"proto_file"]) -> None: ...
type___CodeGeneratorRequest = CodeGeneratorRequest
class CodeGeneratorResponse(google___protobuf___message___Message):
DESCRIPTOR: google___protobuf___descriptor___Descriptor = ...
FeatureValue = typing___NewType('FeatureValue', builtin___int)
type___FeatureValue = FeatureValue
Feature: _Feature
class _Feature(google___protobuf___internal___enum_type_wrapper____EnumTypeWrapper[CodeGeneratorResponse.FeatureValue]):
DESCRIPTOR: google___protobuf___descriptor___EnumDescriptor = ...
FEATURE_NONE = typing___cast(CodeGeneratorResponse.FeatureValue, 0)
FEATURE_PROTO3_OPTIONAL = typing___cast(CodeGeneratorResponse.FeatureValue, 1)
FEATURE_NONE = typing___cast(CodeGeneratorResponse.FeatureValue, 0)
FEATURE_PROTO3_OPTIONAL = typing___cast(CodeGeneratorResponse.FeatureValue, 1)
class File(google___protobuf___message___Message):
DESCRIPTOR: google___protobuf___descriptor___Descriptor = ...
name: typing___Text = ...
insertion_point: typing___Text = ...
content: typing___Text = ...
@property
def generated_code_info(self) -> google___protobuf___descriptor_pb2___GeneratedCodeInfo: ...
def __init__(self,
*,
name : typing___Optional[typing___Text] = None,
insertion_point : typing___Optional[typing___Text] = None,
content : typing___Optional[typing___Text] = None,
generated_code_info : typing___Optional[google___protobuf___descriptor_pb2___GeneratedCodeInfo] = None,
) -> None: ...
def HasField(self, field_name: typing_extensions___Literal[u"content",b"content",u"generated_code_info",b"generated_code_info",u"insertion_point",b"insertion_point",u"name",b"name"]) -> builtin___bool: ...
def ClearField(self, field_name: typing_extensions___Literal[u"content",b"content",u"generated_code_info",b"generated_code_info",u"insertion_point",b"insertion_point",u"name",b"name"]) -> None: ...
type___File = File
error: typing___Text = ...
supported_features: builtin___int = ...
@property
def file(self) -> google___protobuf___internal___containers___RepeatedCompositeFieldContainer[type___CodeGeneratorResponse.File]: ...
def __init__(self,
*,
error : typing___Optional[typing___Text] = None,
supported_features : typing___Optional[builtin___int] = None,
file : typing___Optional[typing___Iterable[type___CodeGeneratorResponse.File]] = None,
) -> None: ...
def HasField(self, field_name: typing_extensions___Literal[u"error",b"error",u"supported_features",b"supported_features"]) -> builtin___bool: ...
def ClearField(self, field_name: typing_extensions___Literal[u"error",b"error",u"file",b"file",u"supported_features",b"supported_features"]) -> None: ...
type___CodeGeneratorResponse = CodeGeneratorResponse

View File

@@ -0,0 +1,330 @@
from typing import Any
from .descriptor_pb2 import (
EnumOptions,
EnumValueOptions,
FieldOptions,
FileOptions,
MessageOptions,
MethodOptions,
OneofOptions,
ServiceOptions,
)
from .message import Message
class Error(Exception): ...
class TypeTransformationError(Error): ...
class DescriptorMetaclass(type):
def __instancecheck__(self, obj): ...
class DescriptorBase(metaclass=DescriptorMetaclass):
has_options: Any
def __init__(self, options, serialized_options, options_class_name) -> None: ...
def GetOptions(self): ...
class _NestedDescriptorBase(DescriptorBase):
name: Any
full_name: Any
file: Any
containing_type: Any
def __init__(
self,
options,
options_class_name,
name,
full_name,
file,
containing_type,
serialized_start=...,
serialized_end=...,
serialized_options=...,
) -> None: ...
def GetTopLevelContainingType(self): ...
def CopyToProto(self, proto): ...
class Descriptor(_NestedDescriptorBase):
def __new__(
cls,
name,
full_name,
filename,
containing_type,
fields,
nested_types,
enum_types,
extensions,
options=...,
serialized_options=...,
is_extendable=...,
extension_ranges=...,
oneofs=...,
file=...,
serialized_start=...,
serialized_end=...,
syntax=...,
): ...
fields: Any
fields_by_number: Any
fields_by_name: Any
nested_types: Any
nested_types_by_name: Any
enum_types: Any
enum_types_by_name: Any
enum_values_by_name: Any
extensions: Any
extensions_by_name: Any
is_extendable: Any
extension_ranges: Any
oneofs: Any
oneofs_by_name: Any
syntax: Any
def __init__(
self,
name,
full_name,
filename,
containing_type,
fields,
nested_types,
enum_types,
extensions,
options=...,
serialized_options=...,
is_extendable=...,
extension_ranges=...,
oneofs=...,
file=...,
serialized_start=...,
serialized_end=...,
syntax=...,
) -> None: ...
def EnumValueName(self, enum, value): ...
def CopyToProto(self, proto): ...
def GetOptions(self) -> MessageOptions: ...
class FieldDescriptor(DescriptorBase):
TYPE_DOUBLE: Any
TYPE_FLOAT: Any
TYPE_INT64: Any
TYPE_UINT64: Any
TYPE_INT32: Any
TYPE_FIXED64: Any
TYPE_FIXED32: Any
TYPE_BOOL: Any
TYPE_STRING: Any
TYPE_GROUP: Any
TYPE_MESSAGE: Any
TYPE_BYTES: Any
TYPE_UINT32: Any
TYPE_ENUM: Any
TYPE_SFIXED32: Any
TYPE_SFIXED64: Any
TYPE_SINT32: Any
TYPE_SINT64: Any
MAX_TYPE: Any
CPPTYPE_INT32: Any
CPPTYPE_INT64: Any
CPPTYPE_UINT32: Any
CPPTYPE_UINT64: Any
CPPTYPE_DOUBLE: Any
CPPTYPE_FLOAT: Any
CPPTYPE_BOOL: Any
CPPTYPE_ENUM: Any
CPPTYPE_STRING: Any
CPPTYPE_MESSAGE: Any
MAX_CPPTYPE: Any
LABEL_OPTIONAL: Any
LABEL_REQUIRED: Any
LABEL_REPEATED: Any
MAX_LABEL: Any
MAX_FIELD_NUMBER: Any
FIRST_RESERVED_FIELD_NUMBER: Any
LAST_RESERVED_FIELD_NUMBER: Any
def __new__(
cls,
name,
full_name,
index,
number,
type,
cpp_type,
label,
default_value,
message_type,
enum_type,
containing_type,
is_extension,
extension_scope,
options=...,
serialized_options=...,
file=...,
has_default_value=...,
containing_oneof=...,
): ...
name: Any
full_name: Any
index: Any
number: Any
type: Any
cpp_type: Any
label: Any
has_default_value: Any
default_value: Any
containing_type: Any
message_type: Any
enum_type: Any
is_extension: Any
extension_scope: Any
containing_oneof: Any
def __init__(
self,
name,
full_name,
index,
number,
type,
cpp_type,
label,
default_value,
message_type,
enum_type,
containing_type,
is_extension,
extension_scope,
options=...,
serialized_options=...,
file=...,
has_default_value=...,
containing_oneof=...,
) -> None: ...
@staticmethod
def ProtoTypeToCppProtoType(proto_type): ...
def GetOptions(self) -> FieldOptions: ...
class EnumDescriptor(_NestedDescriptorBase):
def __new__(
cls,
name,
full_name,
filename,
values,
containing_type=...,
options=...,
serialized_options=...,
file=...,
serialized_start=...,
serialized_end=...,
): ...
values: Any
values_by_name: Any
values_by_number: Any
def __init__(
self,
name,
full_name,
filename,
values,
containing_type=...,
options=...,
serialized_options=...,
file=...,
serialized_start=...,
serialized_end=...,
) -> None: ...
def CopyToProto(self, proto): ...
def GetOptions(self) -> EnumOptions: ...
class EnumValueDescriptor(DescriptorBase):
def __new__(cls, name, index, number, type=..., options=..., serialized_options=...): ...
name: Any
index: Any
number: Any
type: Any
def __init__(self, name, index, number, type=..., options=..., serialized_options=...) -> None: ...
def GetOptions(self) -> EnumValueOptions: ...
class OneofDescriptor:
def __new__(cls, name, full_name, index, containing_type, fields): ...
name: Any
full_name: Any
index: Any
containing_type: Any
fields: Any
def __init__(self, name, full_name, index, containing_type, fields) -> None: ...
def GetOptions(self) -> OneofOptions: ...
class ServiceDescriptor(_NestedDescriptorBase):
index: Any
methods: Any
methods_by_name: Any
def __init__(
self,
name,
full_name,
index,
methods,
options=...,
serialized_options=...,
file=...,
serialized_start=...,
serialized_end=...,
) -> None: ...
def FindMethodByName(self, name): ...
def CopyToProto(self, proto): ...
def GetOptions(self) -> ServiceOptions: ...
class MethodDescriptor(DescriptorBase):
name: Any
full_name: Any
index: Any
containing_service: Any
input_type: Any
output_type: Any
def __init__(
self, name, full_name, index, containing_service, input_type, output_type, options=..., serialized_options=...
) -> None: ...
def GetOptions(self) -> MethodOptions: ...
class FileDescriptor(DescriptorBase):
def __new__(
cls,
name,
package,
options=...,
serialized_options=...,
serialized_pb=...,
dependencies=...,
public_dependencies=...,
syntax=...,
pool=...,
): ...
_options: Any
pool: Any
message_types_by_name: Any
name: Any
package: Any
syntax: Any
serialized_pb: Any
enum_types_by_name: Any
extensions_by_name: Any
services_by_name: Any
dependencies: Any
public_dependencies: Any
def __init__(
self,
name,
package,
options=...,
serialized_options=...,
serialized_pb=...,
dependencies=...,
public_dependencies=...,
syntax=...,
pool=...,
) -> None: ...
def CopyToProto(self, proto): ...
def GetOptions(self) -> FileOptions: ...
def MakeDescriptor(desc_proto, package=..., build_file_if_cpp=..., syntax=...): ...
def _ParseOptions(message: Message, string: bytes) -> Message: ...

View File

@@ -0,0 +1,734 @@
"""
@generated by mypy-protobuf. Do not edit manually!
isort:skip_file
"""
from google.protobuf.descriptor import (
Descriptor as google___protobuf___descriptor___Descriptor,
EnumDescriptor as google___protobuf___descriptor___EnumDescriptor,
FileDescriptor as google___protobuf___descriptor___FileDescriptor,
)
from google.protobuf.internal.containers import (
RepeatedCompositeFieldContainer as google___protobuf___internal___containers___RepeatedCompositeFieldContainer,
RepeatedScalarFieldContainer as google___protobuf___internal___containers___RepeatedScalarFieldContainer,
)
from google.protobuf.internal.enum_type_wrapper import (
_EnumTypeWrapper as google___protobuf___internal___enum_type_wrapper____EnumTypeWrapper,
)
from google.protobuf.message import (
Message as google___protobuf___message___Message,
)
from typing import (
Iterable as typing___Iterable,
NewType as typing___NewType,
Optional as typing___Optional,
Text as typing___Text,
cast as typing___cast,
)
from typing_extensions import (
Literal as typing_extensions___Literal,
)
builtin___bool = bool
builtin___bytes = bytes
builtin___float = float
builtin___int = int
DESCRIPTOR: google___protobuf___descriptor___FileDescriptor = ...
class FileDescriptorSet(google___protobuf___message___Message):
DESCRIPTOR: google___protobuf___descriptor___Descriptor = ...
@property
def file(self) -> google___protobuf___internal___containers___RepeatedCompositeFieldContainer[type___FileDescriptorProto]: ...
def __init__(self,
*,
file : typing___Optional[typing___Iterable[type___FileDescriptorProto]] = None,
) -> None: ...
def ClearField(self, field_name: typing_extensions___Literal[u"file",b"file"]) -> None: ...
type___FileDescriptorSet = FileDescriptorSet
class FileDescriptorProto(google___protobuf___message___Message):
DESCRIPTOR: google___protobuf___descriptor___Descriptor = ...
name: typing___Text = ...
package: typing___Text = ...
dependency: google___protobuf___internal___containers___RepeatedScalarFieldContainer[typing___Text] = ...
public_dependency: google___protobuf___internal___containers___RepeatedScalarFieldContainer[builtin___int] = ...
weak_dependency: google___protobuf___internal___containers___RepeatedScalarFieldContainer[builtin___int] = ...
syntax: typing___Text = ...
@property
def message_type(self) -> google___protobuf___internal___containers___RepeatedCompositeFieldContainer[type___DescriptorProto]: ...
@property
def enum_type(self) -> google___protobuf___internal___containers___RepeatedCompositeFieldContainer[type___EnumDescriptorProto]: ...
@property
def service(self) -> google___protobuf___internal___containers___RepeatedCompositeFieldContainer[type___ServiceDescriptorProto]: ...
@property
def extension(self) -> google___protobuf___internal___containers___RepeatedCompositeFieldContainer[type___FieldDescriptorProto]: ...
@property
def options(self) -> type___FileOptions: ...
@property
def source_code_info(self) -> type___SourceCodeInfo: ...
def __init__(self,
*,
name : typing___Optional[typing___Text] = None,
package : typing___Optional[typing___Text] = None,
dependency : typing___Optional[typing___Iterable[typing___Text]] = None,
public_dependency : typing___Optional[typing___Iterable[builtin___int]] = None,
weak_dependency : typing___Optional[typing___Iterable[builtin___int]] = None,
message_type : typing___Optional[typing___Iterable[type___DescriptorProto]] = None,
enum_type : typing___Optional[typing___Iterable[type___EnumDescriptorProto]] = None,
service : typing___Optional[typing___Iterable[type___ServiceDescriptorProto]] = None,
extension : typing___Optional[typing___Iterable[type___FieldDescriptorProto]] = None,
options : typing___Optional[type___FileOptions] = None,
source_code_info : typing___Optional[type___SourceCodeInfo] = None,
syntax : typing___Optional[typing___Text] = None,
) -> None: ...
def HasField(self, field_name: typing_extensions___Literal[u"name",b"name",u"options",b"options",u"package",b"package",u"source_code_info",b"source_code_info",u"syntax",b"syntax"]) -> builtin___bool: ...
def ClearField(self, field_name: typing_extensions___Literal[u"dependency",b"dependency",u"enum_type",b"enum_type",u"extension",b"extension",u"message_type",b"message_type",u"name",b"name",u"options",b"options",u"package",b"package",u"public_dependency",b"public_dependency",u"service",b"service",u"source_code_info",b"source_code_info",u"syntax",b"syntax",u"weak_dependency",b"weak_dependency"]) -> None: ...
type___FileDescriptorProto = FileDescriptorProto
class DescriptorProto(google___protobuf___message___Message):
DESCRIPTOR: google___protobuf___descriptor___Descriptor = ...
class ExtensionRange(google___protobuf___message___Message):
DESCRIPTOR: google___protobuf___descriptor___Descriptor = ...
start: builtin___int = ...
end: builtin___int = ...
@property
def options(self) -> type___ExtensionRangeOptions: ...
def __init__(self,
*,
start : typing___Optional[builtin___int] = None,
end : typing___Optional[builtin___int] = None,
options : typing___Optional[type___ExtensionRangeOptions] = None,
) -> None: ...
def HasField(self, field_name: typing_extensions___Literal[u"end",b"end",u"options",b"options",u"start",b"start"]) -> builtin___bool: ...
def ClearField(self, field_name: typing_extensions___Literal[u"end",b"end",u"options",b"options",u"start",b"start"]) -> None: ...
type___ExtensionRange = ExtensionRange
class ReservedRange(google___protobuf___message___Message):
DESCRIPTOR: google___protobuf___descriptor___Descriptor = ...
start: builtin___int = ...
end: builtin___int = ...
def __init__(self,
*,
start : typing___Optional[builtin___int] = None,
end : typing___Optional[builtin___int] = None,
) -> None: ...
def HasField(self, field_name: typing_extensions___Literal[u"end",b"end",u"start",b"start"]) -> builtin___bool: ...
def ClearField(self, field_name: typing_extensions___Literal[u"end",b"end",u"start",b"start"]) -> None: ...
type___ReservedRange = ReservedRange
name: typing___Text = ...
reserved_name: google___protobuf___internal___containers___RepeatedScalarFieldContainer[typing___Text] = ...
@property
def field(self) -> google___protobuf___internal___containers___RepeatedCompositeFieldContainer[type___FieldDescriptorProto]: ...
@property
def extension(self) -> google___protobuf___internal___containers___RepeatedCompositeFieldContainer[type___FieldDescriptorProto]: ...
@property
def nested_type(self) -> google___protobuf___internal___containers___RepeatedCompositeFieldContainer[type___DescriptorProto]: ...
@property
def enum_type(self) -> google___protobuf___internal___containers___RepeatedCompositeFieldContainer[type___EnumDescriptorProto]: ...
@property
def extension_range(self) -> google___protobuf___internal___containers___RepeatedCompositeFieldContainer[type___DescriptorProto.ExtensionRange]: ...
@property
def oneof_decl(self) -> google___protobuf___internal___containers___RepeatedCompositeFieldContainer[type___OneofDescriptorProto]: ...
@property
def options(self) -> type___MessageOptions: ...
@property
def reserved_range(self) -> google___protobuf___internal___containers___RepeatedCompositeFieldContainer[type___DescriptorProto.ReservedRange]: ...
def __init__(self,
*,
name : typing___Optional[typing___Text] = None,
field : typing___Optional[typing___Iterable[type___FieldDescriptorProto]] = None,
extension : typing___Optional[typing___Iterable[type___FieldDescriptorProto]] = None,
nested_type : typing___Optional[typing___Iterable[type___DescriptorProto]] = None,
enum_type : typing___Optional[typing___Iterable[type___EnumDescriptorProto]] = None,
extension_range : typing___Optional[typing___Iterable[type___DescriptorProto.ExtensionRange]] = None,
oneof_decl : typing___Optional[typing___Iterable[type___OneofDescriptorProto]] = None,
options : typing___Optional[type___MessageOptions] = None,
reserved_range : typing___Optional[typing___Iterable[type___DescriptorProto.ReservedRange]] = None,
reserved_name : typing___Optional[typing___Iterable[typing___Text]] = None,
) -> None: ...
def HasField(self, field_name: typing_extensions___Literal[u"name",b"name",u"options",b"options"]) -> builtin___bool: ...
def ClearField(self, field_name: typing_extensions___Literal[u"enum_type",b"enum_type",u"extension",b"extension",u"extension_range",b"extension_range",u"field",b"field",u"name",b"name",u"nested_type",b"nested_type",u"oneof_decl",b"oneof_decl",u"options",b"options",u"reserved_name",b"reserved_name",u"reserved_range",b"reserved_range"]) -> None: ...
type___DescriptorProto = DescriptorProto
class ExtensionRangeOptions(google___protobuf___message___Message):
DESCRIPTOR: google___protobuf___descriptor___Descriptor = ...
@property
def uninterpreted_option(self) -> google___protobuf___internal___containers___RepeatedCompositeFieldContainer[type___UninterpretedOption]: ...
def __init__(self,
*,
uninterpreted_option : typing___Optional[typing___Iterable[type___UninterpretedOption]] = None,
) -> None: ...
def ClearField(self, field_name: typing_extensions___Literal[u"uninterpreted_option",b"uninterpreted_option"]) -> None: ...
type___ExtensionRangeOptions = ExtensionRangeOptions
class FieldDescriptorProto(google___protobuf___message___Message):
DESCRIPTOR: google___protobuf___descriptor___Descriptor = ...
TypeValue = typing___NewType('TypeValue', builtin___int)
type___TypeValue = TypeValue
Type: _Type
class _Type(google___protobuf___internal___enum_type_wrapper____EnumTypeWrapper[FieldDescriptorProto.TypeValue]):
DESCRIPTOR: google___protobuf___descriptor___EnumDescriptor = ...
TYPE_DOUBLE = typing___cast(FieldDescriptorProto.TypeValue, 1)
TYPE_FLOAT = typing___cast(FieldDescriptorProto.TypeValue, 2)
TYPE_INT64 = typing___cast(FieldDescriptorProto.TypeValue, 3)
TYPE_UINT64 = typing___cast(FieldDescriptorProto.TypeValue, 4)
TYPE_INT32 = typing___cast(FieldDescriptorProto.TypeValue, 5)
TYPE_FIXED64 = typing___cast(FieldDescriptorProto.TypeValue, 6)
TYPE_FIXED32 = typing___cast(FieldDescriptorProto.TypeValue, 7)
TYPE_BOOL = typing___cast(FieldDescriptorProto.TypeValue, 8)
TYPE_STRING = typing___cast(FieldDescriptorProto.TypeValue, 9)
TYPE_GROUP = typing___cast(FieldDescriptorProto.TypeValue, 10)
TYPE_MESSAGE = typing___cast(FieldDescriptorProto.TypeValue, 11)
TYPE_BYTES = typing___cast(FieldDescriptorProto.TypeValue, 12)
TYPE_UINT32 = typing___cast(FieldDescriptorProto.TypeValue, 13)
TYPE_ENUM = typing___cast(FieldDescriptorProto.TypeValue, 14)
TYPE_SFIXED32 = typing___cast(FieldDescriptorProto.TypeValue, 15)
TYPE_SFIXED64 = typing___cast(FieldDescriptorProto.TypeValue, 16)
TYPE_SINT32 = typing___cast(FieldDescriptorProto.TypeValue, 17)
TYPE_SINT64 = typing___cast(FieldDescriptorProto.TypeValue, 18)
TYPE_DOUBLE = typing___cast(FieldDescriptorProto.TypeValue, 1)
TYPE_FLOAT = typing___cast(FieldDescriptorProto.TypeValue, 2)
TYPE_INT64 = typing___cast(FieldDescriptorProto.TypeValue, 3)
TYPE_UINT64 = typing___cast(FieldDescriptorProto.TypeValue, 4)
TYPE_INT32 = typing___cast(FieldDescriptorProto.TypeValue, 5)
TYPE_FIXED64 = typing___cast(FieldDescriptorProto.TypeValue, 6)
TYPE_FIXED32 = typing___cast(FieldDescriptorProto.TypeValue, 7)
TYPE_BOOL = typing___cast(FieldDescriptorProto.TypeValue, 8)
TYPE_STRING = typing___cast(FieldDescriptorProto.TypeValue, 9)
TYPE_GROUP = typing___cast(FieldDescriptorProto.TypeValue, 10)
TYPE_MESSAGE = typing___cast(FieldDescriptorProto.TypeValue, 11)
TYPE_BYTES = typing___cast(FieldDescriptorProto.TypeValue, 12)
TYPE_UINT32 = typing___cast(FieldDescriptorProto.TypeValue, 13)
TYPE_ENUM = typing___cast(FieldDescriptorProto.TypeValue, 14)
TYPE_SFIXED32 = typing___cast(FieldDescriptorProto.TypeValue, 15)
TYPE_SFIXED64 = typing___cast(FieldDescriptorProto.TypeValue, 16)
TYPE_SINT32 = typing___cast(FieldDescriptorProto.TypeValue, 17)
TYPE_SINT64 = typing___cast(FieldDescriptorProto.TypeValue, 18)
LabelValue = typing___NewType('LabelValue', builtin___int)
type___LabelValue = LabelValue
Label: _Label
class _Label(google___protobuf___internal___enum_type_wrapper____EnumTypeWrapper[FieldDescriptorProto.LabelValue]):
DESCRIPTOR: google___protobuf___descriptor___EnumDescriptor = ...
LABEL_OPTIONAL = typing___cast(FieldDescriptorProto.LabelValue, 1)
LABEL_REQUIRED = typing___cast(FieldDescriptorProto.LabelValue, 2)
LABEL_REPEATED = typing___cast(FieldDescriptorProto.LabelValue, 3)
LABEL_OPTIONAL = typing___cast(FieldDescriptorProto.LabelValue, 1)
LABEL_REQUIRED = typing___cast(FieldDescriptorProto.LabelValue, 2)
LABEL_REPEATED = typing___cast(FieldDescriptorProto.LabelValue, 3)
name: typing___Text = ...
number: builtin___int = ...
label: type___FieldDescriptorProto.LabelValue = ...
type: type___FieldDescriptorProto.TypeValue = ...
type_name: typing___Text = ...
extendee: typing___Text = ...
default_value: typing___Text = ...
oneof_index: builtin___int = ...
json_name: typing___Text = ...
proto3_optional: builtin___bool = ...
@property
def options(self) -> type___FieldOptions: ...
def __init__(self,
*,
name : typing___Optional[typing___Text] = None,
number : typing___Optional[builtin___int] = None,
label : typing___Optional[type___FieldDescriptorProto.LabelValue] = None,
type : typing___Optional[type___FieldDescriptorProto.TypeValue] = None,
type_name : typing___Optional[typing___Text] = None,
extendee : typing___Optional[typing___Text] = None,
default_value : typing___Optional[typing___Text] = None,
oneof_index : typing___Optional[builtin___int] = None,
json_name : typing___Optional[typing___Text] = None,
options : typing___Optional[type___FieldOptions] = None,
proto3_optional : typing___Optional[builtin___bool] = None,
) -> None: ...
def HasField(self, field_name: typing_extensions___Literal[u"default_value",b"default_value",u"extendee",b"extendee",u"json_name",b"json_name",u"label",b"label",u"name",b"name",u"number",b"number",u"oneof_index",b"oneof_index",u"options",b"options",u"proto3_optional",b"proto3_optional",u"type",b"type",u"type_name",b"type_name"]) -> builtin___bool: ...
def ClearField(self, field_name: typing_extensions___Literal[u"default_value",b"default_value",u"extendee",b"extendee",u"json_name",b"json_name",u"label",b"label",u"name",b"name",u"number",b"number",u"oneof_index",b"oneof_index",u"options",b"options",u"proto3_optional",b"proto3_optional",u"type",b"type",u"type_name",b"type_name"]) -> None: ...
type___FieldDescriptorProto = FieldDescriptorProto
class OneofDescriptorProto(google___protobuf___message___Message):
DESCRIPTOR: google___protobuf___descriptor___Descriptor = ...
name: typing___Text = ...
@property
def options(self) -> type___OneofOptions: ...
def __init__(self,
*,
name : typing___Optional[typing___Text] = None,
options : typing___Optional[type___OneofOptions] = None,
) -> None: ...
def HasField(self, field_name: typing_extensions___Literal[u"name",b"name",u"options",b"options"]) -> builtin___bool: ...
def ClearField(self, field_name: typing_extensions___Literal[u"name",b"name",u"options",b"options"]) -> None: ...
type___OneofDescriptorProto = OneofDescriptorProto
class EnumDescriptorProto(google___protobuf___message___Message):
DESCRIPTOR: google___protobuf___descriptor___Descriptor = ...
class EnumReservedRange(google___protobuf___message___Message):
DESCRIPTOR: google___protobuf___descriptor___Descriptor = ...
start: builtin___int = ...
end: builtin___int = ...
def __init__(self,
*,
start : typing___Optional[builtin___int] = None,
end : typing___Optional[builtin___int] = None,
) -> None: ...
def HasField(self, field_name: typing_extensions___Literal[u"end",b"end",u"start",b"start"]) -> builtin___bool: ...
def ClearField(self, field_name: typing_extensions___Literal[u"end",b"end",u"start",b"start"]) -> None: ...
type___EnumReservedRange = EnumReservedRange
name: typing___Text = ...
reserved_name: google___protobuf___internal___containers___RepeatedScalarFieldContainer[typing___Text] = ...
@property
def value(self) -> google___protobuf___internal___containers___RepeatedCompositeFieldContainer[type___EnumValueDescriptorProto]: ...
@property
def options(self) -> type___EnumOptions: ...
@property
def reserved_range(self) -> google___protobuf___internal___containers___RepeatedCompositeFieldContainer[type___EnumDescriptorProto.EnumReservedRange]: ...
def __init__(self,
*,
name : typing___Optional[typing___Text] = None,
value : typing___Optional[typing___Iterable[type___EnumValueDescriptorProto]] = None,
options : typing___Optional[type___EnumOptions] = None,
reserved_range : typing___Optional[typing___Iterable[type___EnumDescriptorProto.EnumReservedRange]] = None,
reserved_name : typing___Optional[typing___Iterable[typing___Text]] = None,
) -> None: ...
def HasField(self, field_name: typing_extensions___Literal[u"name",b"name",u"options",b"options"]) -> builtin___bool: ...
def ClearField(self, field_name: typing_extensions___Literal[u"name",b"name",u"options",b"options",u"reserved_name",b"reserved_name",u"reserved_range",b"reserved_range",u"value",b"value"]) -> None: ...
type___EnumDescriptorProto = EnumDescriptorProto
class EnumValueDescriptorProto(google___protobuf___message___Message):
DESCRIPTOR: google___protobuf___descriptor___Descriptor = ...
name: typing___Text = ...
number: builtin___int = ...
@property
def options(self) -> type___EnumValueOptions: ...
def __init__(self,
*,
name : typing___Optional[typing___Text] = None,
number : typing___Optional[builtin___int] = None,
options : typing___Optional[type___EnumValueOptions] = None,
) -> None: ...
def HasField(self, field_name: typing_extensions___Literal[u"name",b"name",u"number",b"number",u"options",b"options"]) -> builtin___bool: ...
def ClearField(self, field_name: typing_extensions___Literal[u"name",b"name",u"number",b"number",u"options",b"options"]) -> None: ...
type___EnumValueDescriptorProto = EnumValueDescriptorProto
class ServiceDescriptorProto(google___protobuf___message___Message):
DESCRIPTOR: google___protobuf___descriptor___Descriptor = ...
name: typing___Text = ...
@property
def method(self) -> google___protobuf___internal___containers___RepeatedCompositeFieldContainer[type___MethodDescriptorProto]: ...
@property
def options(self) -> type___ServiceOptions: ...
def __init__(self,
*,
name : typing___Optional[typing___Text] = None,
method : typing___Optional[typing___Iterable[type___MethodDescriptorProto]] = None,
options : typing___Optional[type___ServiceOptions] = None,
) -> None: ...
def HasField(self, field_name: typing_extensions___Literal[u"name",b"name",u"options",b"options"]) -> builtin___bool: ...
def ClearField(self, field_name: typing_extensions___Literal[u"method",b"method",u"name",b"name",u"options",b"options"]) -> None: ...
type___ServiceDescriptorProto = ServiceDescriptorProto
class MethodDescriptorProto(google___protobuf___message___Message):
DESCRIPTOR: google___protobuf___descriptor___Descriptor = ...
name: typing___Text = ...
input_type: typing___Text = ...
output_type: typing___Text = ...
client_streaming: builtin___bool = ...
server_streaming: builtin___bool = ...
@property
def options(self) -> type___MethodOptions: ...
def __init__(self,
*,
name : typing___Optional[typing___Text] = None,
input_type : typing___Optional[typing___Text] = None,
output_type : typing___Optional[typing___Text] = None,
options : typing___Optional[type___MethodOptions] = None,
client_streaming : typing___Optional[builtin___bool] = None,
server_streaming : typing___Optional[builtin___bool] = None,
) -> None: ...
def HasField(self, field_name: typing_extensions___Literal[u"client_streaming",b"client_streaming",u"input_type",b"input_type",u"name",b"name",u"options",b"options",u"output_type",b"output_type",u"server_streaming",b"server_streaming"]) -> builtin___bool: ...
def ClearField(self, field_name: typing_extensions___Literal[u"client_streaming",b"client_streaming",u"input_type",b"input_type",u"name",b"name",u"options",b"options",u"output_type",b"output_type",u"server_streaming",b"server_streaming"]) -> None: ...
type___MethodDescriptorProto = MethodDescriptorProto
class FileOptions(google___protobuf___message___Message):
DESCRIPTOR: google___protobuf___descriptor___Descriptor = ...
OptimizeModeValue = typing___NewType('OptimizeModeValue', builtin___int)
type___OptimizeModeValue = OptimizeModeValue
OptimizeMode: _OptimizeMode
class _OptimizeMode(google___protobuf___internal___enum_type_wrapper____EnumTypeWrapper[FileOptions.OptimizeModeValue]):
DESCRIPTOR: google___protobuf___descriptor___EnumDescriptor = ...
SPEED = typing___cast(FileOptions.OptimizeModeValue, 1)
CODE_SIZE = typing___cast(FileOptions.OptimizeModeValue, 2)
LITE_RUNTIME = typing___cast(FileOptions.OptimizeModeValue, 3)
SPEED = typing___cast(FileOptions.OptimizeModeValue, 1)
CODE_SIZE = typing___cast(FileOptions.OptimizeModeValue, 2)
LITE_RUNTIME = typing___cast(FileOptions.OptimizeModeValue, 3)
java_package: typing___Text = ...
java_outer_classname: typing___Text = ...
java_multiple_files: builtin___bool = ...
java_generate_equals_and_hash: builtin___bool = ...
java_string_check_utf8: builtin___bool = ...
optimize_for: type___FileOptions.OptimizeModeValue = ...
go_package: typing___Text = ...
cc_generic_services: builtin___bool = ...
java_generic_services: builtin___bool = ...
py_generic_services: builtin___bool = ...
php_generic_services: builtin___bool = ...
deprecated: builtin___bool = ...
cc_enable_arenas: builtin___bool = ...
objc_class_prefix: typing___Text = ...
csharp_namespace: typing___Text = ...
swift_prefix: typing___Text = ...
php_class_prefix: typing___Text = ...
php_namespace: typing___Text = ...
php_metadata_namespace: typing___Text = ...
ruby_package: typing___Text = ...
@property
def uninterpreted_option(self) -> google___protobuf___internal___containers___RepeatedCompositeFieldContainer[type___UninterpretedOption]: ...
def __init__(self,
*,
java_package : typing___Optional[typing___Text] = None,
java_outer_classname : typing___Optional[typing___Text] = None,
java_multiple_files : typing___Optional[builtin___bool] = None,
java_generate_equals_and_hash : typing___Optional[builtin___bool] = None,
java_string_check_utf8 : typing___Optional[builtin___bool] = None,
optimize_for : typing___Optional[type___FileOptions.OptimizeModeValue] = None,
go_package : typing___Optional[typing___Text] = None,
cc_generic_services : typing___Optional[builtin___bool] = None,
java_generic_services : typing___Optional[builtin___bool] = None,
py_generic_services : typing___Optional[builtin___bool] = None,
php_generic_services : typing___Optional[builtin___bool] = None,
deprecated : typing___Optional[builtin___bool] = None,
cc_enable_arenas : typing___Optional[builtin___bool] = None,
objc_class_prefix : typing___Optional[typing___Text] = None,
csharp_namespace : typing___Optional[typing___Text] = None,
swift_prefix : typing___Optional[typing___Text] = None,
php_class_prefix : typing___Optional[typing___Text] = None,
php_namespace : typing___Optional[typing___Text] = None,
php_metadata_namespace : typing___Optional[typing___Text] = None,
ruby_package : typing___Optional[typing___Text] = None,
uninterpreted_option : typing___Optional[typing___Iterable[type___UninterpretedOption]] = None,
) -> None: ...
def HasField(self, field_name: typing_extensions___Literal[u"cc_enable_arenas",b"cc_enable_arenas",u"cc_generic_services",b"cc_generic_services",u"csharp_namespace",b"csharp_namespace",u"deprecated",b"deprecated",u"go_package",b"go_package",u"java_generate_equals_and_hash",b"java_generate_equals_and_hash",u"java_generic_services",b"java_generic_services",u"java_multiple_files",b"java_multiple_files",u"java_outer_classname",b"java_outer_classname",u"java_package",b"java_package",u"java_string_check_utf8",b"java_string_check_utf8",u"objc_class_prefix",b"objc_class_prefix",u"optimize_for",b"optimize_for",u"php_class_prefix",b"php_class_prefix",u"php_generic_services",b"php_generic_services",u"php_metadata_namespace",b"php_metadata_namespace",u"php_namespace",b"php_namespace",u"py_generic_services",b"py_generic_services",u"ruby_package",b"ruby_package",u"swift_prefix",b"swift_prefix"]) -> builtin___bool: ...
def ClearField(self, field_name: typing_extensions___Literal[u"cc_enable_arenas",b"cc_enable_arenas",u"cc_generic_services",b"cc_generic_services",u"csharp_namespace",b"csharp_namespace",u"deprecated",b"deprecated",u"go_package",b"go_package",u"java_generate_equals_and_hash",b"java_generate_equals_and_hash",u"java_generic_services",b"java_generic_services",u"java_multiple_files",b"java_multiple_files",u"java_outer_classname",b"java_outer_classname",u"java_package",b"java_package",u"java_string_check_utf8",b"java_string_check_utf8",u"objc_class_prefix",b"objc_class_prefix",u"optimize_for",b"optimize_for",u"php_class_prefix",b"php_class_prefix",u"php_generic_services",b"php_generic_services",u"php_metadata_namespace",b"php_metadata_namespace",u"php_namespace",b"php_namespace",u"py_generic_services",b"py_generic_services",u"ruby_package",b"ruby_package",u"swift_prefix",b"swift_prefix",u"uninterpreted_option",b"uninterpreted_option"]) -> None: ...
type___FileOptions = FileOptions
class MessageOptions(google___protobuf___message___Message):
DESCRIPTOR: google___protobuf___descriptor___Descriptor = ...
message_set_wire_format: builtin___bool = ...
no_standard_descriptor_accessor: builtin___bool = ...
deprecated: builtin___bool = ...
map_entry: builtin___bool = ...
@property
def uninterpreted_option(self) -> google___protobuf___internal___containers___RepeatedCompositeFieldContainer[type___UninterpretedOption]: ...
def __init__(self,
*,
message_set_wire_format : typing___Optional[builtin___bool] = None,
no_standard_descriptor_accessor : typing___Optional[builtin___bool] = None,
deprecated : typing___Optional[builtin___bool] = None,
map_entry : typing___Optional[builtin___bool] = None,
uninterpreted_option : typing___Optional[typing___Iterable[type___UninterpretedOption]] = None,
) -> None: ...
def HasField(self, field_name: typing_extensions___Literal[u"deprecated",b"deprecated",u"map_entry",b"map_entry",u"message_set_wire_format",b"message_set_wire_format",u"no_standard_descriptor_accessor",b"no_standard_descriptor_accessor"]) -> builtin___bool: ...
def ClearField(self, field_name: typing_extensions___Literal[u"deprecated",b"deprecated",u"map_entry",b"map_entry",u"message_set_wire_format",b"message_set_wire_format",u"no_standard_descriptor_accessor",b"no_standard_descriptor_accessor",u"uninterpreted_option",b"uninterpreted_option"]) -> None: ...
type___MessageOptions = MessageOptions
class FieldOptions(google___protobuf___message___Message):
DESCRIPTOR: google___protobuf___descriptor___Descriptor = ...
CTypeValue = typing___NewType('CTypeValue', builtin___int)
type___CTypeValue = CTypeValue
CType: _CType
class _CType(google___protobuf___internal___enum_type_wrapper____EnumTypeWrapper[FieldOptions.CTypeValue]):
DESCRIPTOR: google___protobuf___descriptor___EnumDescriptor = ...
STRING = typing___cast(FieldOptions.CTypeValue, 0)
CORD = typing___cast(FieldOptions.CTypeValue, 1)
STRING_PIECE = typing___cast(FieldOptions.CTypeValue, 2)
STRING = typing___cast(FieldOptions.CTypeValue, 0)
CORD = typing___cast(FieldOptions.CTypeValue, 1)
STRING_PIECE = typing___cast(FieldOptions.CTypeValue, 2)
JSTypeValue = typing___NewType('JSTypeValue', builtin___int)
type___JSTypeValue = JSTypeValue
JSType: _JSType
class _JSType(google___protobuf___internal___enum_type_wrapper____EnumTypeWrapper[FieldOptions.JSTypeValue]):
DESCRIPTOR: google___protobuf___descriptor___EnumDescriptor = ...
JS_NORMAL = typing___cast(FieldOptions.JSTypeValue, 0)
JS_STRING = typing___cast(FieldOptions.JSTypeValue, 1)
JS_NUMBER = typing___cast(FieldOptions.JSTypeValue, 2)
JS_NORMAL = typing___cast(FieldOptions.JSTypeValue, 0)
JS_STRING = typing___cast(FieldOptions.JSTypeValue, 1)
JS_NUMBER = typing___cast(FieldOptions.JSTypeValue, 2)
ctype: type___FieldOptions.CTypeValue = ...
packed: builtin___bool = ...
jstype: type___FieldOptions.JSTypeValue = ...
lazy: builtin___bool = ...
deprecated: builtin___bool = ...
weak: builtin___bool = ...
@property
def uninterpreted_option(self) -> google___protobuf___internal___containers___RepeatedCompositeFieldContainer[type___UninterpretedOption]: ...
def __init__(self,
*,
ctype : typing___Optional[type___FieldOptions.CTypeValue] = None,
packed : typing___Optional[builtin___bool] = None,
jstype : typing___Optional[type___FieldOptions.JSTypeValue] = None,
lazy : typing___Optional[builtin___bool] = None,
deprecated : typing___Optional[builtin___bool] = None,
weak : typing___Optional[builtin___bool] = None,
uninterpreted_option : typing___Optional[typing___Iterable[type___UninterpretedOption]] = None,
) -> None: ...
def HasField(self, field_name: typing_extensions___Literal[u"ctype",b"ctype",u"deprecated",b"deprecated",u"jstype",b"jstype",u"lazy",b"lazy",u"packed",b"packed",u"weak",b"weak"]) -> builtin___bool: ...
def ClearField(self, field_name: typing_extensions___Literal[u"ctype",b"ctype",u"deprecated",b"deprecated",u"jstype",b"jstype",u"lazy",b"lazy",u"packed",b"packed",u"uninterpreted_option",b"uninterpreted_option",u"weak",b"weak"]) -> None: ...
type___FieldOptions = FieldOptions
class OneofOptions(google___protobuf___message___Message):
DESCRIPTOR: google___protobuf___descriptor___Descriptor = ...
@property
def uninterpreted_option(self) -> google___protobuf___internal___containers___RepeatedCompositeFieldContainer[type___UninterpretedOption]: ...
def __init__(self,
*,
uninterpreted_option : typing___Optional[typing___Iterable[type___UninterpretedOption]] = None,
) -> None: ...
def ClearField(self, field_name: typing_extensions___Literal[u"uninterpreted_option",b"uninterpreted_option"]) -> None: ...
type___OneofOptions = OneofOptions
class EnumOptions(google___protobuf___message___Message):
DESCRIPTOR: google___protobuf___descriptor___Descriptor = ...
allow_alias: builtin___bool = ...
deprecated: builtin___bool = ...
@property
def uninterpreted_option(self) -> google___protobuf___internal___containers___RepeatedCompositeFieldContainer[type___UninterpretedOption]: ...
def __init__(self,
*,
allow_alias : typing___Optional[builtin___bool] = None,
deprecated : typing___Optional[builtin___bool] = None,
uninterpreted_option : typing___Optional[typing___Iterable[type___UninterpretedOption]] = None,
) -> None: ...
def HasField(self, field_name: typing_extensions___Literal[u"allow_alias",b"allow_alias",u"deprecated",b"deprecated"]) -> builtin___bool: ...
def ClearField(self, field_name: typing_extensions___Literal[u"allow_alias",b"allow_alias",u"deprecated",b"deprecated",u"uninterpreted_option",b"uninterpreted_option"]) -> None: ...
type___EnumOptions = EnumOptions
class EnumValueOptions(google___protobuf___message___Message):
DESCRIPTOR: google___protobuf___descriptor___Descriptor = ...
deprecated: builtin___bool = ...
@property
def uninterpreted_option(self) -> google___protobuf___internal___containers___RepeatedCompositeFieldContainer[type___UninterpretedOption]: ...
def __init__(self,
*,
deprecated : typing___Optional[builtin___bool] = None,
uninterpreted_option : typing___Optional[typing___Iterable[type___UninterpretedOption]] = None,
) -> None: ...
def HasField(self, field_name: typing_extensions___Literal[u"deprecated",b"deprecated"]) -> builtin___bool: ...
def ClearField(self, field_name: typing_extensions___Literal[u"deprecated",b"deprecated",u"uninterpreted_option",b"uninterpreted_option"]) -> None: ...
type___EnumValueOptions = EnumValueOptions
class ServiceOptions(google___protobuf___message___Message):
DESCRIPTOR: google___protobuf___descriptor___Descriptor = ...
deprecated: builtin___bool = ...
@property
def uninterpreted_option(self) -> google___protobuf___internal___containers___RepeatedCompositeFieldContainer[type___UninterpretedOption]: ...
def __init__(self,
*,
deprecated : typing___Optional[builtin___bool] = None,
uninterpreted_option : typing___Optional[typing___Iterable[type___UninterpretedOption]] = None,
) -> None: ...
def HasField(self, field_name: typing_extensions___Literal[u"deprecated",b"deprecated"]) -> builtin___bool: ...
def ClearField(self, field_name: typing_extensions___Literal[u"deprecated",b"deprecated",u"uninterpreted_option",b"uninterpreted_option"]) -> None: ...
type___ServiceOptions = ServiceOptions
class MethodOptions(google___protobuf___message___Message):
DESCRIPTOR: google___protobuf___descriptor___Descriptor = ...
IdempotencyLevelValue = typing___NewType('IdempotencyLevelValue', builtin___int)
type___IdempotencyLevelValue = IdempotencyLevelValue
IdempotencyLevel: _IdempotencyLevel
class _IdempotencyLevel(google___protobuf___internal___enum_type_wrapper____EnumTypeWrapper[MethodOptions.IdempotencyLevelValue]):
DESCRIPTOR: google___protobuf___descriptor___EnumDescriptor = ...
IDEMPOTENCY_UNKNOWN = typing___cast(MethodOptions.IdempotencyLevelValue, 0)
NO_SIDE_EFFECTS = typing___cast(MethodOptions.IdempotencyLevelValue, 1)
IDEMPOTENT = typing___cast(MethodOptions.IdempotencyLevelValue, 2)
IDEMPOTENCY_UNKNOWN = typing___cast(MethodOptions.IdempotencyLevelValue, 0)
NO_SIDE_EFFECTS = typing___cast(MethodOptions.IdempotencyLevelValue, 1)
IDEMPOTENT = typing___cast(MethodOptions.IdempotencyLevelValue, 2)
deprecated: builtin___bool = ...
idempotency_level: type___MethodOptions.IdempotencyLevelValue = ...
@property
def uninterpreted_option(self) -> google___protobuf___internal___containers___RepeatedCompositeFieldContainer[type___UninterpretedOption]: ...
def __init__(self,
*,
deprecated : typing___Optional[builtin___bool] = None,
idempotency_level : typing___Optional[type___MethodOptions.IdempotencyLevelValue] = None,
uninterpreted_option : typing___Optional[typing___Iterable[type___UninterpretedOption]] = None,
) -> None: ...
def HasField(self, field_name: typing_extensions___Literal[u"deprecated",b"deprecated",u"idempotency_level",b"idempotency_level"]) -> builtin___bool: ...
def ClearField(self, field_name: typing_extensions___Literal[u"deprecated",b"deprecated",u"idempotency_level",b"idempotency_level",u"uninterpreted_option",b"uninterpreted_option"]) -> None: ...
type___MethodOptions = MethodOptions
class UninterpretedOption(google___protobuf___message___Message):
DESCRIPTOR: google___protobuf___descriptor___Descriptor = ...
class NamePart(google___protobuf___message___Message):
DESCRIPTOR: google___protobuf___descriptor___Descriptor = ...
name_part: typing___Text = ...
is_extension: builtin___bool = ...
def __init__(self,
*,
name_part : typing___Optional[typing___Text] = None,
is_extension : typing___Optional[builtin___bool] = None,
) -> None: ...
def HasField(self, field_name: typing_extensions___Literal[u"is_extension",b"is_extension",u"name_part",b"name_part"]) -> builtin___bool: ...
def ClearField(self, field_name: typing_extensions___Literal[u"is_extension",b"is_extension",u"name_part",b"name_part"]) -> None: ...
type___NamePart = NamePart
identifier_value: typing___Text = ...
positive_int_value: builtin___int = ...
negative_int_value: builtin___int = ...
double_value: builtin___float = ...
string_value: builtin___bytes = ...
aggregate_value: typing___Text = ...
@property
def name(self) -> google___protobuf___internal___containers___RepeatedCompositeFieldContainer[type___UninterpretedOption.NamePart]: ...
def __init__(self,
*,
name : typing___Optional[typing___Iterable[type___UninterpretedOption.NamePart]] = None,
identifier_value : typing___Optional[typing___Text] = None,
positive_int_value : typing___Optional[builtin___int] = None,
negative_int_value : typing___Optional[builtin___int] = None,
double_value : typing___Optional[builtin___float] = None,
string_value : typing___Optional[builtin___bytes] = None,
aggregate_value : typing___Optional[typing___Text] = None,
) -> None: ...
def HasField(self, field_name: typing_extensions___Literal[u"aggregate_value",b"aggregate_value",u"double_value",b"double_value",u"identifier_value",b"identifier_value",u"negative_int_value",b"negative_int_value",u"positive_int_value",b"positive_int_value",u"string_value",b"string_value"]) -> builtin___bool: ...
def ClearField(self, field_name: typing_extensions___Literal[u"aggregate_value",b"aggregate_value",u"double_value",b"double_value",u"identifier_value",b"identifier_value",u"name",b"name",u"negative_int_value",b"negative_int_value",u"positive_int_value",b"positive_int_value",u"string_value",b"string_value"]) -> None: ...
type___UninterpretedOption = UninterpretedOption
class SourceCodeInfo(google___protobuf___message___Message):
DESCRIPTOR: google___protobuf___descriptor___Descriptor = ...
class Location(google___protobuf___message___Message):
DESCRIPTOR: google___protobuf___descriptor___Descriptor = ...
path: google___protobuf___internal___containers___RepeatedScalarFieldContainer[builtin___int] = ...
span: google___protobuf___internal___containers___RepeatedScalarFieldContainer[builtin___int] = ...
leading_comments: typing___Text = ...
trailing_comments: typing___Text = ...
leading_detached_comments: google___protobuf___internal___containers___RepeatedScalarFieldContainer[typing___Text] = ...
def __init__(self,
*,
path : typing___Optional[typing___Iterable[builtin___int]] = None,
span : typing___Optional[typing___Iterable[builtin___int]] = None,
leading_comments : typing___Optional[typing___Text] = None,
trailing_comments : typing___Optional[typing___Text] = None,
leading_detached_comments : typing___Optional[typing___Iterable[typing___Text]] = None,
) -> None: ...
def HasField(self, field_name: typing_extensions___Literal[u"leading_comments",b"leading_comments",u"trailing_comments",b"trailing_comments"]) -> builtin___bool: ...
def ClearField(self, field_name: typing_extensions___Literal[u"leading_comments",b"leading_comments",u"leading_detached_comments",b"leading_detached_comments",u"path",b"path",u"span",b"span",u"trailing_comments",b"trailing_comments"]) -> None: ...
type___Location = Location
@property
def location(self) -> google___protobuf___internal___containers___RepeatedCompositeFieldContainer[type___SourceCodeInfo.Location]: ...
def __init__(self,
*,
location : typing___Optional[typing___Iterable[type___SourceCodeInfo.Location]] = None,
) -> None: ...
def ClearField(self, field_name: typing_extensions___Literal[u"location",b"location"]) -> None: ...
type___SourceCodeInfo = SourceCodeInfo
class GeneratedCodeInfo(google___protobuf___message___Message):
DESCRIPTOR: google___protobuf___descriptor___Descriptor = ...
class Annotation(google___protobuf___message___Message):
DESCRIPTOR: google___protobuf___descriptor___Descriptor = ...
path: google___protobuf___internal___containers___RepeatedScalarFieldContainer[builtin___int] = ...
source_file: typing___Text = ...
begin: builtin___int = ...
end: builtin___int = ...
def __init__(self,
*,
path : typing___Optional[typing___Iterable[builtin___int]] = None,
source_file : typing___Optional[typing___Text] = None,
begin : typing___Optional[builtin___int] = None,
end : typing___Optional[builtin___int] = None,
) -> None: ...
def HasField(self, field_name: typing_extensions___Literal[u"begin",b"begin",u"end",b"end",u"source_file",b"source_file"]) -> builtin___bool: ...
def ClearField(self, field_name: typing_extensions___Literal[u"begin",b"begin",u"end",b"end",u"path",b"path",u"source_file",b"source_file"]) -> None: ...
type___Annotation = Annotation
@property
def annotation(self) -> google___protobuf___internal___containers___RepeatedCompositeFieldContainer[type___GeneratedCodeInfo.Annotation]: ...
def __init__(self,
*,
annotation : typing___Optional[typing___Iterable[type___GeneratedCodeInfo.Annotation]] = None,
) -> None: ...
def ClearField(self, field_name: typing_extensions___Literal[u"annotation",b"annotation"]) -> None: ...
type___GeneratedCodeInfo = GeneratedCodeInfo

View File

@@ -0,0 +1,18 @@
from typing import Any, Optional
class DescriptorPool:
def __new__(cls, descriptor_db: Optional[Any] = ...): ...
def __init__(self, descriptor_db: Optional[Any] = ...) -> None: ...
def Add(self, file_desc_proto): ...
def AddSerializedFile(self, serialized_file_desc_proto): ...
def AddDescriptor(self, desc): ...
def AddEnumDescriptor(self, enum_desc): ...
def AddFileDescriptor(self, file_desc): ...
def FindFileByName(self, file_name): ...
def FindFileContainingSymbol(self, symbol): ...
def FindMessageTypeByName(self, full_name): ...
def FindEnumTypeByName(self, full_name): ...
def FindFieldByName(self, full_name): ...
def FindExtensionByName(self, full_name): ...
def Default(): ...

View File

@@ -0,0 +1,46 @@
"""
@generated by mypy-protobuf. Do not edit manually!
isort:skip_file
"""
from google.protobuf.descriptor import (
Descriptor as google___protobuf___descriptor___Descriptor,
FileDescriptor as google___protobuf___descriptor___FileDescriptor,
)
from google.protobuf.internal.well_known_types import (
Duration as google___protobuf___internal___well_known_types___Duration,
)
from google.protobuf.message import (
Message as google___protobuf___message___Message,
)
from typing import (
Optional as typing___Optional,
)
from typing_extensions import (
Literal as typing_extensions___Literal,
)
builtin___bool = bool
builtin___bytes = bytes
builtin___float = float
builtin___int = int
DESCRIPTOR: google___protobuf___descriptor___FileDescriptor = ...
class Duration(google___protobuf___message___Message, google___protobuf___internal___well_known_types___Duration):
DESCRIPTOR: google___protobuf___descriptor___Descriptor = ...
seconds: builtin___int = ...
nanos: builtin___int = ...
def __init__(self,
*,
seconds : typing___Optional[builtin___int] = None,
nanos : typing___Optional[builtin___int] = None,
) -> None: ...
def ClearField(self, field_name: typing_extensions___Literal[u"nanos",b"nanos",u"seconds",b"seconds"]) -> None: ...
type___Duration = Duration

View File

@@ -0,0 +1,22 @@
"""
@generated by mypy-protobuf. Do not edit manually!
isort:skip_file
"""
from google.protobuf.descriptor import (
Descriptor as google___protobuf___descriptor___Descriptor,
FileDescriptor as google___protobuf___descriptor___FileDescriptor,
)
from google.protobuf.message import (
Message as google___protobuf___message___Message,
)
DESCRIPTOR: google___protobuf___descriptor___FileDescriptor = ...
class Empty(google___protobuf___message___Message):
DESCRIPTOR: google___protobuf___descriptor___Descriptor = ...
def __init__(self,
) -> None: ...
type___Empty = Empty

View File

@@ -0,0 +1,50 @@
"""
@generated by mypy-protobuf. Do not edit manually!
isort:skip_file
"""
from google.protobuf.descriptor import (
Descriptor as google___protobuf___descriptor___Descriptor,
FileDescriptor as google___protobuf___descriptor___FileDescriptor,
)
from google.protobuf.internal.containers import (
RepeatedScalarFieldContainer as google___protobuf___internal___containers___RepeatedScalarFieldContainer,
)
from google.protobuf.internal.well_known_types import (
FieldMask as google___protobuf___internal___well_known_types___FieldMask,
)
from google.protobuf.message import (
Message as google___protobuf___message___Message,
)
from typing import (
Iterable as typing___Iterable,
Optional as typing___Optional,
Text as typing___Text,
)
from typing_extensions import (
Literal as typing_extensions___Literal,
)
builtin___bool = bool
builtin___bytes = bytes
builtin___float = float
builtin___int = int
DESCRIPTOR: google___protobuf___descriptor___FileDescriptor = ...
class FieldMask(google___protobuf___message___Message, google___protobuf___internal___well_known_types___FieldMask):
DESCRIPTOR: google___protobuf___descriptor___Descriptor = ...
paths: google___protobuf___internal___containers___RepeatedScalarFieldContainer[typing___Text] = ...
def __init__(self,
*,
paths : typing___Optional[typing___Iterable[typing___Text]] = None,
) -> None: ...
def ClearField(self, field_name: typing_extensions___Literal[u"paths",b"paths"]) -> None: ...
type___FieldMask = FieldMask

View File

@@ -0,0 +1,90 @@
from typing import (
Any,
Callable,
Iterable,
Iterator,
List,
Mapping as Mapping,
MutableMapping as MutableMapping,
Optional,
Sequence,
TypeVar,
Union,
overload,
)
from google.protobuf.descriptor import Descriptor
from google.protobuf.internal.message_listener import MessageListener
from google.protobuf.internal.python_message import GeneratedProtocolMessageType
_T = TypeVar("_T")
_K = TypeVar("_K")
_V = TypeVar("_V")
_M = TypeVar("_M")
class BaseContainer(Sequence[_T]):
def __init__(self, message_listener: MessageListener) -> None: ...
def __len__(self) -> int: ...
def __ne__(self, other: object) -> bool: ...
def __hash__(self) -> int: ...
def __repr__(self) -> str: ...
def sort(self, *, key: Optional[Callable[[_T], Any]] = ..., reverse: bool = ...) -> None: ...
@overload
def __getitem__(self, key: int) -> _T: ...
@overload
def __getitem__(self, key: slice) -> List[_T]: ...
class RepeatedScalarFieldContainer(BaseContainer[_T]):
def __init__(self, message_listener: MessageListener, message_descriptor: Descriptor) -> None: ...
def append(self, value: _T) -> None: ...
def insert(self, key: int, value: _T) -> None: ...
def extend(self, elem_seq: Optional[Iterable[_T]]) -> None: ...
def MergeFrom(self: _M, other: _M) -> None: ...
def remove(self, elem: _T) -> None: ...
def pop(self, key: int = ...) -> _T: ...
@overload
def __setitem__(self, key: int, value: _T) -> None: ...
@overload
def __setitem__(self, key: slice, value: Iterable[_T]) -> None: ...
def __getslice__(self, start: int, stop: int) -> List[_T]: ...
def __setslice__(self, start: int, stop: int, values: Iterable[_T]) -> None: ...
def __delitem__(self, key: Union[int, slice]) -> None: ...
def __delslice__(self, start: int, stop: int) -> None: ...
def __eq__(self, other: object) -> bool: ...
class RepeatedCompositeFieldContainer(BaseContainer[_T]):
def __init__(self, message_listener: MessageListener, type_checker: Any) -> None: ...
def add(self, **kwargs: Any) -> _T: ...
def append(self, value: _T) -> None: ...
def insert(self, key: int, value: _T) -> None: ...
def extend(self, elem_seq: Iterable[_T]) -> None: ...
def MergeFrom(self: _M, other: _M) -> None: ...
def remove(self, elem: _T) -> None: ...
def pop(self, key: int = ...) -> _T: ...
def __getslice__(self, start: int, stop: int) -> List[_T]: ...
def __delitem__(self, key: Union[int, slice]) -> None: ...
def __delslice__(self, start: int, stop: int) -> None: ...
def __eq__(self, other: object) -> bool: ...
class ScalarMap(MutableMapping[_K, _V]):
def __setitem__(self, k: _K, v: _V) -> None: ...
def __delitem__(self, v: _K) -> None: ...
def __getitem__(self, k: _K) -> _V: ...
def __len__(self) -> int: ...
def __iter__(self) -> Iterator[_K]: ...
def __eq__(self, other: object) -> bool: ...
def MergeFrom(self: _M, other: _M): ...
def InvalidateIterators(self) -> None: ...
def GetEntryClass(self) -> GeneratedProtocolMessageType: ...
class MessageMap(MutableMapping[_K, _V]):
def __setitem__(self, k: _K, v: _V) -> None: ...
def __delitem__(self, v: _K) -> None: ...
def __getitem__(self, k: _K) -> _V: ...
def __len__(self) -> int: ...
def __iter__(self) -> Iterator[_K]: ...
def __eq__(self, other: object) -> bool: ...
def get_or_create(self, key: _K) -> _V: ...
def MergeFrom(self: _M, other: _M): ...
def InvalidateIterators(self) -> None: ...
def GetEntryClass(self) -> GeneratedProtocolMessageType: ...

View File

@@ -0,0 +1,30 @@
from typing import Any
def ReadTag(buffer, pos): ...
def EnumDecoder(field_number, is_repeated, is_packed, key, new_default): ...
Int32Decoder: Any
Int64Decoder: Any
UInt32Decoder: Any
UInt64Decoder: Any
SInt32Decoder: Any
SInt64Decoder: Any
Fixed32Decoder: Any
Fixed64Decoder: Any
SFixed32Decoder: Any
SFixed64Decoder: Any
FloatDecoder: Any
DoubleDecoder: Any
BoolDecoder: Any
def StringDecoder(field_number, is_repeated, is_packed, key, new_default): ...
def BytesDecoder(field_number, is_repeated, is_packed, key, new_default): ...
def GroupDecoder(field_number, is_repeated, is_packed, key, new_default): ...
def MessageDecoder(field_number, is_repeated, is_packed, key, new_default): ...
MESSAGE_SET_ITEM_TAG: Any
def MessageSetItemDecoder(extensions_by_number): ...
def MapDecoder(field_descriptor, new_default, is_message_map): ...
SkipField: Any

View File

@@ -0,0 +1,34 @@
from typing import Any
Int32Sizer: Any
UInt32Sizer: Any
SInt32Sizer: Any
Fixed32Sizer: Any
Fixed64Sizer: Any
BoolSizer: Any
def StringSizer(field_number, is_repeated, is_packed): ...
def BytesSizer(field_number, is_repeated, is_packed): ...
def GroupSizer(field_number, is_repeated, is_packed): ...
def MessageSizer(field_number, is_repeated, is_packed): ...
def MessageSetItemSizer(field_number): ...
def MapSizer(field_descriptor): ...
def TagBytes(field_number, wire_type): ...
Int32Encoder: Any
UInt32Encoder: Any
SInt32Encoder: Any
Fixed32Encoder: Any
Fixed64Encoder: Any
SFixed32Encoder: Any
SFixed64Encoder: Any
FloatEncoder: Any
DoubleEncoder: Any
def BoolEncoder(field_number, is_repeated, is_packed): ...
def StringEncoder(field_number, is_repeated, is_packed): ...
def BytesEncoder(field_number, is_repeated, is_packed): ...
def GroupEncoder(field_number, is_repeated, is_packed): ...
def MessageEncoder(field_number, is_repeated, is_packed): ...
def MessageSetItemEncoder(field_number): ...
def MapEncoder(field_descriptor): ...

View File

@@ -0,0 +1,18 @@
from typing import Generic, List, Tuple, TypeVar
from google.protobuf.descriptor import EnumDescriptor
_V = TypeVar("_V", bound=int)
# Expose a generic version so that those using mypy-protobuf
# can get autogenerated NewType wrapper around the int values
class _EnumTypeWrapper(Generic[_V]):
DESCRIPTOR: EnumDescriptor
def __init__(self, enum_type: EnumDescriptor) -> None: ...
def Name(self, number: _V) -> str: ...
def Value(self, name: str) -> _V: ...
def keys(self) -> List[str]: ...
def values(self) -> List[_V]: ...
def items(self) -> List[Tuple[str, _V]]: ...
class EnumTypeWrapper(_EnumTypeWrapper[int]): ...

View File

@@ -0,0 +1,36 @@
from typing import Any, Generic, Iterator, TypeVar, overload
from google.protobuf.descriptor import FieldDescriptor
from google.protobuf.message import Message
_ContainerMessageT = TypeVar("_ContainerMessageT", bound=Message)
_ExtenderMessageT = TypeVar("_ExtenderMessageT", bound=Message)
class _ExtensionFieldDescriptor(FieldDescriptor, Generic[_ContainerMessageT, _ExtenderMessageT]): ...
class _ExtensionDict(Generic[_ContainerMessageT]):
def __init__(self, extended_message: _ContainerMessageT) -> None: ...
# Dummy fallback overloads with FieldDescriptor are for backward compatibility with
# mypy-protobuf <= 1.23. We can drop them a few months after 1.24 releases.
@overload
def __getitem__(
self, extension_handle: _ExtensionFieldDescriptor[_ContainerMessageT, _ExtenderMessageT]
) -> _ExtenderMessageT: ...
@overload
def __getitem__(self, extension_handle: FieldDescriptor) -> Any: ...
@overload
def __setitem__(
self, extension_handle: _ExtensionFieldDescriptor[_ContainerMessageT, _ExtenderMessageT], value: _ExtenderMessageT
) -> None: ...
@overload
def __setitem__(self, extension_handle: FieldDescriptor, value: Any) -> None: ...
@overload
def __delitem__(self, extension_handle: _ExtensionFieldDescriptor[_ContainerMessageT, _ExtenderMessageT]) -> None: ...
@overload
def __delitem__(self, extension_handle: FieldDescriptor) -> None: ...
@overload
def __contains__(self, extension_handle: _ExtensionFieldDescriptor[_ContainerMessageT, _ExtenderMessageT]) -> bool: ...
@overload
def __contains__(self, extension_handle: FieldDescriptor) -> bool: ...
def __iter__(self) -> Iterator[_ExtensionFieldDescriptor[_ContainerMessageT, Any]]: ...
def __len__(self) -> int: ...

View File

@@ -0,0 +1,5 @@
class MessageListener(object):
def Modified(self) -> None: ...
class NullMessageListener(MessageListener):
def Modified(self) -> None: ...

View File

@@ -0,0 +1 @@
class GeneratedProtocolMessageType(type): ...

View File

@@ -0,0 +1,94 @@
from datetime import datetime, timedelta
from typing import Any as tAny, Dict, Optional, Text, Type
class Error(Exception): ...
class ParseError(Error): ...
class Any:
type_url: tAny = ...
value: tAny = ...
def Pack(self, msg: tAny, type_url_prefix: bytes = ..., deterministic: Optional[tAny] = ...) -> None: ...
def Unpack(self, msg: tAny): ...
def TypeName(self): ...
def Is(self, descriptor: tAny): ...
class Timestamp:
def ToJsonString(self) -> str: ...
seconds: int = ...
nanos: int = ...
def FromJsonString(self, value: str) -> None: ...
def GetCurrentTime(self) -> None: ...
def ToNanoseconds(self) -> int: ...
def ToMicroseconds(self) -> int: ...
def ToMilliseconds(self) -> int: ...
def ToSeconds(self) -> int: ...
def FromNanoseconds(self, nanos: int) -> None: ...
def FromMicroseconds(self, micros: int) -> None: ...
def FromMilliseconds(self, millis: int) -> None: ...
def FromSeconds(self, seconds: int) -> None: ...
def ToDatetime(self) -> datetime: ...
def FromDatetime(self, dt: datetime) -> None: ...
class Duration:
def ToJsonString(self) -> str: ...
seconds: int = ...
nanos: int = ...
def FromJsonString(self, value: tAny) -> None: ...
def ToNanoseconds(self) -> int: ...
def ToMicroseconds(self) -> int: ...
def ToMilliseconds(self) -> int: ...
def ToSeconds(self) -> int: ...
def FromNanoseconds(self, nanos: int) -> None: ...
def FromMicroseconds(self, micros: int) -> None: ...
def FromMilliseconds(self, millis: int) -> None: ...
def FromSeconds(self, seconds: int) -> None: ...
def ToTimedelta(self) -> timedelta: ...
def FromTimedelta(self, td: timedelta) -> None: ...
class FieldMask:
def ToJsonString(self) -> str: ...
def FromJsonString(self, value: tAny) -> None: ...
def IsValidForDescriptor(self, message_descriptor: tAny): ...
def AllFieldsFromDescriptor(self, message_descriptor: tAny) -> None: ...
def CanonicalFormFromMask(self, mask: tAny) -> None: ...
def Union(self, mask1: tAny, mask2: tAny) -> None: ...
def Intersect(self, mask1: tAny, mask2: tAny) -> None: ...
def MergeMessage(
self, source: tAny, destination: tAny, replace_message_field: bool = ..., replace_repeated_field: bool = ...
) -> None: ...
class _FieldMaskTree:
def __init__(self, field_mask: Optional[tAny] = ...) -> None: ...
def MergeFromFieldMask(self, field_mask: tAny) -> None: ...
def AddPath(self, path: tAny): ...
def ToFieldMask(self, field_mask: tAny) -> None: ...
def IntersectPath(self, path: tAny, intersection: tAny): ...
def AddLeafNodes(self, prefix: tAny, node: tAny) -> None: ...
def MergeMessage(self, source: tAny, destination: tAny, replace_message: tAny, replace_repeated: tAny) -> None: ...
class Struct:
def __getitem__(self, key: tAny): ...
def __contains__(self, item: tAny): ...
def __setitem__(self, key: tAny, value: tAny) -> None: ...
def __delitem__(self, key: tAny) -> None: ...
def __len__(self): ...
def __iter__(self): ...
def keys(self): ...
def values(self): ...
def items(self): ...
def get_or_create_list(self, key: tAny): ...
def get_or_create_struct(self, key: tAny): ...
def update(self, dictionary: tAny) -> None: ...
class ListValue:
def __len__(self): ...
def append(self, value: tAny) -> None: ...
def extend(self, elem_seq: tAny) -> None: ...
def __getitem__(self, index: tAny): ...
def __setitem__(self, index: tAny, value: tAny) -> None: ...
def __delitem__(self, key: tAny) -> None: ...
def items(self) -> None: ...
def add_struct(self): ...
def add_list(self): ...
WKTBASES: Dict[Text, Type]

View File

@@ -0,0 +1,50 @@
from typing import Any
TAG_TYPE_BITS: Any
TAG_TYPE_MASK: Any
WIRETYPE_VARINT: Any
WIRETYPE_FIXED64: Any
WIRETYPE_LENGTH_DELIMITED: Any
WIRETYPE_START_GROUP: Any
WIRETYPE_END_GROUP: Any
WIRETYPE_FIXED32: Any
INT32_MAX: Any
INT32_MIN: Any
UINT32_MAX: Any
INT64_MAX: Any
INT64_MIN: Any
UINT64_MAX: Any
FORMAT_UINT32_LITTLE_ENDIAN: Any
FORMAT_UINT64_LITTLE_ENDIAN: Any
FORMAT_FLOAT_LITTLE_ENDIAN: Any
FORMAT_DOUBLE_LITTLE_ENDIAN: Any
def PackTag(field_number, wire_type): ...
def UnpackTag(tag): ...
def ZigZagEncode(value): ...
def ZigZagDecode(value): ...
def Int32ByteSize(field_number, int32): ...
def Int32ByteSizeNoTag(int32): ...
def Int64ByteSize(field_number, int64): ...
def UInt32ByteSize(field_number, uint32): ...
def UInt64ByteSize(field_number, uint64): ...
def SInt32ByteSize(field_number, int32): ...
def SInt64ByteSize(field_number, int64): ...
def Fixed32ByteSize(field_number, fixed32): ...
def Fixed64ByteSize(field_number, fixed64): ...
def SFixed32ByteSize(field_number, sfixed32): ...
def SFixed64ByteSize(field_number, sfixed64): ...
def FloatByteSize(field_number, flt): ...
def DoubleByteSize(field_number, double): ...
def BoolByteSize(field_number, b): ...
def EnumByteSize(field_number, enum): ...
def StringByteSize(field_number, string): ...
def BytesByteSize(field_number, b): ...
def GroupByteSize(field_number, message): ...
def MessageByteSize(field_number, message): ...
def MessageSetItemByteSize(field_number, msg): ...
def TagByteSize(field_number): ...
NON_PACKABLE_TYPES: Any
def IsTypePackable(field_type): ...

View File

@@ -0,0 +1,26 @@
from typing import Any, Dict, Text, TypeVar, Union
from google.protobuf.message import Message
_MessageT = TypeVar("_MessageT", bound=Message)
class Error(Exception): ...
class ParseError(Error): ...
class SerializeToJsonError(Error): ...
def MessageToJson(
message: Message,
including_default_value_fields: bool = ...,
preserving_proto_field_name: bool = ...,
indent: int = ...,
sort_keys: bool = ...,
use_integers_for_enums: bool = ...,
) -> str: ...
def MessageToDict(
message: Message,
including_default_value_fields: bool = ...,
preserving_proto_field_name: bool = ...,
use_integers_for_enums: bool = ...,
) -> Dict[Text, Any]: ...
def Parse(text: Union[bytes, Text], message: _MessageT, ignore_unknown_fields: bool = ...) -> _MessageT: ...
def ParseDict(js_dict: Any, message: _MessageT, ignore_unknown_fields: bool = ...) -> _MessageT: ...

View File

@@ -0,0 +1,56 @@
import sys
from typing import Any, ByteString, Sequence, Tuple, Type, TypeVar, Union, overload
from .descriptor import Descriptor, FieldDescriptor
from .internal.extension_dict import _ExtensionDict, _ExtensionFieldDescriptor
class Error(Exception): ...
class DecodeError(Error): ...
class EncodeError(Error): ...
_M = TypeVar("_M", bound=Message) # message type (of self)
if sys.version_info < (3,):
_Serialized = Union[bytes, buffer, unicode]
else:
_Serialized = ByteString
class Message:
DESCRIPTOR: Descriptor
def __deepcopy__(self, memo=...): ...
def __eq__(self, other_msg): ...
def __ne__(self, other_msg): ...
def MergeFrom(self: _M, other_msg: _M) -> None: ...
def CopyFrom(self: _M, other_msg: _M) -> None: ...
def Clear(self) -> None: ...
def SetInParent(self) -> None: ...
def IsInitialized(self) -> bool: ...
def MergeFromString(self, serialized: _Serialized) -> int: ...
def ParseFromString(self, serialized: _Serialized) -> int: ...
def SerializeToString(self, deterministic: bool = ...) -> bytes: ...
def SerializePartialToString(self, deterministic: bool = ...) -> bytes: ...
def ListFields(self) -> Sequence[Tuple[FieldDescriptor, Any]]: ...
# Dummy fallback overloads with FieldDescriptor are for backward compatibility with
# mypy-protobuf <= 1.23. We can drop them a few months after 1.24 releases.
@overload
def HasExtension(self: _M, extension_handle: _ExtensionFieldDescriptor[_M, Any]) -> bool: ...
@overload
def HasExtension(self, extension_handle: FieldDescriptor) -> bool: ...
@overload
def ClearExtension(self: _M, extension_handle: _ExtensionFieldDescriptor[_M, Any]) -> None: ...
@overload
def ClearExtension(self, extension_handle: FieldDescriptor) -> None: ...
def ByteSize(self) -> int: ...
@classmethod
def FromString(cls: Type[_M], s: _Serialized) -> _M: ...
@property
def Extensions(self: _M) -> _ExtensionDict[_M]: ...
# Intentionally left out typing on these three methods, because they are
# stringly typed and it is not useful to call them on a Message directly.
# We prefer more specific typing on individual subclasses of Message
# See https://github.com/dropbox/mypy-protobuf/issues/62 for details
def HasField(self, field_name: Any) -> bool: ...
def ClearField(self, field_name: Any) -> None: ...
def WhichOneof(self, oneof_group: Any) -> Any: ...
# TODO: check kwargs
def __init__(self, **kwargs) -> None: ...

View File

@@ -0,0 +1,14 @@
from typing import Any, Dict, Iterable, Optional, Type
from google.protobuf.descriptor import Descriptor
from google.protobuf.descriptor_pb2 import FileDescriptorProto
from google.protobuf.descriptor_pool import DescriptorPool
from google.protobuf.message import Message
class MessageFactory:
pool: Any
def __init__(self, pool: Optional[DescriptorPool] = ...) -> None: ...
def GetPrototype(self, descriptor: Descriptor) -> Type[Message]: ...
def GetMessages(self, files: Iterable[str]) -> Dict[str, Type[Message]]: ...
def GetMessages(file_protos: Iterable[FileDescriptorProto]) -> Dict[str, Type[Message]]: ...

View File

@@ -0,0 +1,6 @@
class GeneratedProtocolMessageType(type):
def __new__(cls, name, bases, dictionary): ...
def __init__(self, name, bases, dictionary) -> None: ...
def ParseMessage(descriptor, byte_str): ...
def MakeClass(descriptor): ...

View File

@@ -0,0 +1,39 @@
from concurrent.futures import Future
from typing import Callable, Optional, Text, Type
from google.protobuf.descriptor import MethodDescriptor, ServiceDescriptor
from google.protobuf.message import Message
class RpcException(Exception): ...
class Service:
@staticmethod
def GetDescriptor() -> ServiceDescriptor: ...
def CallMethod(
self,
method_descriptor: MethodDescriptor,
rpc_controller: RpcController,
request: Message,
done: Optional[Callable[[Message], None]],
) -> Optional[Future[Message]]: ...
def GetRequestClass(self, method_descriptor: MethodDescriptor) -> Type[Message]: ...
def GetResponseClass(self, method_descriptor: MethodDescriptor) -> Type[Message]: ...
class RpcController:
def Reset(self) -> None: ...
def Failed(self) -> bool: ...
def ErrorText(self) -> Optional[Text]: ...
def StartCancel(self) -> None: ...
def SetFailed(self, reason: Text) -> None: ...
def IsCanceled(self) -> bool: ...
def NotifyOnCancel(self, callback: Callable[[], None]) -> None: ...
class RpcChannel:
def CallMethod(
self,
method_descriptor: MethodDescriptor,
rpc_controller: RpcController,
request: Message,
response_class: Type[Message],
done: Optional[Callable[[Message], None]],
) -> Optional[Future[Message]]: ...

View File

@@ -0,0 +1,41 @@
"""
@generated by mypy-protobuf. Do not edit manually!
isort:skip_file
"""
from google.protobuf.descriptor import (
Descriptor as google___protobuf___descriptor___Descriptor,
FileDescriptor as google___protobuf___descriptor___FileDescriptor,
)
from google.protobuf.message import (
Message as google___protobuf___message___Message,
)
from typing import (
Optional as typing___Optional,
Text as typing___Text,
)
from typing_extensions import (
Literal as typing_extensions___Literal,
)
builtin___bool = bool
builtin___bytes = bytes
builtin___float = float
builtin___int = int
DESCRIPTOR: google___protobuf___descriptor___FileDescriptor = ...
class SourceContext(google___protobuf___message___Message):
DESCRIPTOR: google___protobuf___descriptor___Descriptor = ...
file_name: typing___Text = ...
def __init__(self,
*,
file_name : typing___Optional[typing___Text] = None,
) -> None: ...
def ClearField(self, field_name: typing_extensions___Literal[u"file_name",b"file_name"]) -> None: ...
type___SourceContext = SourceContext

View File

@@ -0,0 +1,131 @@
"""
@generated by mypy-protobuf. Do not edit manually!
isort:skip_file
"""
from google.protobuf.descriptor import (
Descriptor as google___protobuf___descriptor___Descriptor,
EnumDescriptor as google___protobuf___descriptor___EnumDescriptor,
FileDescriptor as google___protobuf___descriptor___FileDescriptor,
)
from google.protobuf.internal.containers import (
MessageMap as google___protobuf___internal___containers___MessageMap,
RepeatedCompositeFieldContainer as google___protobuf___internal___containers___RepeatedCompositeFieldContainer,
)
from google.protobuf.internal.enum_type_wrapper import (
_EnumTypeWrapper as google___protobuf___internal___enum_type_wrapper____EnumTypeWrapper,
)
from google.protobuf.internal.well_known_types import (
ListValue as google___protobuf___internal___well_known_types___ListValue,
Struct as google___protobuf___internal___well_known_types___Struct,
)
from google.protobuf.message import (
Message as google___protobuf___message___Message,
)
from typing import (
Any,
Iterable as typing___Iterable,
Mapping as typing___Mapping,
NewType as typing___NewType,
Optional as typing___Optional,
Text as typing___Text,
cast as typing___cast,
)
from typing_extensions import (
Literal as typing_extensions___Literal,
)
builtin___bool = bool
builtin___bytes = bytes
builtin___float = float
builtin___int = int
DESCRIPTOR: google___protobuf___descriptor___FileDescriptor = ...
NullValueValue = typing___NewType('NullValueValue', builtin___int)
type___NullValueValue = NullValueValue
# We temporary set this to Any to simplify mypy-protobuf migration,
# replace with `NullValue: _NullValue` after mypy-protobuf 1.24 is out.
NullValue = Any
class _NullValue(google___protobuf___internal___enum_type_wrapper____EnumTypeWrapper[NullValueValue]):
DESCRIPTOR: google___protobuf___descriptor___EnumDescriptor = ...
NULL_VALUE = typing___cast(NullValueValue, 0)
NULL_VALUE = typing___cast(NullValueValue, 0)
class Struct(google___protobuf___message___Message, google___protobuf___internal___well_known_types___Struct):
DESCRIPTOR: google___protobuf___descriptor___Descriptor = ...
class FieldsEntry(google___protobuf___message___Message):
DESCRIPTOR: google___protobuf___descriptor___Descriptor = ...
key: typing___Text = ...
@property
def value(self) -> type___Value: ...
def __init__(self,
*,
key : typing___Optional[typing___Text] = None,
value : typing___Optional[type___Value] = None,
) -> None: ...
def HasField(self, field_name: typing_extensions___Literal[u"value",b"value"]) -> builtin___bool: ...
def ClearField(self, field_name: typing_extensions___Literal[u"key",b"key",u"value",b"value"]) -> None: ...
type___FieldsEntry = FieldsEntry
@property
def fields(self) -> google___protobuf___internal___containers___MessageMap[typing___Text, type___Value]: ...
def __init__(self,
*,
fields : typing___Optional[typing___Mapping[typing___Text, type___Value]] = None,
) -> None: ...
def ClearField(self, field_name: typing_extensions___Literal[u"fields",b"fields"]) -> None: ...
type___Struct = Struct
class Value(google___protobuf___message___Message):
DESCRIPTOR: google___protobuf___descriptor___Descriptor = ...
null_value: type___NullValueValue = ...
number_value: builtin___float = ...
string_value: typing___Text = ...
bool_value: builtin___bool = ...
@property
def struct_value(self) -> type___Struct: ...
@property
def list_value(self) -> type___ListValue: ...
def __init__(self,
*,
null_value : typing___Optional[type___NullValueValue] = None,
number_value : typing___Optional[builtin___float] = None,
string_value : typing___Optional[typing___Text] = None,
bool_value : typing___Optional[builtin___bool] = None,
struct_value : typing___Optional[type___Struct] = None,
list_value : typing___Optional[type___ListValue] = None,
) -> None: ...
def HasField(self, field_name: typing_extensions___Literal[u"bool_value",b"bool_value",u"kind",b"kind",u"list_value",b"list_value",u"null_value",b"null_value",u"number_value",b"number_value",u"string_value",b"string_value",u"struct_value",b"struct_value"]) -> builtin___bool: ...
def ClearField(self, field_name: typing_extensions___Literal[u"bool_value",b"bool_value",u"kind",b"kind",u"list_value",b"list_value",u"null_value",b"null_value",u"number_value",b"number_value",u"string_value",b"string_value",u"struct_value",b"struct_value"]) -> None: ...
def WhichOneof(self, oneof_group: typing_extensions___Literal[u"kind",b"kind"]) -> typing_extensions___Literal["null_value","number_value","string_value","bool_value","struct_value","list_value"]: ...
type___Value = Value
class ListValue(google___protobuf___message___Message, google___protobuf___internal___well_known_types___ListValue):
DESCRIPTOR: google___protobuf___descriptor___Descriptor = ...
@property
def values(self) -> google___protobuf___internal___containers___RepeatedCompositeFieldContainer[type___Value]: ...
def __init__(self,
*,
values : typing___Optional[typing___Iterable[type___Value]] = None,
) -> None: ...
def ClearField(self, field_name: typing_extensions___Literal[u"values",b"values"]) -> None: ...
type___ListValue = ListValue

View File

@@ -0,0 +1,16 @@
from typing import Dict, Iterable, Type, Union
from google.protobuf.descriptor import Descriptor, EnumDescriptor, FileDescriptor, ServiceDescriptor
from google.protobuf.message import Message
from google.protobuf.message_factory import MessageFactory
class SymbolDatabase(MessageFactory):
def RegisterMessage(self, message: Union[Type[Message], Message]) -> Union[Type[Message], Message]: ...
def RegisterMessageDescriptor(self, message_descriptor: Descriptor) -> None: ...
def RegisterEnumDescriptor(self, enum_descriptor: EnumDescriptor) -> EnumDescriptor: ...
def RegisterServiceDescriptor(self, service_descriptor: ServiceDescriptor) -> None: ...
def RegisterFileDescriptor(self, file_descriptor: FileDescriptor) -> None: ...
def GetSymbol(self, symbol: str) -> Type[Message]: ...
def GetMessages(self, files: Iterable[str]) -> Dict[str, Type[Message]]: ...
def Default(): ...

View File

@@ -0,0 +1,46 @@
"""
@generated by mypy-protobuf. Do not edit manually!
isort:skip_file
"""
from google.protobuf.descriptor import (
Descriptor as google___protobuf___descriptor___Descriptor,
FileDescriptor as google___protobuf___descriptor___FileDescriptor,
)
from google.protobuf.internal.well_known_types import (
Timestamp as google___protobuf___internal___well_known_types___Timestamp,
)
from google.protobuf.message import (
Message as google___protobuf___message___Message,
)
from typing import (
Optional as typing___Optional,
)
from typing_extensions import (
Literal as typing_extensions___Literal,
)
builtin___bool = bool
builtin___bytes = bytes
builtin___float = float
builtin___int = int
DESCRIPTOR: google___protobuf___descriptor___FileDescriptor = ...
class Timestamp(google___protobuf___message___Message, google___protobuf___internal___well_known_types___Timestamp):
DESCRIPTOR: google___protobuf___descriptor___Descriptor = ...
seconds: builtin___int = ...
nanos: builtin___int = ...
def __init__(self,
*,
seconds : typing___Optional[builtin___int] = None,
nanos : typing___Optional[builtin___int] = None,
) -> None: ...
def ClearField(self, field_name: typing_extensions___Literal[u"nanos",b"nanos",u"seconds",b"seconds"]) -> None: ...
type___Timestamp = Timestamp

View File

@@ -0,0 +1,237 @@
"""
@generated by mypy-protobuf. Do not edit manually!
isort:skip_file
"""
from google.protobuf.any_pb2 import (
Any as google___protobuf___any_pb2___Any,
)
from google.protobuf.descriptor import (
Descriptor as google___protobuf___descriptor___Descriptor,
EnumDescriptor as google___protobuf___descriptor___EnumDescriptor,
FileDescriptor as google___protobuf___descriptor___FileDescriptor,
)
from google.protobuf.internal.containers import (
RepeatedCompositeFieldContainer as google___protobuf___internal___containers___RepeatedCompositeFieldContainer,
RepeatedScalarFieldContainer as google___protobuf___internal___containers___RepeatedScalarFieldContainer,
)
from google.protobuf.internal.enum_type_wrapper import (
_EnumTypeWrapper as google___protobuf___internal___enum_type_wrapper____EnumTypeWrapper,
)
from google.protobuf.message import (
Message as google___protobuf___message___Message,
)
from google.protobuf.source_context_pb2 import (
SourceContext as google___protobuf___source_context_pb2___SourceContext,
)
from typing import (
Iterable as typing___Iterable,
NewType as typing___NewType,
Optional as typing___Optional,
Text as typing___Text,
cast as typing___cast,
)
from typing_extensions import (
Literal as typing_extensions___Literal,
)
builtin___bool = bool
builtin___bytes = bytes
builtin___float = float
builtin___int = int
DESCRIPTOR: google___protobuf___descriptor___FileDescriptor = ...
SyntaxValue = typing___NewType('SyntaxValue', builtin___int)
type___SyntaxValue = SyntaxValue
Syntax: _Syntax
class _Syntax(google___protobuf___internal___enum_type_wrapper____EnumTypeWrapper[SyntaxValue]):
DESCRIPTOR: google___protobuf___descriptor___EnumDescriptor = ...
SYNTAX_PROTO2 = typing___cast(SyntaxValue, 0)
SYNTAX_PROTO3 = typing___cast(SyntaxValue, 1)
SYNTAX_PROTO2 = typing___cast(SyntaxValue, 0)
SYNTAX_PROTO3 = typing___cast(SyntaxValue, 1)
class Type(google___protobuf___message___Message):
DESCRIPTOR: google___protobuf___descriptor___Descriptor = ...
name: typing___Text = ...
oneofs: google___protobuf___internal___containers___RepeatedScalarFieldContainer[typing___Text] = ...
syntax: type___SyntaxValue = ...
@property
def fields(self) -> google___protobuf___internal___containers___RepeatedCompositeFieldContainer[type___Field]: ...
@property
def options(self) -> google___protobuf___internal___containers___RepeatedCompositeFieldContainer[type___Option]: ...
@property
def source_context(self) -> google___protobuf___source_context_pb2___SourceContext: ...
def __init__(self,
*,
name : typing___Optional[typing___Text] = None,
fields : typing___Optional[typing___Iterable[type___Field]] = None,
oneofs : typing___Optional[typing___Iterable[typing___Text]] = None,
options : typing___Optional[typing___Iterable[type___Option]] = None,
source_context : typing___Optional[google___protobuf___source_context_pb2___SourceContext] = None,
syntax : typing___Optional[type___SyntaxValue] = None,
) -> None: ...
def HasField(self, field_name: typing_extensions___Literal[u"source_context",b"source_context"]) -> builtin___bool: ...
def ClearField(self, field_name: typing_extensions___Literal[u"fields",b"fields",u"name",b"name",u"oneofs",b"oneofs",u"options",b"options",u"source_context",b"source_context",u"syntax",b"syntax"]) -> None: ...
type___Type = Type
class Field(google___protobuf___message___Message):
DESCRIPTOR: google___protobuf___descriptor___Descriptor = ...
KindValue = typing___NewType('KindValue', builtin___int)
type___KindValue = KindValue
Kind: _Kind
class _Kind(google___protobuf___internal___enum_type_wrapper____EnumTypeWrapper[Field.KindValue]):
DESCRIPTOR: google___protobuf___descriptor___EnumDescriptor = ...
TYPE_UNKNOWN = typing___cast(Field.KindValue, 0)
TYPE_DOUBLE = typing___cast(Field.KindValue, 1)
TYPE_FLOAT = typing___cast(Field.KindValue, 2)
TYPE_INT64 = typing___cast(Field.KindValue, 3)
TYPE_UINT64 = typing___cast(Field.KindValue, 4)
TYPE_INT32 = typing___cast(Field.KindValue, 5)
TYPE_FIXED64 = typing___cast(Field.KindValue, 6)
TYPE_FIXED32 = typing___cast(Field.KindValue, 7)
TYPE_BOOL = typing___cast(Field.KindValue, 8)
TYPE_STRING = typing___cast(Field.KindValue, 9)
TYPE_GROUP = typing___cast(Field.KindValue, 10)
TYPE_MESSAGE = typing___cast(Field.KindValue, 11)
TYPE_BYTES = typing___cast(Field.KindValue, 12)
TYPE_UINT32 = typing___cast(Field.KindValue, 13)
TYPE_ENUM = typing___cast(Field.KindValue, 14)
TYPE_SFIXED32 = typing___cast(Field.KindValue, 15)
TYPE_SFIXED64 = typing___cast(Field.KindValue, 16)
TYPE_SINT32 = typing___cast(Field.KindValue, 17)
TYPE_SINT64 = typing___cast(Field.KindValue, 18)
TYPE_UNKNOWN = typing___cast(Field.KindValue, 0)
TYPE_DOUBLE = typing___cast(Field.KindValue, 1)
TYPE_FLOAT = typing___cast(Field.KindValue, 2)
TYPE_INT64 = typing___cast(Field.KindValue, 3)
TYPE_UINT64 = typing___cast(Field.KindValue, 4)
TYPE_INT32 = typing___cast(Field.KindValue, 5)
TYPE_FIXED64 = typing___cast(Field.KindValue, 6)
TYPE_FIXED32 = typing___cast(Field.KindValue, 7)
TYPE_BOOL = typing___cast(Field.KindValue, 8)
TYPE_STRING = typing___cast(Field.KindValue, 9)
TYPE_GROUP = typing___cast(Field.KindValue, 10)
TYPE_MESSAGE = typing___cast(Field.KindValue, 11)
TYPE_BYTES = typing___cast(Field.KindValue, 12)
TYPE_UINT32 = typing___cast(Field.KindValue, 13)
TYPE_ENUM = typing___cast(Field.KindValue, 14)
TYPE_SFIXED32 = typing___cast(Field.KindValue, 15)
TYPE_SFIXED64 = typing___cast(Field.KindValue, 16)
TYPE_SINT32 = typing___cast(Field.KindValue, 17)
TYPE_SINT64 = typing___cast(Field.KindValue, 18)
CardinalityValue = typing___NewType('CardinalityValue', builtin___int)
type___CardinalityValue = CardinalityValue
Cardinality: _Cardinality
class _Cardinality(google___protobuf___internal___enum_type_wrapper____EnumTypeWrapper[Field.CardinalityValue]):
DESCRIPTOR: google___protobuf___descriptor___EnumDescriptor = ...
CARDINALITY_UNKNOWN = typing___cast(Field.CardinalityValue, 0)
CARDINALITY_OPTIONAL = typing___cast(Field.CardinalityValue, 1)
CARDINALITY_REQUIRED = typing___cast(Field.CardinalityValue, 2)
CARDINALITY_REPEATED = typing___cast(Field.CardinalityValue, 3)
CARDINALITY_UNKNOWN = typing___cast(Field.CardinalityValue, 0)
CARDINALITY_OPTIONAL = typing___cast(Field.CardinalityValue, 1)
CARDINALITY_REQUIRED = typing___cast(Field.CardinalityValue, 2)
CARDINALITY_REPEATED = typing___cast(Field.CardinalityValue, 3)
kind: type___Field.KindValue = ...
cardinality: type___Field.CardinalityValue = ...
number: builtin___int = ...
name: typing___Text = ...
type_url: typing___Text = ...
oneof_index: builtin___int = ...
packed: builtin___bool = ...
json_name: typing___Text = ...
default_value: typing___Text = ...
@property
def options(self) -> google___protobuf___internal___containers___RepeatedCompositeFieldContainer[type___Option]: ...
def __init__(self,
*,
kind : typing___Optional[type___Field.KindValue] = None,
cardinality : typing___Optional[type___Field.CardinalityValue] = None,
number : typing___Optional[builtin___int] = None,
name : typing___Optional[typing___Text] = None,
type_url : typing___Optional[typing___Text] = None,
oneof_index : typing___Optional[builtin___int] = None,
packed : typing___Optional[builtin___bool] = None,
options : typing___Optional[typing___Iterable[type___Option]] = None,
json_name : typing___Optional[typing___Text] = None,
default_value : typing___Optional[typing___Text] = None,
) -> None: ...
def ClearField(self, field_name: typing_extensions___Literal[u"cardinality",b"cardinality",u"default_value",b"default_value",u"json_name",b"json_name",u"kind",b"kind",u"name",b"name",u"number",b"number",u"oneof_index",b"oneof_index",u"options",b"options",u"packed",b"packed",u"type_url",b"type_url"]) -> None: ...
type___Field = Field
class Enum(google___protobuf___message___Message):
DESCRIPTOR: google___protobuf___descriptor___Descriptor = ...
name: typing___Text = ...
syntax: type___SyntaxValue = ...
@property
def enumvalue(self) -> google___protobuf___internal___containers___RepeatedCompositeFieldContainer[type___EnumValue]: ...
@property
def options(self) -> google___protobuf___internal___containers___RepeatedCompositeFieldContainer[type___Option]: ...
@property
def source_context(self) -> google___protobuf___source_context_pb2___SourceContext: ...
def __init__(self,
*,
name : typing___Optional[typing___Text] = None,
enumvalue : typing___Optional[typing___Iterable[type___EnumValue]] = None,
options : typing___Optional[typing___Iterable[type___Option]] = None,
source_context : typing___Optional[google___protobuf___source_context_pb2___SourceContext] = None,
syntax : typing___Optional[type___SyntaxValue] = None,
) -> None: ...
def HasField(self, field_name: typing_extensions___Literal[u"source_context",b"source_context"]) -> builtin___bool: ...
def ClearField(self, field_name: typing_extensions___Literal[u"enumvalue",b"enumvalue",u"name",b"name",u"options",b"options",u"source_context",b"source_context",u"syntax",b"syntax"]) -> None: ...
type___Enum = Enum
class EnumValue(google___protobuf___message___Message):
DESCRIPTOR: google___protobuf___descriptor___Descriptor = ...
name: typing___Text = ...
number: builtin___int = ...
@property
def options(self) -> google___protobuf___internal___containers___RepeatedCompositeFieldContainer[type___Option]: ...
def __init__(self,
*,
name : typing___Optional[typing___Text] = None,
number : typing___Optional[builtin___int] = None,
options : typing___Optional[typing___Iterable[type___Option]] = None,
) -> None: ...
def ClearField(self, field_name: typing_extensions___Literal[u"name",b"name",u"number",b"number",u"options",b"options"]) -> None: ...
type___EnumValue = EnumValue
class Option(google___protobuf___message___Message):
DESCRIPTOR: google___protobuf___descriptor___Descriptor = ...
name: typing___Text = ...
@property
def value(self) -> google___protobuf___any_pb2___Any: ...
def __init__(self,
*,
name : typing___Optional[typing___Text] = None,
value : typing___Optional[google___protobuf___any_pb2___Any] = None,
) -> None: ...
def HasField(self, field_name: typing_extensions___Literal[u"value",b"value"]) -> builtin___bool: ...
def ClearField(self, field_name: typing_extensions___Literal[u"name",b"name",u"value",b"value"]) -> None: ...
type___Option = Option

View File

@@ -0,0 +1,129 @@
"""
@generated by mypy-protobuf. Do not edit manually!
isort:skip_file
"""
from google.protobuf.descriptor import (
Descriptor as google___protobuf___descriptor___Descriptor,
FileDescriptor as google___protobuf___descriptor___FileDescriptor,
)
from google.protobuf.message import (
Message as google___protobuf___message___Message,
)
from typing import (
Optional as typing___Optional,
Text as typing___Text,
)
from typing_extensions import (
Literal as typing_extensions___Literal,
)
builtin___bool = bool
builtin___bytes = bytes
builtin___float = float
builtin___int = int
DESCRIPTOR: google___protobuf___descriptor___FileDescriptor = ...
class DoubleValue(google___protobuf___message___Message):
DESCRIPTOR: google___protobuf___descriptor___Descriptor = ...
value: builtin___float = ...
def __init__(self,
*,
value : typing___Optional[builtin___float] = None,
) -> None: ...
def ClearField(self, field_name: typing_extensions___Literal[u"value",b"value"]) -> None: ...
type___DoubleValue = DoubleValue
class FloatValue(google___protobuf___message___Message):
DESCRIPTOR: google___protobuf___descriptor___Descriptor = ...
value: builtin___float = ...
def __init__(self,
*,
value : typing___Optional[builtin___float] = None,
) -> None: ...
def ClearField(self, field_name: typing_extensions___Literal[u"value",b"value"]) -> None: ...
type___FloatValue = FloatValue
class Int64Value(google___protobuf___message___Message):
DESCRIPTOR: google___protobuf___descriptor___Descriptor = ...
value: builtin___int = ...
def __init__(self,
*,
value : typing___Optional[builtin___int] = None,
) -> None: ...
def ClearField(self, field_name: typing_extensions___Literal[u"value",b"value"]) -> None: ...
type___Int64Value = Int64Value
class UInt64Value(google___protobuf___message___Message):
DESCRIPTOR: google___protobuf___descriptor___Descriptor = ...
value: builtin___int = ...
def __init__(self,
*,
value : typing___Optional[builtin___int] = None,
) -> None: ...
def ClearField(self, field_name: typing_extensions___Literal[u"value",b"value"]) -> None: ...
type___UInt64Value = UInt64Value
class Int32Value(google___protobuf___message___Message):
DESCRIPTOR: google___protobuf___descriptor___Descriptor = ...
value: builtin___int = ...
def __init__(self,
*,
value : typing___Optional[builtin___int] = None,
) -> None: ...
def ClearField(self, field_name: typing_extensions___Literal[u"value",b"value"]) -> None: ...
type___Int32Value = Int32Value
class UInt32Value(google___protobuf___message___Message):
DESCRIPTOR: google___protobuf___descriptor___Descriptor = ...
value: builtin___int = ...
def __init__(self,
*,
value : typing___Optional[builtin___int] = None,
) -> None: ...
def ClearField(self, field_name: typing_extensions___Literal[u"value",b"value"]) -> None: ...
type___UInt32Value = UInt32Value
class BoolValue(google___protobuf___message___Message):
DESCRIPTOR: google___protobuf___descriptor___Descriptor = ...
value: builtin___bool = ...
def __init__(self,
*,
value : typing___Optional[builtin___bool] = None,
) -> None: ...
def ClearField(self, field_name: typing_extensions___Literal[u"value",b"value"]) -> None: ...
type___BoolValue = BoolValue
class StringValue(google___protobuf___message___Message):
DESCRIPTOR: google___protobuf___descriptor___Descriptor = ...
value: typing___Text = ...
def __init__(self,
*,
value : typing___Optional[typing___Text] = None,
) -> None: ...
def ClearField(self, field_name: typing_extensions___Literal[u"value",b"value"]) -> None: ...
type___StringValue = StringValue
class BytesValue(google___protobuf___message___Message):
DESCRIPTOR: google___protobuf___descriptor___Descriptor = ...
value: builtin___bytes = ...
def __init__(self,
*,
value : typing___Optional[builtin___bytes] = None,
) -> None: ...
def ClearField(self, field_name: typing_extensions___Literal[u"value",b"value"]) -> None: ...
type___BytesValue = BytesValue