Package protolegacy
import "google.golang.org/protobuf/internal/protolegacy"
- Overview
- Index
Package protolegacy is a stub version of the v1 proto package
to satisfy internal/testprotos/legacy dependencies.
- Constants
- Variables
- func CompactTextString(Message) string
- func DecodeVarint([]byte) (uint64, int)
- func EncodeVarint(uint64) []byte
- func EnumName(map[int32]string, int32) string
- func Marshal(Message) ([]byte, error)
- func RegisterEnum(string, map[int32]string, map[string]int32)
- func RegisterExtension(d *ExtensionDesc)
- func RegisterFile(s string, d []byte)
- func RegisterMapType(interface{}, string)
- func RegisterType(m Message, s string)
- func Size(Message) int
- func SizeVarint(uint64) int
- func Unmarshal([]byte, Message) error
- func UnmarshalJSONEnum(map[string]int32, []byte, string) (int32, error)
- type Buffer
- func (*Buffer) DecodeFixed32() (uint64, error)
- func (*Buffer) DecodeFixed64() (uint64, error)
- func (*Buffer) DecodeGroup(Message) error
- func (*Buffer) DecodeMessage(Message) error
- func (*Buffer) DecodeRawBytes(bool) ([]byte, error)
- func (*Buffer) DecodeStringBytes() (string, error)
- func (*Buffer) DecodeVarint() (uint64, error)
- func (*Buffer) DecodeZigzag32() (uint64, error)
- func (*Buffer) DecodeZigzag64() (uint64, error)
- func (*Buffer) EncodeFixed32(uint64) error
- func (*Buffer) EncodeFixed64(uint64) error
- func (*Buffer) EncodeMessage(Message) error
- func (*Buffer) EncodeRawBytes([]byte) error
- func (*Buffer) EncodeStringBytes(string) error
- func (*Buffer) EncodeVarint(uint64) error
- func (*Buffer) EncodeZigzag32(uint64) error
- func (*Buffer) EncodeZigzag64(uint64) error
- func (*Buffer) Marshal(Message) error
- func (*Buffer) Unmarshal(Message) error
- type Extension
- type ExtensionDesc
- type ExtensionRange
- type InternalMessageInfo
- func (*InternalMessageInfo) DiscardUnknown(Message)
- func (*InternalMessageInfo) Marshal([]byte, Message, bool) ([]byte, error)
- func (*InternalMessageInfo) Merge(Message, Message)
- func (*InternalMessageInfo) Size(Message) int
- func (*InternalMessageInfo) Unmarshal(Message, []byte) error
- type Message
- type XXX_InternalExtensions
Package files
proto.go
Constants
const (
ProtoPackageIsVersion1 = true
ProtoPackageIsVersion2 = true
ProtoPackageIsVersion3 = true
)
const (
WireVarint = 0
WireFixed32 = 5
WireFixed64 = 1
WireBytes = 2
WireStartGroup = 3
WireEndGroup = 4
)
Variables
var ErrInternalBadWireType = errors.New("not implemented")
func CompactTextString(Message) string
func DecodeVarint([]byte) (uint64, int)
func EncodeVarint(uint64) []byte
func EnumName(map[int32]string, int32) string
func Marshal(Message) ([]byte, error)
func RegisterEnum(string, map[int32]string, map[string]int32)
func RegisterExtension(d *ExtensionDesc)
func RegisterFile(s string, d []byte)
func RegisterMapType(interface{}, string)
func RegisterType(m Message, s string)
func Size(Message) int
func SizeVarint(uint64) int
func Unmarshal([]byte, Message) error
func UnmarshalJSONEnum(map[string]int32, []byte, string) (int32, error)
type Buffer struct{}
func (*Buffer) DecodeFixed32() (uint64, error)
func (*Buffer) DecodeFixed64() (uint64, error)
func (*Buffer) DecodeGroup(Message) error
func (*Buffer) DecodeMessage(Message) error
func (*Buffer) DecodeRawBytes(bool) ([]byte, error)
func (*Buffer) DecodeStringBytes() (string, error)
func (*Buffer) DecodeVarint() (uint64, error)
func (*Buffer) DecodeZigzag32() (uint64, error)
func (*Buffer) DecodeZigzag64() (uint64, error)
func (*Buffer) EncodeFixed32(uint64) error
func (*Buffer) EncodeFixed64(uint64) error
func (*Buffer) EncodeMessage(Message) error
func (*Buffer) EncodeRawBytes([]byte) error
func (*Buffer) EncodeStringBytes(string) error
func (*Buffer) EncodeVarint(uint64) error
func (*Buffer) EncodeZigzag32(uint64) error
func (*Buffer) EncodeZigzag64(uint64) error
func (*Buffer) Marshal(Message) error
func (*Buffer) Unmarshal(Message) error
type Extension = protoimpl.ExtensionFieldV1
type ExtensionDesc = protoimpl.ExtensionInfo
type ExtensionRange = protoiface.ExtensionRangeV1
type InternalMessageInfo struct{}
func (*InternalMessageInfo) DiscardUnknown(Message)
func (*InternalMessageInfo) Marshal
¶
func (*InternalMessageInfo) Marshal([]byte, Message, bool) ([]byte, error)
func (*InternalMessageInfo) Merge
¶
func (*InternalMessageInfo) Merge(Message, Message)
func (*InternalMessageInfo) Size
¶
func (*InternalMessageInfo) Size(Message) int
func (*InternalMessageInfo) Unmarshal
¶
func (*InternalMessageInfo) Unmarshal(Message, []byte) error
type Message = protoiface.MessageV1
type XXX_InternalExtensions = protoimpl.ExtensionFields