Documentation ¶
Overview ¶
Package decode implements BINN decoding.
Index ¶
- Variables
- func Float32(b []byte) float32
- func Float64(b []byte) float64
- func Int16(b []byte) int16
- func Int32(b []byte) int32
- func Int64(b []byte) int64
- func Int8(b []byte) int8
- func String(b []byte) string
- func Type(b []byte) binn.Type
- func Uint16(b []byte) uint16
- func Uint32(b []byte) uint32
- func Uint64(b []byte) uint64
- func Uint8(b []byte) uint8
- func Unmarshal(data []byte, v interface{}) error
- type Decoder
- type FailedToReadSizeError
- type FailedToReadTypeError
- type InvalidUnmarshalError
- type UnknownValueError
- type Unmarshaler
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrUnknownType = errors.New("unknown storage type") ErrCantSetValue = errors.New("can't set value") ErrItemNotFound = errors.New("item not found") ErrInvalidItem = errors.New("invalid item") ErrInvalidStructValue = errors.New("invalid struct value") ErrIncompleteRead = errors.New("incomplete read") )
Functions ¶
Types ¶
type Decoder ¶ added in v0.1.3
type Decoder struct {
// contains filtered or unexported fields
}
func NewDecoder ¶ added in v0.1.3
type FailedToReadSizeError ¶ added in v0.2.2
type FailedToReadSizeError struct {
Previous error
}
func (*FailedToReadSizeError) Error ¶ added in v0.2.2
func (err *FailedToReadSizeError) Error() string
func (*FailedToReadSizeError) Unwrap ¶ added in v0.2.2
func (err *FailedToReadSizeError) Unwrap() error
type FailedToReadTypeError ¶ added in v0.2.2
type FailedToReadTypeError struct {
Previous error
}
func (*FailedToReadTypeError) Error ¶ added in v0.2.2
func (err *FailedToReadTypeError) Error() string
func (*FailedToReadTypeError) Unwrap ¶ added in v0.2.2
func (err *FailedToReadTypeError) Unwrap() error
type InvalidUnmarshalError ¶
func (*InvalidUnmarshalError) Error ¶
func (e *InvalidUnmarshalError) Error() string
type UnknownValueError ¶
func (*UnknownValueError) Error ¶
func (e *UnknownValueError) Error() string
type Unmarshaler ¶ added in v0.2.0
Click to show internal directories.
Click to hide internal directories.