package
1.3.2
Repository: https://github.com/gogo/protobuf.git
Documentation: pkg.go.dev

# Packages

# Functions

Bool is a helper routine that allocates a new bool value to store v and returns a pointer to it.
ClearAllExtensions clears all extensions from pb.
ClearExtension removes the given extension from pb.
Clone returns a deep copy of a protocol buffer.
CompactText writes a given protocol buffer in compact text format (one line).
CompactTextString is the same as CompactText, but returns the string directly.
DecodeVarint reads a varint-encoded integer from the slice.
DiscardUnknown recursively discards all unknown fields from this message and all embedded messages.
EncodeVarint returns the varint encoding of x.
EnumName is a helper function to simplify printing protocol buffer enums by name.
EnumValueMap returns the mapping from names to integers of the enum type enumType, or a nil if not found.
Equal returns true iff protocol buffers a and b are equal.
ExtensionDescs returns a new slice containing pb's extension descriptors, in undefined order.
FileDescriptor returns the compressed FileDescriptorProto for a .proto file.
Float32 is a helper routine that allocates a new float32 value to store v and returns a pointer to it.
Float64 is a helper routine that allocates a new float64 value to store v and returns a pointer to it.
GetExtension retrieves a proto2 extended field from pb.
GetExtensions returns a slice of the extensions present in pb that are also listed in es.
GetProperties returns the list of properties for the type represented by t.
Deprecated: do not use.
HasExtension returns whether the given extension is present in pb.
Int is a helper routine that allocates a new int32 value to store v and returns a pointer to it, but unlike Int32 its argument value is an int.
Int32 is a helper routine that allocates a new int32 value to store v and returns a pointer to it.
Int64 is a helper routine that allocates a new int64 value to store v and returns a pointer to it.
Marshal takes a protocol buffer message and encodes it into the wire format, returning the data.
Deprecated: do not use.
Deprecated: do not use.
MarshalText writes a given protocol buffer in text format.
MarshalTextString is the same as MarshalText, but returns the string directly.
Merge merges src into dst.
MessageName returns the fully-qualified proto name for the given message type.
MessageType returns the message type (pointer to struct) for a named message.
NewBuffer allocates a new Buffer and initializes its internal data to the contents of the argument slice.
RegisteredExtensions returns a map of the registered extensions of a protocol buffer struct, indexed by the extension number.
RegisterEnum is called from the generated code to install the enum descriptor maps into the global table to aid parsing text format protocol buffers.
RegisterExtension is called from the generated code.
RegisterFile is called from generated code and maps from the full file name of a .proto file to its compressed FileDescriptorProto.
RegisterMapType is called from generated code and maps from the fully qualified proto name to the native map type of the proto map definition.
Deprecated: do not use.
RegisterType is called from generated code and maps from the fully qualified proto name to the type (pointer to struct) of the protocol buffer.
SetDefaults sets unset protocol buffer fields to their default values.
SetExtension sets the specified extension of pb to the specified value.
SetRawExtension is for testing only.
Size returns the encoded size of a protocol buffer message.
SizeVarint returns the varint encoding size of an integer.
String is a helper routine that allocates a new string value to store v and returns a pointer to it.
Uint32 is a helper routine that allocates a new uint32 value to store v and returns a pointer to it.
Uint64 is a helper routine that allocates a new uint64 value to store v and returns a pointer to it.
Unmarshal parses the protocol buffer representation in buf and places the decoded result in pb.
UnmarshalJSONEnum is a helper function to simplify recovering enum int values from their JSON-encoded representation.
UnmarshalMerge parses the protocol buffer representation in buf and writes the decoded result to pb.
Deprecated: do not use.
Deprecated: do not use.
UnmarshalText reads a protocol buffer in Text format.

# Constants

ProtoPackageIsVersion1 is referenced from generated protocol buffer files to assert that that code is compatible with this version of the proto package.
ProtoPackageIsVersion2 is referenced from generated protocol buffer files to assert that that code is compatible with this version of the proto package.
ProtoPackageIsVersion3 is referenced from generated protocol buffer files to assert that that code is compatible with this version of the proto package.
Constants that identify the encoding of a value on the wire.
Constants that identify the encoding of a value on the wire.
Constants that identify the encoding of a value on the wire.
Constants that identify the encoding of a value on the wire.
Constants that identify the encoding of a value on the wire.
Constants that identify the encoding of a value on the wire.

# Variables

ErrInternalBadWireType is returned by generated code when an incorrect wire type is encountered.
ErrMissingExtension is the error returned by GetExtension if the named extension is not in the message.
ErrNil is the error returned if Marshal is called with nil.
ErrTooLarge is the error returned if Marshal is called with a message that encodes to >2GB.

# Structs

A Buffer is a buffer manager for marshaling and unmarshaling protocol buffers.
Extension represents an extension in a message.
ExtensionDesc represents an extension specification.
ExtensionRange represents a range of message extensions for a protocol buffer.
InternalMessageInfo is a type used internally by generated .pb.go files.
OneofProperties represents information about a specific field in a oneof.
Properties represents the protocol-specific behavior of a single struct field.
RequiredNotSetError is an error type returned by either Marshal or Unmarshal.
Deprecated: do not use.
StructProperties represents properties for all the fields of a struct.
TextMarshaler is a configurable text format marshaler.
XXX_InternalExtensions is an internal representation of proto extensions.

# Interfaces

Marshaler is the interface representing objects that can marshal themselves.
Merger is the interface representing objects that can merge messages of the same type.
Message is implemented by generated protocol buffer messages.
Unmarshaler is the interface representing objects that can unmarshal themselves.