ebml

package
v0.3.0 Latest Latest
Warning

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

Go to latest
Published: Dec 20, 2025 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ReadVINT

func ReadVINT(r io.Reader) (uint64, uint64, error)

ReadVINT reads a Variable-Size Integer. Returns the integer and VINT representation. SEE: https://github.com/ietf-wg-cellar/ebml-specification/blob/master/specification.markdown#variable-size-integer.

Types

type ElementHeader

type ElementHeader struct {
	// Tag is the unique VINT-encoded tag of the element.
	Tag uint64
	// DataSize defines how many bytes of data the element contains.
	DataSize uint64
}

type Reader

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

Reader reads EBML elements.

func NewReader

func NewReader(reader io.Reader) *Reader

NewReader creates a new Reader that will read from reader.

func (*Reader) Discard

func (r *Reader) Discard() (int64, error)

Discard discards the current element's data.

func (*Reader) NextElement

func (r *Reader) NextElement() (uint64, uint64, error)

NextElement reads the next element's header.

func (*Reader) Read

func (r *Reader) Read(p []byte) (int, error)

Read reads from the current element's data.

func (*Reader) Reader

func (r *Reader) Reader() io.Reader

Reader returns the current element's data reader.

Jump to

Keyboard shortcuts

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