kvpacker

package
v0.0.0-...-62eada6 Latest Latest
Warning

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

Go to latest
Published: Sep 12, 2023 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Data

type Data []Var

func (Data) MarshalBinary

func (d Data) MarshalBinary() ([]byte, error)

func (*Data) UnmarshalBinary

func (d *Data) UnmarshalBinary(b []byte) error

type Type

type Type uint8
const (
	None            Type = iota // contains child key/value pairs
	String                      // utf-8 string (no 00 bytes)
	Int                         // 32-bit signed integer
	Float                       // 32-bit float
	Ptr                         // 32-bit pointer (deprecated)
	WString                     // utf-16 string
	Color                       // RGBA8888 color
	Uint64                      // 64-bit unsigned integer
	CompiledIntByte             // 8-bit signed integer
	CompiledInt0                // integer (can only be 0)
	CompiledInt1                // integer (can only be 1)

)

func (Type) String

func (i Type) String() string

type Var

type Var struct {
	Type Type
	Name string

	// The field that is set below is based on Type.
	None    Data
	String  string
	Int     int32
	Float   float32
	Ptr     uint32
	WString []uint16
	Color   color.RGBA
	Uint64  uint64
}

Jump to

Keyboard shortcuts

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