loader

package
v0.36.0 Latest Latest
Warning

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

Go to latest
Published: Dec 10, 2022 License: BSD-3-Clause Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func String added in v0.34.0

func String(b []byte, name string) string

Types

type L

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

L provides panicking reading and integer decoding methods.

func Get added in v0.35.0

func Get(load Loader) *L

func New added in v0.34.0

func New(r binary.Reader, offset int64) *L

func (*L) Byte

func (load *L) Byte() byte

func (*L) Bytes

func (load *L) Bytes(n uint32) (data []byte)

func (*L) Count

func (load *L) Count(max int, name string) int

Count reads a varuint32.

func (*L) Discard added in v0.35.0

func (load *L) Discard(count uint32)

func (*L) Into

func (load *L) Into(buf []byte)

func (*L) Read added in v0.34.0

func (load *L) Read(buf []byte) (int, error)

Read doesn't panic, but returns an error.

func (*L) ReadByte added in v0.34.0

func (load *L) ReadByte() (byte, error)

ReadByte doesn't panic, but returns an error.

func (*L) Span added in v0.34.0

func (load *L) Span(max int, name string) []struct{}

Span reads a varuint32 for iteration.

func (*L) String added in v0.34.0

func (load *L) String(n uint32, name string) string

func (*L) Tell added in v0.34.0

func (load *L) Tell() int64

Tell how many bytes have been read.

func (*L) Uint32

func (load *L) Uint32() uint32

func (*L) Uint64

func (load *L) Uint64() uint64

func (*L) UnreadByte added in v0.34.0

func (load *L) UnreadByte() error

UnreadByte doesn't panic, but returns an error.

func (*L) Varint32

func (load *L) Varint32() int32

func (*L) Varint64

func (load *L) Varint64() int64

func (*L) Varint7

func (load *L) Varint7() int8

func (*L) Varuint1

func (load *L) Varuint1() bool

func (*L) Varuint32

func (load *L) Varuint32() uint32

func (*L) Varuint64

func (load *L) Varuint64() uint64

type Loader added in v0.35.0

type Loader interface {
	binary.Reader
	// contains filtered or unexported methods
}

Jump to

Keyboard shortcuts

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