google.protobuf.any_pb2¶
Generated protocol buffer code.
-
class
google.protobuf.any_pb2.
Any
(**kwargs)¶ -
ByteSize
()¶
-
Clear
()¶
-
ClearExtension
(extension_handle)¶ Clears the contents of a given extension.
- Parameters:
extension_handle – The handle for the extension to clear.
-
ClearField
(field_name)¶
-
CopyFrom
(other_msg)¶ Copies the content of the specified message into the current message.
The method clears the current message and then merges the specified message using MergeFrom.
- Parameters:
other_msg (Message) – A message to copy into the current one.
-
DESCRIPTOR
= <google.protobuf.descriptor.Descriptor object>¶
-
DiscardUnknownFields
()¶
-
FindInitializationErrors
()¶ Finds required fields which are not initialized.
- Returns:
A list of strings. Each string is a path to an uninitialized field from the top-level message, e.g. “foo.bar[5].baz”.
-
static
FromString
(s)¶
-
HasExtension
(extension_handle)¶ Checks if a certain extension is present for this message.
Extensions are retrieved using the
Extensions
mapping (if present).- Parameters:
extension_handle – The handle for the extension to check.
- Returns:
Whether the extension is present for this message.
- Return type:
- Raises:
KeyError – if the extension is repeated. Similar to repeated fields, there is no separate notion of presence: a “not present” repeated extension is an empty list.
-
HasField
(field_name)¶
-
Is
(descriptor)¶ Checks if this Any represents the given protobuf type.
-
IsInitialized
(errors=None)¶ Checks if all required fields of a message are set.
- Parameters:
errors – A list which, if provided, will be populated with the field paths of all missing required fields.
- Returns:
True iff the specified message has all required fields set.
-
ListFields
()¶
-
MergeFrom
(msg)¶
-
MergeFromString
(serialized)¶
-
Pack
(msg, type_url_prefix='type.googleapis.com/', deterministic=None)¶ Packs the specified message into current Any message.
-
ParseFromString
(serialized)¶ Parse serialized protocol buffer data into this message.
Like
MergeFromString()
, except we clear the object first.- Raises:
message.DecodeError if the input cannot be parsed. –
-
static
RegisterExtension
(extension_handle)¶
-
SerializePartialToString
(**kwargs)¶
-
SerializeToString
(**kwargs)¶
-
SetInParent
()¶ Sets the _cached_byte_size_dirty bit to true, and propagates this to our listener iff this was a state change.
-
TYPE_URL_FIELD_NUMBER
= 1¶
-
TypeName
()¶ Returns the protobuf type name of the inner message.
-
UnknownFields
()¶
-
Unpack
(msg)¶ Unpacks the current Any message into specified message.
-
VALUE_FIELD_NUMBER
= 2¶
-
WhichOneof
(oneof_name)¶ Returns the name of the currently set field inside a oneof, or None.
-
property
type_url
¶
-
property
value
¶
-