stonejson

package
v0.0.18 Latest Latest
Warning

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

Go to latest
Published: Oct 31, 2026 License: AGPL-3.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

View Source
const (
	TypeUnknown uint8 = iota
	TypeNull
	TypeNumber
	TypeString
	TypeBool
	TypeObject
	TypeArray
)

Definimos tipos internos para evitar lógica pesada

Variables

This section is empty.

Functions

This section is empty.

Types

type ObjectJSON

type ObjectJSON struct {
	Data   []byte       // Referencia al JSON original (el "bloque de piedra")
	Keys   []string     // Nombres de las llaves
	Coords []ValueCoord // Coordenadas de los valores en el bloque Data
}

func ParseToOffsets

func ParseToOffsets(data []byte) (*ObjectJSON, error)

ParseToOffsets escanea el JSON y anota dónde está cada valor sin hacer copias

func (*ObjectJSON) Get

func (o *ObjectJSON) Get(key string) any

type ValueCoord

type ValueCoord struct {
	Offset uint32
	Length uint32
	Type   uint8 // Representa String, Number, Bool, etc.
}

Jump to

Keyboard shortcuts

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