proto

package
v0.2.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 1, 2023 License: MIT Imports: 1 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Decoder

type Decoder struct {
	// contains filtered or unexported fields
}

func NewDecoder

func NewDecoder(buf []byte) *Decoder

func (*Decoder) EOF

func (d *Decoder) EOF() bool

func (*Decoder) PeekTag

func (d *Decoder) PeekTag() (uint32, protowire.Type, int)

func (*Decoder) ReadBytes

func (d *Decoder) ReadBytes() ([]byte, int)

func (*Decoder) ReadFixed32

func (d *Decoder) ReadFixed32() (uint32, int)

func (*Decoder) ReadFixed64

func (d *Decoder) ReadFixed64() (uint64, int)

func (*Decoder) ReadTag

func (d *Decoder) ReadTag() (uint32, protowire.Type, int)

func (*Decoder) ReadVarint

func (d *Decoder) ReadVarint() (uint64, int)

func (*Decoder) ReadZigzag

func (d *Decoder) ReadZigzag() (int64, int)

type Encoder

type Encoder struct {
	// contains filtered or unexported fields
}

func NewEncoder

func NewEncoder(buf []byte) *Encoder

func (*Encoder) Bytes

func (e *Encoder) Bytes() []byte

func (*Encoder) Clear

func (e *Encoder) Clear()

func (*Encoder) EmitBytes

func (e *Encoder) EmitBytes(tag uint32, s []byte)

func (*Encoder) EmitFixed32

func (e *Encoder) EmitFixed32(tag uint32, v uint32)

func (*Encoder) EmitFixed64

func (e *Encoder) EmitFixed64(tag uint32, v uint64)

func (*Encoder) EmitString

func (e *Encoder) EmitString(tag uint32, s string)

func (*Encoder) EmitVarint

func (e *Encoder) EmitVarint(tag uint32, v uint64)

func (*Encoder) EmitZigzag

func (e *Encoder) EmitZigzag(tag uint32, x int64)

func (*Encoder) Len

func (e *Encoder) Len() int

func (*Encoder) WriteBytes

func (e *Encoder) WriteBytes(s []byte)

func (*Encoder) WriteFixed32

func (e *Encoder) WriteFixed32(v uint32)

func (*Encoder) WriteFixed64

func (e *Encoder) WriteFixed64(v uint64)

func (*Encoder) WriteVarint

func (e *Encoder) WriteVarint(v uint64)

func (*Encoder) WriteZigzag

func (e *Encoder) WriteZigzag(x int64)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL