--- /dev/null
+from typing import Any, Sequence, Optional, Text, Tuple\r
+\r
+from .descriptor import FieldDescriptor\r
+\r
+class Error(Exception): ...\r
+class DecodeError(Error): ...\r
+class EncodeError(Error): ...\r
+\r
+class Message:\r
+ DESCRIPTOR = ... # type: Any\r
+ def __deepcopy__(self, memo=...): ...\r
+ def __eq__(self, other_msg): ...\r
+ def __ne__(self, other_msg): ...\r
+ def MergeFrom(self, other_msg: Message) -> None: ...\r
+ def CopyFrom(self, other_msg: Message) -> None: ...\r
+ def Clear(self) -> None: ...\r
+ def SetInParent(self) -> None: ...\r
+ def IsInitialized(self) -> bool: ...\r
+ def MergeFromString(self, serialized: Any) -> int: ... # TODO: we need to be able to call buffer() on serialized\r
+ def ParseFromString(self, serialized: Any) -> None: ...\r
+ def SerializeToString(self) -> bytes: ...\r
+ def SerializePartialToString(self) -> bytes: ...\r
+ def ListFields(self) -> Sequence[Tuple[FieldDescriptor, Any]]: ...\r
+ def HasField(self, field_name: Text) -> bool: ...\r
+ def ClearField(self, field_name: Text) -> None: ...\r
+ def WhichOneof(self, oneof_group) -> Optional[Text]: ...\r
+ def HasExtension(self, extension_handle): ...\r
+ def ClearExtension(self, extension_handle): ...\r
+ def ByteSize(self) -> int: ...\r
+\r
+ # TODO: check kwargs\r
+ def __init__(self, **kwargs) -> None: ...\r