Documentation ¶
Index ¶
- type Composite
- type Data
- type Decoder
- func (d *Decoder) Read(r Reader, v ...any) error
- func (d *Decoder) ReadBool(r Reader) (bool, error)
- func (d *Decoder) ReadFloat(r Reader) (float64, error)
- func (d *Decoder) ReadUvarint(r Reader) (uint64, error)
- func (d *Decoder) ReadVarint(r Reader) (int64, error)
- func (d *Decoder) Unmarshal(data []byte, v interface{}) error
- type Encoder
- func (e *Encoder) Marshal(v interface{}) ([]byte, error)
- func (e *Encoder) Write(w Writer, v ...any) error
- func (e *Encoder) WriteBool(w Writer, v bool) error
- func (e *Encoder) WriteFloat(w Writer, v float64) error
- func (e *Encoder) WriteUvarint(w Writer, v uint64) error
- func (e *Encoder) WriteVarint(w Writer, v int64) error
- type LengthDescriptor
- type List
- type Nullable
- type Pointer
- type Reader
- type TinyPackable
- type VarData
- type VarList
- type VariadicLength
- type Writer
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Data ¶
type Data[LD LengthDescriptor] struct { List[LD, byte] }
func CreateData ¶
func CreateData[LD LengthDescriptor](content ...byte) (result Data[LD])
type Decoder ¶
type Decoder struct {
MaxVariadicLength int
}
func DefaultDecoder ¶
func DefaultDecoder() *Decoder
type LengthDescriptor ¶
type LengthDescriptor interface {
GetTinyPackLength() int
}
type List ¶
type List[LD LengthDescriptor, T any] struct { Content []T }
func CreateList ¶
func CreateList[LD LengthDescriptor, T any](content ...T) (result List[LD, T])
type TinyPackable ¶
type VariadicLength ¶
type VariadicLength struct{}
func (VariadicLength) GetTinyPackLength ¶
func (VariadicLength) GetTinyPackLength() int
Source Files ¶
Click to show internal directories.
Click to hide internal directories.