ledgerwire

package
v1.5.2 Latest Latest
Warning

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

Go to latest
Published: Oct 17, 2026 License: MIT Imports: 12 Imported by: 0

Documentation

Overview

Package ledgerwire is the variable table wire for ledger keys and values, cairn log records, fuse boxes and dogfood receipts, generated from schemas/ledger/. Every other .go file here is generated: edit the schema and run go generate ./pkg/ledgerwire, never the output.

Index

Constants

View Source
const (
	TableFixedReasonPreviousForm         = "previous_form"
	TableFixedReasonMessageFormAsFile    = "message_form_as_file"
	TableFixedReasonNewerForm            = "newer_form"
	TableFixedReasonLayoutMalformed      = "layout_malformed"
	TableFixedReasonLayoutUnknown        = "layout_unknown"
	TableFixedReasonLayoutNewer          = "layout_newer"
	TableFixedReasonLayoutUnsupported    = "layout_unsupported"
	TableFixedReasonLayoutRecordTooLarge = "layout_record_too_large"
	TableFixedReasonPlanTooLarge         = "plan_too_large"
	TableFixedReasonBatchTooLarge        = "batch_too_large"
	TableFixedReasonNoLayout             = "no_layout"
	TableFixedReasonTextIllFormed        = "text_ill_formed"
	TableFixedReasonTruncated            = "truncated"
	TableFixedReasonReservedNotZero      = "reserved_not_zero"
)

THE FIXED LOAD'S REFUSAL NAMES — EXPORTED (mas-bandwidth/schema docs/FIXED-FORM-ALGORITHM.md §5.3, mas-bandwidth/schema docs/SPEC-TABLES.md §3.4). Every refusal of the fixed load has a name, the framing-damage returns included, so an adopter's existing report.Reason == "layout_newer" comparisons keep compiling against these constants; the emitted <T>FixedLoad names every reason constant in place of a string literal.

TableFixedReasonLayoutUnknown is the Reason of a file whose header hash no entry of this build's lineage holds (mas-bandwidth/schema docs/SPEC-TABLES.md §21.3, algorithm §5.3 step 5). It says what the reader knows and not which way the file lies: a newer writer's layout, an older one nobody locked and a damaged hash byte read the same.

TableFixedReasonLayoutNewer ("ship the reader") is RESERVED (SPEC-TABLES §21.3) for a hash the lock lineage proves newer, which nothing on the wire or in the lock does today, so no Go fixed load answers it; it stays exported so an adopter's existing comparisons keep compiling.

View Source
const BuildVersion uint64 = 0xfe5142578e5bf42d

BuildVersion is the unit's build version (mas-bandwidth/schema docs/SPEC-TABLES.md §20): the one digest a block carries and BlockOpen compares, and the fact §3.3's announcement carries before the first body so a peer's build is knowable.

View Source
const CairnLogRecordLoadRetainBuilder = "CairnLogRecord: retention requires a region round trip through the VARIABLE form"
View Source
const CairnLogRecordSaveRetainMessages = "CairnLogRecord: retention requires a region round trip through the VARIABLE form"
View Source
const DogfoodReceiptLoadRetainBuilder = "DogfoodReceipt: retention requires a region round trip through the VARIABLE form"
View Source
const DogfoodReceiptSaveRetainMessages = "DogfoodReceipt: retention requires a region round trip through the VARIABLE form"
View Source
const FuseBoxLoadRetainBuilder = "FuseBox: retention requires a region round trip through the VARIABLE form"
View Source
const FuseBoxSaveRetainMessages = "FuseBox: retention requires a region round trip through the VARIABLE form"
View Source
const FuseLoadRetainBuilder = "Fuse: retention requires a region round trip through the VARIABLE form"
View Source
const FuseSaveRetainMessages = "Fuse: retention requires a region round trip through the VARIABLE form"
View Source
const LedgerKeyLoadRetainBuilder = "LedgerKey: retention requires a region round trip through the VARIABLE form"
View Source
const LedgerKeySaveRetainMessages = "LedgerKey: retention requires a region round trip through the VARIABLE form"
View Source
const LedgerValueLoadRetainBuilder = "LedgerValue: retention requires a region round trip through the VARIABLE form"
View Source
const LedgerValueSaveRetainMessages = "LedgerValue: retention requires a region round trip through the VARIABLE form"
View Source
const ProtocolId uint64 = 0x18e1896995290a87

The unit's protocol id — the hash of its wire shape (SPEC §3.1). Two sides at the same id speak identical bits; there is no other versioning.

View Source
const QuarantineEntryLoadRetainBuilder = "QuarantineEntry: retention requires a region round trip through the VARIABLE form"
View Source
const QuarantineEntrySaveRetainMessages = "QuarantineEntry: retention requires a region round trip through the VARIABLE form"
View Source
const TableCookHeaderBytes int64 = 64

TableCookHeaderBytes is §7.1's header: 64 bytes of u64 words. The DATA part begins at align_up(64, alignment) — DERIVED and not a header field, because a fact a reader computes is a fact two writers cannot disagree about.

View Source
const TableCookMagic uint64 = 0x4b4f4f434d484353

TableCookMagic is the cook's magic (mas-bandwidth/schema docs/SPEC-TABLES.md §7.1), read before anything else: it is what establishes the byte order every other header word is written in, and it is also what separates a COOK from a BLOCK — the two accelerators carry the same build version and different magics, because a form's identity belongs in its magic rather than in a second digest.

The value is "SCHMCOOK" read as ASCII in the byte order a little-endian store produces, so a hex dump of a little-endian cook is legible.

View Source
const TableCookMaxAlign int64 = 64

TableCookMaxAlign is the ceiling on the header's alignment word: the same sixty-four a block's base takes (§19.1), past which the derived data offset would no longer be the 64 every unit this language can declare produces.

View Source
const TableDocNone = ""

THE SHARED EMPTY DOC (mas-bandwidth/schema docs/SPEC-TABLES.md §8.1): a declaration with no /// block carries a doc column naming this one definition, so absence costs a unit no string data and a printer concatenates doc columns with no nil test. Go gives a string no address identity, so what the rule is READ OFF here is the emitted text: the generated file defines the empty doc once and every unannotated row names that definition, rather than each row carrying an inline "" of its own.

View Source
const TableFixedForm uint8 = 3
View Source
const TableFixedHashAt = 8
View Source
const TableFixedHeaderBytes = 16
View Source
const TableMessageBatchMax = 256
View Source
const TableMessageEntriesHere = 46
View Source
const TableMessageRefBitsHere = 6
View Source
const TokenValueLoadRetainBuilder = "TokenValue: retention requires a region round trip through the VARIABLE form"
View Source
const TokenValueSaveRetainMessages = "TokenValue: retention requires a region round trip through the VARIABLE form"

Variables

View Source
var CairnLogRecordTableFields = []TableFieldInfo{
	{Name: "event_kind", Json: "event", TypeName: "CairnEvent", DeclaredTypeName: "CairnEvent", Id: 0x517a4505d602bca2, Kind: 30, IsArray: false, Counted: false, Optional: false,
		ArrayBound: 0, Offset: uint32(unsafe.Offsetof(CairnLogRecord{}.EventKind)), ElemSize: uint32(unsafe.Sizeof(CairnLogRecord{}.EventKind)), CountOffset: 0xffffffff, PresentOffset: 0xffffffff,
		CookOffset: 0, CookElemSize: 1, CookCountOffset: 4294967295, CookPresentOffset: 4294967295,
		HasRange: false, RangeMin: 0.0, RangeMax: 0.0, EnumMax: 2,
		FracBits: 0, Pointer: false, TargetId: 0x0000000000000000,
		EnumName:    func(v uint64) string { return EnumNameCairnEvent(CairnEvent(v)) },
		VariantId:   func(v uint64) uint64 { id, _ := CairnEvent(v).TableEnumId(); return id },
		KeyTypeName: "", KeyName: nil, KeyId: nil,
		Arms:  nil,
		Guard: "", Table: nil,
		Doc: TableDocNone, NumTags: 0, Tags: nil},
	{Name: "session", Json: "session", TypeName: "string", DeclaredTypeName: "string", Id: 0x3ca2c49553a457d7, Kind: 12, IsArray: false, Counted: true, Optional: false,
		ArrayBound: 128, Offset: uint32(unsafe.Offsetof(CairnLogRecord{}.Session)), ElemSize: uint32(unsafe.Sizeof(CairnLogRecord{}.Session)), CountOffset: uint32(unsafe.Offsetof(CairnLogRecord{}.SessionLength)), PresentOffset: 0xffffffff,
		CookOffset: 1, CookElemSize: 1, CookCountOffset: 132, CookPresentOffset: 4294967295,
		HasRange: false, RangeMin: 0.0, RangeMax: 0.0, EnumMax: -1,
		FracBits: 0, Pointer: false, TargetId: 0x0000000000000000,
		EnumName:    nil,
		VariantId:   nil,
		KeyTypeName: "", KeyName: nil, KeyId: nil,
		Arms:  nil,
		Guard: "", Table: nil,
		Doc: TableDocNone, NumTags: 0, Tags: nil},
	{Name: "entry", Json: "entry", TypeName: "string", DeclaredTypeName: "string", Id: 0xbe2a85bf4c0ca913, Kind: 12, IsArray: false, Counted: true, Optional: false,
		ArrayBound: 128, Offset: uint32(unsafe.Offsetof(CairnLogRecord{}.Entry)), ElemSize: uint32(unsafe.Sizeof(CairnLogRecord{}.Entry)), CountOffset: uint32(unsafe.Offsetof(CairnLogRecord{}.EntryLength)), PresentOffset: 0xffffffff,
		CookOffset: 136, CookElemSize: 1, CookCountOffset: 268, CookPresentOffset: 4294967295,
		HasRange: false, RangeMin: 0.0, RangeMax: 0.0, EnumMax: -1,
		FracBits: 0, Pointer: false, TargetId: 0x0000000000000000,
		EnumName:    nil,
		VariantId:   nil,
		KeyTypeName: "", KeyName: nil, KeyId: nil,
		Arms:  nil,
		Guard: "", Table: nil,
		Doc: TableDocNone, NumTags: 0, Tags: nil},
	{Name: "stamp", Json: "stamp", TypeName: "string", DeclaredTypeName: "string", Id: 0xee7ba9ad45c64144, Kind: 17, IsArray: false, Counted: false, Optional: false,
		ArrayBound: 0, Offset: uint32(unsafe.Offsetof(CairnLogRecord{}.Stamp)), ElemSize: uint32(unsafe.Sizeof(CairnLogRecord{}.Stamp)), CountOffset: 0xffffffff, PresentOffset: 0xffffffff,
		CookOffset: 272, CookElemSize: 8, CookCountOffset: 4294967295, CookPresentOffset: 4294967295,
		HasRange: false, RangeMin: 0.0, RangeMax: 0.0, EnumMax: -1,
		FracBits: 0, Pointer: true, TargetId: 0x704be0d8faaffc58,
		EnumName:    nil,
		VariantId:   nil,
		KeyTypeName: "", KeyName: nil, KeyId: nil,
		Arms:  nil,
		Guard: "", Table: nil,
		Doc: TableDocNone, NumTags: 0, Tags: nil},
	{Name: "publish", Json: "publish", TypeName: "PublishPolicy", DeclaredTypeName: "PublishPolicy", Id: 0xe2bfe8411c472768, Kind: 30, IsArray: false, Counted: false, Optional: false,
		ArrayBound: 0, Offset: uint32(unsafe.Offsetof(CairnLogRecord{}.Publish)), ElemSize: uint32(unsafe.Sizeof(CairnLogRecord{}.Publish)), CountOffset: 0xffffffff, PresentOffset: 0xffffffff,
		CookOffset: 280, CookElemSize: 1, CookCountOffset: 4294967295, CookPresentOffset: 4294967295,
		HasRange: false, RangeMin: 0.0, RangeMax: 0.0, EnumMax: 4,
		FracBits: 0, Pointer: false, TargetId: 0x0000000000000000,
		EnumName:    func(v uint64) string { return EnumNamePublishPolicy(PublishPolicy(v)) },
		VariantId:   func(v uint64) uint64 { id, _ := PublishPolicy(v).TableEnumId(); return id },
		KeyTypeName: "", KeyName: nil, KeyId: nil,
		Arms:  nil,
		Guard: "", Table: nil,
		Doc: TableDocNone, NumTags: 0, Tags: nil},
	{Name: "source", Json: "source", TypeName: "string", DeclaredTypeName: "string", Id: 0x76dbdc228f782db8, Kind: 17, IsArray: false, Counted: false, Optional: false,
		ArrayBound: 0, Offset: uint32(unsafe.Offsetof(CairnLogRecord{}.Source)), ElemSize: uint32(unsafe.Sizeof(CairnLogRecord{}.Source)), CountOffset: 0xffffffff, PresentOffset: 0xffffffff,
		CookOffset: 288, CookElemSize: 8, CookCountOffset: 4294967295, CookPresentOffset: 4294967295,
		HasRange: false, RangeMin: 0.0, RangeMax: 0.0, EnumMax: -1,
		FracBits: 0, Pointer: true, TargetId: 0x704be0d8faaffc58,
		EnumName:    nil,
		VariantId:   nil,
		KeyTypeName: "", KeyName: nil, KeyId: nil,
		Arms:  nil,
		Guard: "", Table: nil,
		Doc: TableDocNone, NumTags: 0, Tags: nil},
}

CairnLogRecordTableFields is CairnLogRecord's per-field reflection data (mas-bandwidth/schema docs/SPEC-TABLES.md §8).

View Source
var DogfoodReceiptTableFields = []TableFieldInfo{
	{Name: "tool", Json: "tool", TypeName: "string", DeclaredTypeName: "string", Id: 0x2fe3f0ef38a252c7, Kind: 17, IsArray: false, Counted: false, Optional: false,
		ArrayBound: 0, Offset: uint32(unsafe.Offsetof(DogfoodReceipt{}.Tool)), ElemSize: uint32(unsafe.Sizeof(DogfoodReceipt{}.Tool)), CountOffset: 0xffffffff, PresentOffset: 0xffffffff,
		CookOffset: 0, CookElemSize: 8, CookCountOffset: 4294967295, CookPresentOffset: 4294967295,
		HasRange: false, RangeMin: 0.0, RangeMax: 0.0, EnumMax: -1,
		FracBits: 0, Pointer: true, TargetId: 0x704be0d8faaffc58,
		EnumName:    nil,
		VariantId:   nil,
		KeyTypeName: "", KeyName: nil, KeyId: nil,
		Arms:  nil,
		Guard: "", Table: nil,
		Doc: TableDocNone, NumTags: 0, Tags: nil},
	{Name: "verb", Json: "verb", TypeName: "string", DeclaredTypeName: "string", Id: 0x673ebb0102773a20, Kind: 17, IsArray: false, Counted: false, Optional: false,
		ArrayBound: 0, Offset: uint32(unsafe.Offsetof(DogfoodReceipt{}.Verb)), ElemSize: uint32(unsafe.Sizeof(DogfoodReceipt{}.Verb)), CountOffset: 0xffffffff, PresentOffset: 0xffffffff,
		CookOffset: 8, CookElemSize: 8, CookCountOffset: 4294967295, CookPresentOffset: 4294967295,
		HasRange: false, RangeMin: 0.0, RangeMax: 0.0, EnumMax: -1,
		FracBits: 0, Pointer: true, TargetId: 0x704be0d8faaffc58,
		EnumName:    nil,
		VariantId:   nil,
		KeyTypeName: "", KeyName: nil, KeyId: nil,
		Arms:  nil,
		Guard: "", Table: nil,
		Doc: TableDocNone, NumTags: 0, Tags: nil},
	{Name: "by", Json: "by", TypeName: "string", DeclaredTypeName: "string", Id: 0x8a64b07b54df8d4, Kind: 17, IsArray: false, Counted: false, Optional: false,
		ArrayBound: 0, Offset: uint32(unsafe.Offsetof(DogfoodReceipt{}.By)), ElemSize: uint32(unsafe.Sizeof(DogfoodReceipt{}.By)), CountOffset: 0xffffffff, PresentOffset: 0xffffffff,
		CookOffset: 16, CookElemSize: 8, CookCountOffset: 4294967295, CookPresentOffset: 4294967295,
		HasRange: false, RangeMin: 0.0, RangeMax: 0.0, EnumMax: -1,
		FracBits: 0, Pointer: true, TargetId: 0x704be0d8faaffc58,
		EnumName:    nil,
		VariantId:   nil,
		KeyTypeName: "", KeyName: nil, KeyId: nil,
		Arms:  nil,
		Guard: "", Table: nil,
		Doc: TableDocNone, NumTags: 0, Tags: nil},
	{Name: "at", Json: "at", TypeName: "string", DeclaredTypeName: "string", Id: 0x89c4e07b545a968, Kind: 17, IsArray: false, Counted: false, Optional: false,
		ArrayBound: 0, Offset: uint32(unsafe.Offsetof(DogfoodReceipt{}.At)), ElemSize: uint32(unsafe.Sizeof(DogfoodReceipt{}.At)), CountOffset: 0xffffffff, PresentOffset: 0xffffffff,
		CookOffset: 24, CookElemSize: 8, CookCountOffset: 4294967295, CookPresentOffset: 4294967295,
		HasRange: false, RangeMin: 0.0, RangeMax: 0.0, EnumMax: -1,
		FracBits: 0, Pointer: true, TargetId: 0x704be0d8faaffc58,
		EnumName:    nil,
		VariantId:   nil,
		KeyTypeName: "", KeyName: nil, KeyId: nil,
		Arms:  nil,
		Guard: "", Table: nil,
		Doc: TableDocNone, NumTags: 0, Tags: nil},
	{Name: "ok", Json: "ok", TypeName: "bool", DeclaredTypeName: "bool", Id: 0x8b05d07b5566bef, Kind: 1, IsArray: false, Counted: false, Optional: false,
		ArrayBound: 0, Offset: uint32(unsafe.Offsetof(DogfoodReceipt{}.Ok)), ElemSize: uint32(unsafe.Sizeof(DogfoodReceipt{}.Ok)), CountOffset: 0xffffffff, PresentOffset: 0xffffffff,
		CookOffset: 32, CookElemSize: 1, CookCountOffset: 4294967295, CookPresentOffset: 4294967295,
		HasRange: false, RangeMin: 0.0, RangeMax: 0.0, EnumMax: -1,
		FracBits: 0, Pointer: false, TargetId: 0x0000000000000000,
		EnumName:    nil,
		VariantId:   nil,
		KeyTypeName: "", KeyName: nil, KeyId: nil,
		Arms:  nil,
		Guard: "", Table: nil,
		Doc: TableDocNone, NumTags: 0, Tags: nil},
	{Name: "notes", Json: "notes", TypeName: "string", DeclaredTypeName: "string", Id: 0x40906c71b95bdbaa, Kind: 17, IsArray: false, Counted: false, Optional: false,
		ArrayBound: 0, Offset: uint32(unsafe.Offsetof(DogfoodReceipt{}.Notes)), ElemSize: uint32(unsafe.Sizeof(DogfoodReceipt{}.Notes)), CountOffset: 0xffffffff, PresentOffset: 0xffffffff,
		CookOffset: 40, CookElemSize: 8, CookCountOffset: 4294967295, CookPresentOffset: 4294967295,
		HasRange: false, RangeMin: 0.0, RangeMax: 0.0, EnumMax: -1,
		FracBits: 0, Pointer: true, TargetId: 0x704be0d8faaffc58,
		EnumName:    nil,
		VariantId:   nil,
		KeyTypeName: "", KeyName: nil, KeyId: nil,
		Arms:  nil,
		Guard: "", Table: nil,
		Doc: TableDocNone, NumTags: 0, Tags: nil},
	{Name: "issue", Json: "issue", TypeName: "int64", DeclaredTypeName: "int64", Id: 0x1c54d4fa8357f520, Kind: 5, IsArray: false, Counted: false, Optional: true,
		ArrayBound: 0, Offset: uint32(unsafe.Offsetof(DogfoodReceipt{}.Issue)), ElemSize: uint32(unsafe.Sizeof(DogfoodReceipt{}.Issue)), CountOffset: 0xffffffff, PresentOffset: uint32(unsafe.Offsetof(DogfoodReceipt{}.IssuePresent)),
		CookOffset: 48, CookElemSize: 8, CookCountOffset: 4294967295, CookPresentOffset: 56,
		HasRange: true, RangeMin: 0.0, RangeMax: 9.223372036854776e+18, EnumMax: -1,
		FracBits: 0, Pointer: false, TargetId: 0x0000000000000000,
		EnumName:    nil,
		VariantId:   nil,
		KeyTypeName: "", KeyName: nil, KeyId: nil,
		Arms:  nil,
		Guard: "", Table: nil,
		Doc: TableDocNone, NumTags: 0, Tags: nil},
	{Name: "closes", Json: "closes", TypeName: "string", DeclaredTypeName: "string", Id: 0x8553185090e84610, Kind: 17, IsArray: false, Counted: false, Optional: false,
		ArrayBound: 0, Offset: uint32(unsafe.Offsetof(DogfoodReceipt{}.Closes)), ElemSize: uint32(unsafe.Sizeof(DogfoodReceipt{}.Closes)), CountOffset: 0xffffffff, PresentOffset: 0xffffffff,
		CookOffset: 64, CookElemSize: 8, CookCountOffset: 4294967295, CookPresentOffset: 4294967295,
		HasRange: false, RangeMin: 0.0, RangeMax: 0.0, EnumMax: -1,
		FracBits: 0, Pointer: true, TargetId: 0x704be0d8faaffc58,
		EnumName:    nil,
		VariantId:   nil,
		KeyTypeName: "", KeyName: nil, KeyId: nil,
		Arms:  nil,
		Guard: "", Table: nil,
		Doc: TableDocNone, NumTags: 0, Tags: nil},
}

DogfoodReceiptTableFields is DogfoodReceipt's per-field reflection data (mas-bandwidth/schema docs/SPEC-TABLES.md §8).

View Source
var ErrValidation = errors.New("ledgerwire: wire validation failed")

ErrValidation is returned when a read rejects the wire: a wrong constant, nonzero reserved bits, or an interior null in a string (SPEC §4.3, §4.7).

View Source
var FuseBoxTableFields = []TableFieldInfo{
	{Name: "lockdown", Json: "lockdown", TypeName: "Fuse", DeclaredTypeName: "Fuse", Id: 0x587fb5f7217333da, Kind: 17, IsArray: false, Counted: false, Optional: false,
		ArrayBound: 0, Offset: uint32(unsafe.Offsetof(FuseBox{}.Lockdown)), ElemSize: uint32(unsafe.Sizeof(FuseBox{}.Lockdown)), CountOffset: 0xffffffff, PresentOffset: 0xffffffff,
		CookOffset: 0, CookElemSize: 8, CookCountOffset: 4294967295, CookPresentOffset: 4294967295,
		HasRange: false, RangeMin: 0.0, RangeMax: 0.0, EnumMax: -1,
		FracBits: 0, Pointer: true, TargetId: 0xb11c6e84dc9ca810,
		EnumName:    nil,
		VariantId:   nil,
		KeyTypeName: "", KeyName: nil, KeyId: nil,
		Arms:  nil,
		Guard: "", Table: FuseTableType,
		Doc: TableDocNone, NumTags: 0, Tags: nil},
	{Name: "quarantine", Json: "quarantine", TypeName: "QuarantineEntry", DeclaredTypeName: "QuarantineEntry", Id: 0x7ecc5a61e15573d1, Kind: 13, IsArray: true, Counted: true, Optional: false,
		ArrayBound: 2147483647, Offset: uint32(unsafe.Offsetof(FuseBox{}.Quarantine)), ElemSize: uint32(unsafe.Sizeof(*new(QuarantineEntryRow))), CountOffset: (uint32(unsafe.Offsetof(FuseBox{}.Quarantine))) + 8, PresentOffset: 0xffffffff,
		CookOffset: 8, CookElemSize: 24, CookCountOffset: 16, CookPresentOffset: 4294967295,
		HasRange: false, RangeMin: 0.0, RangeMax: 0.0, EnumMax: -1,
		List: true, ElemAlign: 8,
		FracBits: 0, Pointer: false, TargetId: 0x0000000000000000,
		EnumName:    nil,
		VariantId:   nil,
		KeyTypeName: "", KeyName: nil, KeyId: nil,
		Arms:  nil,
		Guard: "", Table: QuarantineEntryTableType,
		Doc: TableDocNone, NumTags: 0, Tags: nil},
}

FuseBoxTableFields is FuseBox's per-field reflection data (mas-bandwidth/schema docs/SPEC-TABLES.md §8).

View Source
var FuseTableFields = []TableFieldInfo{
	{Name: "at", Json: "at", TypeName: "string", DeclaredTypeName: "string", Id: 0x89c4e07b545a968, Kind: 17, IsArray: false, Counted: false, Optional: false,
		ArrayBound: 0, Offset: uint32(unsafe.Offsetof(Fuse{}.At)), ElemSize: uint32(unsafe.Sizeof(Fuse{}.At)), CountOffset: 0xffffffff, PresentOffset: 0xffffffff,
		CookOffset: 0, CookElemSize: 8, CookCountOffset: 4294967295, CookPresentOffset: 4294967295,
		HasRange: false, RangeMin: 0.0, RangeMax: 0.0, EnumMax: -1,
		FracBits: 0, Pointer: true, TargetId: 0x704be0d8faaffc58,
		EnumName:    nil,
		VariantId:   nil,
		KeyTypeName: "", KeyName: nil, KeyId: nil,
		Arms:  nil,
		Guard: "", Table: nil,
		Doc: TableDocNone, NumTags: 0, Tags: nil},
	{Name: "reason", Json: "reason", TypeName: "string", DeclaredTypeName: "string", Id: 0x65e8d7f3474f2639, Kind: 17, IsArray: false, Counted: false, Optional: false,
		ArrayBound: 0, Offset: uint32(unsafe.Offsetof(Fuse{}.Reason)), ElemSize: uint32(unsafe.Sizeof(Fuse{}.Reason)), CountOffset: 0xffffffff, PresentOffset: 0xffffffff,
		CookOffset: 8, CookElemSize: 8, CookCountOffset: 4294967295, CookPresentOffset: 4294967295,
		HasRange: false, RangeMin: 0.0, RangeMax: 0.0, EnumMax: -1,
		FracBits: 0, Pointer: true, TargetId: 0x704be0d8faaffc58,
		EnumName:    nil,
		VariantId:   nil,
		KeyTypeName: "", KeyName: nil, KeyId: nil,
		Arms:  nil,
		Guard: "", Table: nil,
		Doc: TableDocNone, NumTags: 0, Tags: nil},
}

FuseTableFields is Fuse's per-field reflection data (mas-bandwidth/schema docs/SPEC-TABLES.md §8).

View Source
var LedgerKeyTableFields = []TableFieldInfo{
	{Name: "day", Json: "day", TypeName: "string", DeclaredTypeName: "string", Id: 0xca8d3918f4578f1d, Kind: 12, IsArray: false, Counted: true, Optional: false,
		ArrayBound: 10, Offset: uint32(unsafe.Offsetof(LedgerKey{}.Day)), ElemSize: uint32(unsafe.Sizeof(LedgerKey{}.Day)), CountOffset: uint32(unsafe.Offsetof(LedgerKey{}.DayLength)), PresentOffset: 0xffffffff,
		CookOffset: 0, CookElemSize: 1, CookCountOffset: 12, CookPresentOffset: 4294967295,
		HasRange: false, RangeMin: 0.0, RangeMax: 0.0, EnumMax: -1,
		FracBits: 0, Pointer: false, TargetId: 0x0000000000000000,
		EnumName:    nil,
		VariantId:   nil,
		KeyTypeName: "", KeyName: nil, KeyId: nil,
		Arms:  nil,
		Guard: "", Table: nil,
		Doc: TableDocNone, NumTags: 0, Tags: nil},
	{Name: "card", Json: "card", TypeName: "string", DeclaredTypeName: "string", Id: 0xb5614e90e87b455f, Kind: 17, IsArray: false, Counted: false, Optional: false,
		ArrayBound: 0, Offset: uint32(unsafe.Offsetof(LedgerKey{}.Card)), ElemSize: uint32(unsafe.Sizeof(LedgerKey{}.Card)), CountOffset: 0xffffffff, PresentOffset: 0xffffffff,
		CookOffset: 16, CookElemSize: 8, CookCountOffset: 4294967295, CookPresentOffset: 4294967295,
		HasRange: false, RangeMin: 0.0, RangeMax: 0.0, EnumMax: -1,
		FracBits: 0, Pointer: true, TargetId: 0x704be0d8faaffc58,
		EnumName:    nil,
		VariantId:   nil,
		KeyTypeName: "", KeyName: nil, KeyId: nil,
		Arms:  nil,
		Guard: "", Table: nil,
		Doc: TableDocNone, NumTags: 0, Tags: nil},
	{Name: "model", Json: "model", TypeName: "string", DeclaredTypeName: "string", Id: 0x9de543933e6e703a, Kind: 17, IsArray: false, Counted: false, Optional: false,
		ArrayBound: 0, Offset: uint32(unsafe.Offsetof(LedgerKey{}.Model)), ElemSize: uint32(unsafe.Sizeof(LedgerKey{}.Model)), CountOffset: 0xffffffff, PresentOffset: 0xffffffff,
		CookOffset: 24, CookElemSize: 8, CookCountOffset: 4294967295, CookPresentOffset: 4294967295,
		HasRange: false, RangeMin: 0.0, RangeMax: 0.0, EnumMax: -1,
		FracBits: 0, Pointer: true, TargetId: 0x704be0d8faaffc58,
		EnumName:    nil,
		VariantId:   nil,
		KeyTypeName: "", KeyName: nil, KeyId: nil,
		Arms:  nil,
		Guard: "", Table: nil,
		Doc: TableDocNone, NumTags: 0, Tags: nil},
	{Name: "repo", Json: "repo", TypeName: "string", DeclaredTypeName: "string", Id: 0x4cac581fbfac663d, Kind: 17, IsArray: false, Counted: false, Optional: false,
		ArrayBound: 0, Offset: uint32(unsafe.Offsetof(LedgerKey{}.Repo)), ElemSize: uint32(unsafe.Sizeof(LedgerKey{}.Repo)), CountOffset: 0xffffffff, PresentOffset: 0xffffffff,
		CookOffset: 32, CookElemSize: 8, CookCountOffset: 4294967295, CookPresentOffset: 4294967295,
		HasRange: false, RangeMin: 0.0, RangeMax: 0.0, EnumMax: -1,
		FracBits: 0, Pointer: true, TargetId: 0x704be0d8faaffc58,
		EnumName:    nil,
		VariantId:   nil,
		KeyTypeName: "", KeyName: nil, KeyId: nil,
		Arms:  nil,
		Guard: "", Table: nil,
		Doc: TableDocNone, NumTags: 0, Tags: nil},
}

LedgerKeyTableFields is LedgerKey's per-field reflection data (mas-bandwidth/schema docs/SPEC-TABLES.md §8).

View Source
var LedgerValueTableFields = []TableFieldInfo{
	{Name: "provider", Json: "provider", TypeName: "string", DeclaredTypeName: "string", Id: 0xd02b4c8c65fb54dc, Kind: 17, IsArray: false, Counted: false, Optional: false,
		ArrayBound: 0, Offset: uint32(unsafe.Offsetof(LedgerValue{}.Provider)), ElemSize: uint32(unsafe.Sizeof(LedgerValue{}.Provider)), CountOffset: 0xffffffff, PresentOffset: 0xffffffff,
		CookOffset: 0, CookElemSize: 8, CookCountOffset: 4294967295, CookPresentOffset: 4294967295,
		HasRange: false, RangeMin: 0.0, RangeMax: 0.0, EnumMax: -1,
		FracBits: 0, Pointer: true, TargetId: 0x704be0d8faaffc58,
		EnumName:    nil,
		VariantId:   nil,
		KeyTypeName: "", KeyName: nil, KeyId: nil,
		Arms:  nil,
		Guard: "", Table: nil,
		Doc: TableDocNone, NumTags: 0, Tags: nil},
	{Name: "tokens", Json: "tokens", TypeName: "TokenValue", DeclaredTypeName: "TokenValue", Id: 0x93fab8f021712b13, Kind: 13, IsArray: true, Counted: true, Optional: false,
		ArrayBound: 5, Offset: uint32(unsafe.Offsetof(LedgerValue{}.Tokens)), ElemSize: uint32(unsafe.Sizeof(LedgerValue{}.Tokens[0])), CountOffset: uint32(unsafe.Offsetof(LedgerValue{}.TokensCount)), PresentOffset: 0xffffffff,
		CookOffset: 8, CookElemSize: 16, CookCountOffset: 88, CookPresentOffset: 4294967295,
		HasRange: false, RangeMin: 0.0, RangeMax: 0.0, EnumMax: -1,
		FracBits: 0, Pointer: false, TargetId: 0x0000000000000000,
		EnumName:    nil,
		VariantId:   nil,
		KeyTypeName: "", KeyName: nil, KeyId: nil,
		Arms:  nil,
		Guard: "", Table: TokenValueTableType,
		Doc: TableDocNone, NumTags: 0, Tags: nil},
	{Name: "rough", Json: "rough", TypeName: "int64", DeclaredTypeName: "int64", Id: 0x30f50e469eeeb28e, Kind: 5, IsArray: false, Counted: false, Optional: false,
		ArrayBound: 0, Offset: uint32(unsafe.Offsetof(LedgerValue{}.Rough)), ElemSize: uint32(unsafe.Sizeof(LedgerValue{}.Rough)), CountOffset: 0xffffffff, PresentOffset: 0xffffffff,
		CookOffset: 96, CookElemSize: 8, CookCountOffset: 4294967295, CookPresentOffset: 4294967295,
		HasRange: false, RangeMin: 0.0, RangeMax: 0.0, EnumMax: -1,
		FracBits: 0, Pointer: false, TargetId: 0x0000000000000000,
		EnumName:    nil,
		VariantId:   nil,
		KeyTypeName: "", KeyName: nil, KeyId: nil,
		Arms:  nil,
		Guard: "", Table: nil,
		Doc: TableDocNone, NumTags: 0, Tags: nil},
	{Name: "sources", Json: "sources", TypeName: "string", DeclaredTypeName: "string", Id: 0x6fc4d9b9c935cff1, Kind: 17, IsArray: false, Counted: false, Optional: false,
		ArrayBound: 0, Offset: uint32(unsafe.Offsetof(LedgerValue{}.Sources)), ElemSize: uint32(unsafe.Sizeof(LedgerValue{}.Sources)), CountOffset: 0xffffffff, PresentOffset: 0xffffffff,
		CookOffset: 104, CookElemSize: 8, CookCountOffset: 4294967295, CookPresentOffset: 4294967295,
		HasRange: false, RangeMin: 0.0, RangeMax: 0.0, EnumMax: -1,
		FracBits: 0, Pointer: true, TargetId: 0x704be0d8faaffc58,
		EnumName:    nil,
		VariantId:   nil,
		KeyTypeName: "", KeyName: nil, KeyId: nil,
		Arms:  nil,
		Guard: "", Table: nil,
		Doc: TableDocNone, NumTags: 0, Tags: nil},
}

LedgerValueTableFields is LedgerValue's per-field reflection data (mas-bandwidth/schema docs/SPEC-TABLES.md §8).

View Source
var QuarantineEntryTableFields = []TableFieldInfo{
	{Name: "surface", Json: "surface", TypeName: "string", DeclaredTypeName: "string", Id: 0x18260d59cf7e151c, Kind: 17, IsArray: false, Counted: false, Optional: false,
		ArrayBound: 0, Offset: uint32(unsafe.Offsetof(QuarantineEntry{}.Surface)), ElemSize: uint32(unsafe.Sizeof(QuarantineEntry{}.Surface)), CountOffset: 0xffffffff, PresentOffset: 0xffffffff,
		CookOffset: 0, CookElemSize: 8, CookCountOffset: 4294967295, CookPresentOffset: 4294967295,
		HasRange: false, RangeMin: 0.0, RangeMax: 0.0, EnumMax: -1,
		FracBits: 0, Pointer: true, TargetId: 0x704be0d8faaffc58,
		EnumName:    nil,
		VariantId:   nil,
		KeyTypeName: "", KeyName: nil, KeyId: nil,
		Arms:  nil,
		Guard: "", Table: nil,
		Doc: TableDocNone, NumTags: 0, Tags: nil},
	{Name: "fuse", Json: "fuse", TypeName: "Fuse", DeclaredTypeName: "Fuse", Id: 0x868e6d78db2c3430, Kind: 13, IsArray: false, Counted: false, Optional: false,
		ArrayBound: 0, Offset: uint32(unsafe.Offsetof(QuarantineEntry{}.Fuse)), ElemSize: uint32(unsafe.Sizeof(QuarantineEntry{}.Fuse)), CountOffset: 0xffffffff, PresentOffset: 0xffffffff,
		CookOffset: 8, CookElemSize: 16, CookCountOffset: 4294967295, CookPresentOffset: 4294967295,
		HasRange: false, RangeMin: 0.0, RangeMax: 0.0, EnumMax: -1,
		FracBits: 0, Pointer: false, TargetId: 0x0000000000000000,
		EnumName:    nil,
		VariantId:   nil,
		KeyTypeName: "", KeyName: nil, KeyId: nil,
		Arms:  nil,
		Guard: "", Table: FuseTableType,
		Doc: TableDocNone, NumTags: 0, Tags: nil},
}

QuarantineEntryTableFields is QuarantineEntry's per-field reflection data (mas-bandwidth/schema docs/SPEC-TABLES.md §8).

View Source
var TableCookByteOrder = tableCookNativeOrder()

TableCookByteOrder is THIS BUILD's byte order, as §7.1's order word records it. The byte order is settled AT COOK TIME for the target build, so a matching build version already means a matching order and Open never fixes anything up; a cook whose recorded order is not this build's is simply not this build's file.

View Source
var TokenValueTableFields = []TableFieldInfo{
	{Name: "amount", Json: "amount", TypeName: "int64", DeclaredTypeName: "int64", Id: 0x8113fe7ea2b16969, Kind: 5, IsArray: false, Counted: false, Optional: true,
		ArrayBound: 0, Offset: uint32(unsafe.Offsetof(TokenValue{}.Amount)), ElemSize: uint32(unsafe.Sizeof(TokenValue{}.Amount)), CountOffset: 0xffffffff, PresentOffset: uint32(unsafe.Offsetof(TokenValue{}.AmountPresent)),
		CookOffset: 0, CookElemSize: 8, CookCountOffset: 4294967295, CookPresentOffset: 8,
		HasRange: false, RangeMin: 0.0, RangeMax: 0.0, EnumMax: -1,
		FracBits: 0, Pointer: false, TargetId: 0x0000000000000000,
		EnumName:    nil,
		VariantId:   nil,
		KeyTypeName: "", KeyName: nil, KeyId: nil,
		Arms:  nil,
		Guard: "", Table: nil,
		Doc: TableDocNone, NumTags: 0, Tags: nil},
}

TokenValueTableFields is TokenValue's per-field reflection data (mas-bandwidth/schema docs/SPEC-TABLES.md §8).

Functions

func Announce

func Announce(buffer []byte) int64

func AnnounceMeasure

func AnnounceMeasure() int64

func AnnounceRead

func AnnounceRead(v *TableVocabulary, data []byte, report *TableReport) bool

func CairnLogRecordCookFrom

func CairnLogRecordCookFrom(value *CairnLogRecord, buffer []byte, order TableByteOrder, context ...TableWriteContext) bool

func CairnLogRecordCookMeasure

func CairnLogRecordCookMeasure(value *CairnLogRecord, context ...TableWriteContext) int64

func CairnLogRecordCookMeasureReason

func CairnLogRecordCookMeasureReason(value *CairnLogRecord, context ...TableWriteContext) (int64, error)

func CairnLogRecordFromJson

func CairnLogRecordFromJson(builder *CairnLogRecordBuilder, text []byte, report *TableReport) bool

func CairnLogRecordLoadBody

func CairnLogRecordLoadBody(r *TableReader, value *CairnLogRecord) bool

func CairnLogRecordLoadBodyRetain

func CairnLogRecordLoadBodyRetain(r *TableRetainReader, value *CairnLogRecord) bool

func CairnLogRecordLoadBuilder

func CairnLogRecordLoadBuilder(b *CairnLogRecordBuilder, wire []byte, report *TableReport) bool

func CairnLogRecordLoadMeasure

func CairnLogRecordLoadMeasure(wire []byte) int64

func CairnLogRecordLoadMeasureReason

func CairnLogRecordLoadMeasureReason(wire []byte) (int64, error)

func CairnLogRecordLoadMessageBody

func CairnLogRecordLoadMessageBody(r *TableMessageReader, value *CairnLogRecord) bool

func CairnLogRecordLoadMessageBodyRetain

func CairnLogRecordLoadMessageBodyRetain(r *TableRetainMessageReader, value *CairnLogRecord) bool

func CairnLogRecordMeasure

func CairnLogRecordMeasure(value *CairnLogRecord, context ...TableWriteContext) int64

func CairnLogRecordMeasureBody

func CairnLogRecordMeasureBody(value *CairnLogRecord, ids *TableIds) int64

func CairnLogRecordMeasureBodyRetain

func CairnLogRecordMeasureBodyRetain(value *CairnLogRecord, ids *TableRetainIds) int64

func CairnLogRecordMeasureReason

func CairnLogRecordMeasureReason(value *CairnLogRecord, context ...TableWriteContext) (int64, error)

func CairnLogRecordMeasureRetain

func CairnLogRecordMeasureRetain(value *CairnLogRecord, retain *TableRetain, allocator ...TableAllocator) int64

func CairnLogRecordOpen

func CairnLogRecordOpen(cook *CairnLogRecordCook, base unsafe.Pointer, length int64) bool

CairnLogRecordOpen is the bool convenience for the typed Open error on the handle.

func CairnLogRecordReset

func CairnLogRecordReset(value *CairnLogRecord)

CairnLogRecordReset restores CairnLogRecord's declared defaults in place, reusing the storage the value already holds. The reader calls it before overlaying.

func CairnLogRecordSave

func CairnLogRecordSave(value *CairnLogRecord, buffer []byte, context ...TableWriteContext) int64

func CairnLogRecordSaveBody

func CairnLogRecordSaveBody(w *TableWriter, value *CairnLogRecord) bool

func CairnLogRecordSaveBodyFields

func CairnLogRecordSaveBodyFields(w *TableWriter, value *CairnLogRecord) bool

func CairnLogRecordSaveBodyFieldsRetain

func CairnLogRecordSaveBodyFieldsRetain(w *TableRetainWriter, value *CairnLogRecord) bool

func CairnLogRecordSaveBodyRetain

func CairnLogRecordSaveBodyRetain(w *TableRetainWriter, value *CairnLogRecord) bool

func CairnLogRecordSaveMessageBody

func CairnLogRecordSaveMessageBody(w *TableMessageWriter, value *CairnLogRecord) bool

func CairnLogRecordSaveRetain

func CairnLogRecordSaveRetain(value *CairnLogRecord, retain *TableRetain, buffer []byte, report *TableReport, allocator ...TableAllocator) int64

func CairnLogRecordSaveText

func CairnLogRecordSaveText(value *CairnLogRecord, context ...TableWriteContext) (string, error)

CairnLogRecordSaveText returns the base64 of CairnLogRecord's binary wire (mas-bandwidth/schema docs/SPEC-TABLES.md §16.8): the whole file, form byte first, so the text keeps the form byte, the framing check and every versioning guarantee and is opaque. It takes the write context CairnLogRecordSave takes.

func CairnLogRecordToJson

func CairnLogRecordToJson(value *CairnLogRecord, buffer []byte, allocator ...TableAllocator) int64

func CairnLogRecordToJsonMeasure

func CairnLogRecordToJsonMeasure(value *CairnLogRecord, allocator ...TableAllocator) int64

func DogfoodReceiptCookFrom

func DogfoodReceiptCookFrom(value *DogfoodReceipt, buffer []byte, order TableByteOrder, context ...TableWriteContext) bool

func DogfoodReceiptCookMeasure

func DogfoodReceiptCookMeasure(value *DogfoodReceipt, context ...TableWriteContext) int64

func DogfoodReceiptCookMeasureReason

func DogfoodReceiptCookMeasureReason(value *DogfoodReceipt, context ...TableWriteContext) (int64, error)

func DogfoodReceiptFromJson

func DogfoodReceiptFromJson(builder *DogfoodReceiptBuilder, text []byte, report *TableReport) bool

func DogfoodReceiptLoadBody

func DogfoodReceiptLoadBody(r *TableReader, value *DogfoodReceipt) bool

func DogfoodReceiptLoadBodyRetain

func DogfoodReceiptLoadBodyRetain(r *TableRetainReader, value *DogfoodReceipt) bool

func DogfoodReceiptLoadBuilder

func DogfoodReceiptLoadBuilder(b *DogfoodReceiptBuilder, wire []byte, report *TableReport) bool

func DogfoodReceiptLoadMeasure

func DogfoodReceiptLoadMeasure(wire []byte) int64

func DogfoodReceiptLoadMeasureReason

func DogfoodReceiptLoadMeasureReason(wire []byte) (int64, error)

func DogfoodReceiptLoadMessageBody

func DogfoodReceiptLoadMessageBody(r *TableMessageReader, value *DogfoodReceipt) bool

func DogfoodReceiptLoadMessageBodyRetain

func DogfoodReceiptLoadMessageBodyRetain(r *TableRetainMessageReader, value *DogfoodReceipt) bool

func DogfoodReceiptMeasure

func DogfoodReceiptMeasure(value *DogfoodReceipt, context ...TableWriteContext) int64

func DogfoodReceiptMeasureBody

func DogfoodReceiptMeasureBody(value *DogfoodReceipt, ids *TableIds) int64

func DogfoodReceiptMeasureBodyRetain

func DogfoodReceiptMeasureBodyRetain(value *DogfoodReceipt, ids *TableRetainIds) int64

func DogfoodReceiptMeasureReason

func DogfoodReceiptMeasureReason(value *DogfoodReceipt, context ...TableWriteContext) (int64, error)

func DogfoodReceiptMeasureRetain

func DogfoodReceiptMeasureRetain(value *DogfoodReceipt, retain *TableRetain, allocator ...TableAllocator) int64

func DogfoodReceiptOpen

func DogfoodReceiptOpen(cook *DogfoodReceiptCook, base unsafe.Pointer, length int64) bool

DogfoodReceiptOpen is the bool convenience for the typed Open error on the handle.

func DogfoodReceiptReset

func DogfoodReceiptReset(value *DogfoodReceipt)

DogfoodReceiptReset restores DogfoodReceipt's declared defaults in place, reusing the storage the value already holds. The reader calls it before overlaying.

func DogfoodReceiptSave

func DogfoodReceiptSave(value *DogfoodReceipt, buffer []byte, context ...TableWriteContext) int64

func DogfoodReceiptSaveBody

func DogfoodReceiptSaveBody(w *TableWriter, value *DogfoodReceipt) bool

func DogfoodReceiptSaveBodyFields

func DogfoodReceiptSaveBodyFields(w *TableWriter, value *DogfoodReceipt) bool

func DogfoodReceiptSaveBodyFieldsRetain

func DogfoodReceiptSaveBodyFieldsRetain(w *TableRetainWriter, value *DogfoodReceipt) bool

func DogfoodReceiptSaveBodyRetain

func DogfoodReceiptSaveBodyRetain(w *TableRetainWriter, value *DogfoodReceipt) bool

func DogfoodReceiptSaveMessageBody

func DogfoodReceiptSaveMessageBody(w *TableMessageWriter, value *DogfoodReceipt) bool

func DogfoodReceiptSaveRetain

func DogfoodReceiptSaveRetain(value *DogfoodReceipt, retain *TableRetain, buffer []byte, report *TableReport, allocator ...TableAllocator) int64

func DogfoodReceiptSaveText

func DogfoodReceiptSaveText(value *DogfoodReceipt, context ...TableWriteContext) (string, error)

DogfoodReceiptSaveText returns the base64 of DogfoodReceipt's binary wire (mas-bandwidth/schema docs/SPEC-TABLES.md §16.8): the whole file, form byte first, so the text keeps the form byte, the framing check and every versioning guarantee and is opaque. It takes the write context DogfoodReceiptSave takes.

func DogfoodReceiptToJson

func DogfoodReceiptToJson(value *DogfoodReceipt, buffer []byte, allocator ...TableAllocator) int64

func DogfoodReceiptToJsonMeasure

func DogfoodReceiptToJsonMeasure(value *DogfoodReceipt, allocator ...TableAllocator) int64

func EnumNameCairnEvent

func EnumNameCairnEvent(value CairnEvent) string

EnumNameCairnEvent: debug/log/tooling name for any CairnEvent wire value — out-of-set values (wire-legal up to the declared max) name as "???"

func EnumNamePublishPolicy

func EnumNamePublishPolicy(value PublishPolicy) string

EnumNamePublishPolicy: debug/log/tooling name for any PublishPolicy wire value — out-of-set values (wire-legal up to the declared max) name as "???"

func FuseBoxCookFrom

func FuseBoxCookFrom(value *FuseBox, buffer []byte, order TableByteOrder, context ...TableWriteContext) bool

func FuseBoxCookMeasure

func FuseBoxCookMeasure(value *FuseBox, context ...TableWriteContext) int64

func FuseBoxCookMeasureReason

func FuseBoxCookMeasureReason(value *FuseBox, context ...TableWriteContext) (int64, error)

func FuseBoxFromJson

func FuseBoxFromJson(builder *FuseBoxBuilder, text []byte, report *TableReport) bool

func FuseBoxLoadBody

func FuseBoxLoadBody(r *TableReader, value *FuseBox) bool

func FuseBoxLoadBodyRetain

func FuseBoxLoadBodyRetain(r *TableRetainReader, value *FuseBox) bool

func FuseBoxLoadBuilder

func FuseBoxLoadBuilder(b *FuseBoxBuilder, wire []byte, report *TableReport) bool

func FuseBoxLoadMeasure

func FuseBoxLoadMeasure(wire []byte) int64

func FuseBoxLoadMeasureReason

func FuseBoxLoadMeasureReason(wire []byte) (int64, error)

func FuseBoxLoadMessageBody

func FuseBoxLoadMessageBody(r *TableMessageReader, value *FuseBox) bool

func FuseBoxLoadMessageBodyRetain

func FuseBoxLoadMessageBodyRetain(r *TableRetainMessageReader, value *FuseBox) bool

func FuseBoxMeasure

func FuseBoxMeasure(value *FuseBox, context ...TableWriteContext) int64

func FuseBoxMeasureBody

func FuseBoxMeasureBody(value *FuseBox, ids *TableIds) int64

func FuseBoxMeasureBodyRetain

func FuseBoxMeasureBodyRetain(value *FuseBox, ids *TableRetainIds) int64

func FuseBoxMeasureReason

func FuseBoxMeasureReason(value *FuseBox, context ...TableWriteContext) (int64, error)

func FuseBoxMeasureRetain

func FuseBoxMeasureRetain(value *FuseBox, retain *TableRetain, allocator ...TableAllocator) int64

func FuseBoxOpen

func FuseBoxOpen(cook *FuseBoxCook, base unsafe.Pointer, length int64) bool

FuseBoxOpen is the bool convenience for the typed Open error on the handle.

func FuseBoxQuarantineEach

func FuseBoxQuarantineEach(holder *TableList[QuarantineEntryRow], visit func(*QuarantineEntryRow) bool, arena ...*TableArena) bool

func FuseBoxQuarantineErase

func FuseBoxQuarantineErase(arena *TableArena, holder *TableList[QuarantineEntryRow], element *QuarantineEntryRow) bool

func FuseBoxReset

func FuseBoxReset(value *FuseBox)

FuseBoxReset restores FuseBox's declared defaults in place, reusing the storage the value already holds. The reader calls it before overlaying.

func FuseBoxSave

func FuseBoxSave(value *FuseBox, buffer []byte, context ...TableWriteContext) int64

func FuseBoxSaveBody

func FuseBoxSaveBody(w *TableWriter, value *FuseBox) bool

func FuseBoxSaveBodyFields

func FuseBoxSaveBodyFields(w *TableWriter, value *FuseBox) bool

func FuseBoxSaveBodyFieldsRetain

func FuseBoxSaveBodyFieldsRetain(w *TableRetainWriter, value *FuseBox) bool

func FuseBoxSaveBodyRetain

func FuseBoxSaveBodyRetain(w *TableRetainWriter, value *FuseBox) bool

func FuseBoxSaveMessageBody

func FuseBoxSaveMessageBody(w *TableMessageWriter, value *FuseBox) bool

func FuseBoxSaveRetain

func FuseBoxSaveRetain(value *FuseBox, retain *TableRetain, buffer []byte, report *TableReport, allocator ...TableAllocator) int64

func FuseBoxSaveText

func FuseBoxSaveText(value *FuseBox, context ...TableWriteContext) (string, error)

FuseBoxSaveText returns the base64 of FuseBox's binary wire (mas-bandwidth/schema docs/SPEC-TABLES.md §16.8): the whole file, form byte first, so the text keeps the form byte, the framing check and every versioning guarantee and is opaque. It takes the write context FuseBoxSave takes.

func FuseBoxToJson

func FuseBoxToJson(value *FuseBox, buffer []byte, allocator ...TableAllocator) int64

func FuseBoxToJsonMeasure

func FuseBoxToJsonMeasure(value *FuseBox, allocator ...TableAllocator) int64

func FuseCookFrom

func FuseCookFrom(value *Fuse, buffer []byte, order TableByteOrder, context ...TableWriteContext) bool

func FuseCookMeasure

func FuseCookMeasure(value *Fuse, context ...TableWriteContext) int64

func FuseCookMeasureReason

func FuseCookMeasureReason(value *Fuse, context ...TableWriteContext) (int64, error)

func FuseFromJson

func FuseFromJson(builder *FuseBuilder, text []byte, report *TableReport) bool

func FuseLoadBody

func FuseLoadBody(r *TableReader, value *Fuse) bool

func FuseLoadBodyRetain

func FuseLoadBodyRetain(r *TableRetainReader, value *Fuse) bool

func FuseLoadBuilder

func FuseLoadBuilder(b *FuseBuilder, wire []byte, report *TableReport) bool

func FuseLoadMeasure

func FuseLoadMeasure(wire []byte) int64

func FuseLoadMeasureReason

func FuseLoadMeasureReason(wire []byte) (int64, error)

func FuseLoadMessageBody

func FuseLoadMessageBody(r *TableMessageReader, value *Fuse) bool

func FuseLoadMessageBodyRetain

func FuseLoadMessageBodyRetain(r *TableRetainMessageReader, value *Fuse) bool

func FuseMeasure

func FuseMeasure(value *Fuse, context ...TableWriteContext) int64

func FuseMeasureBody

func FuseMeasureBody(value *Fuse, ids *TableIds) int64

func FuseMeasureBodyRetain

func FuseMeasureBodyRetain(value *Fuse, ids *TableRetainIds) int64

func FuseMeasureReason

func FuseMeasureReason(value *Fuse, context ...TableWriteContext) (int64, error)

func FuseMeasureRetain

func FuseMeasureRetain(value *Fuse, retain *TableRetain, allocator ...TableAllocator) int64

func FuseOpen

func FuseOpen(cook *FuseCook, base unsafe.Pointer, length int64) bool

FuseOpen is the bool convenience for the typed Open error on the handle.

func FuseReset

func FuseReset(value *Fuse)

FuseReset restores Fuse's declared defaults in place, reusing the storage the value already holds. The reader calls it before overlaying.

func FuseSave

func FuseSave(value *Fuse, buffer []byte, context ...TableWriteContext) int64

func FuseSaveBody

func FuseSaveBody(w *TableWriter, value *Fuse) bool

func FuseSaveBodyFields

func FuseSaveBodyFields(w *TableWriter, value *Fuse) bool

func FuseSaveBodyFieldsRetain

func FuseSaveBodyFieldsRetain(w *TableRetainWriter, value *Fuse) bool

func FuseSaveBodyRetain

func FuseSaveBodyRetain(w *TableRetainWriter, value *Fuse) bool

func FuseSaveMessageBody

func FuseSaveMessageBody(w *TableMessageWriter, value *Fuse) bool

func FuseSaveRetain

func FuseSaveRetain(value *Fuse, retain *TableRetain, buffer []byte, report *TableReport, allocator ...TableAllocator) int64

func FuseSaveText

func FuseSaveText(value *Fuse, context ...TableWriteContext) (string, error)

FuseSaveText returns the base64 of Fuse's binary wire (mas-bandwidth/schema docs/SPEC-TABLES.md §16.8): the whole file, form byte first, so the text keeps the form byte, the framing check and every versioning guarantee and is opaque. It takes the write context FuseSave takes.

func FuseToJson

func FuseToJson(value *Fuse, buffer []byte, allocator ...TableAllocator) int64

func FuseToJsonMeasure

func FuseToJsonMeasure(value *Fuse, allocator ...TableAllocator) int64

func LedgerKeyCookFrom

func LedgerKeyCookFrom(value *LedgerKey, buffer []byte, order TableByteOrder, context ...TableWriteContext) bool

func LedgerKeyCookMeasure

func LedgerKeyCookMeasure(value *LedgerKey, context ...TableWriteContext) int64

func LedgerKeyCookMeasureReason

func LedgerKeyCookMeasureReason(value *LedgerKey, context ...TableWriteContext) (int64, error)

func LedgerKeyFromJson

func LedgerKeyFromJson(builder *LedgerKeyBuilder, text []byte, report *TableReport) bool

func LedgerKeyLoadBody

func LedgerKeyLoadBody(r *TableReader, value *LedgerKey) bool

func LedgerKeyLoadBodyRetain

func LedgerKeyLoadBodyRetain(r *TableRetainReader, value *LedgerKey) bool

func LedgerKeyLoadBuilder

func LedgerKeyLoadBuilder(b *LedgerKeyBuilder, wire []byte, report *TableReport) bool

func LedgerKeyLoadMeasure

func LedgerKeyLoadMeasure(wire []byte) int64

func LedgerKeyLoadMeasureReason

func LedgerKeyLoadMeasureReason(wire []byte) (int64, error)

func LedgerKeyLoadMessageBody

func LedgerKeyLoadMessageBody(r *TableMessageReader, value *LedgerKey) bool

func LedgerKeyLoadMessageBodyRetain

func LedgerKeyLoadMessageBodyRetain(r *TableRetainMessageReader, value *LedgerKey) bool

func LedgerKeyMeasure

func LedgerKeyMeasure(value *LedgerKey, context ...TableWriteContext) int64

func LedgerKeyMeasureBody

func LedgerKeyMeasureBody(value *LedgerKey, ids *TableIds) int64

func LedgerKeyMeasureBodyRetain

func LedgerKeyMeasureBodyRetain(value *LedgerKey, ids *TableRetainIds) int64

func LedgerKeyMeasureReason

func LedgerKeyMeasureReason(value *LedgerKey, context ...TableWriteContext) (int64, error)

func LedgerKeyMeasureRetain

func LedgerKeyMeasureRetain(value *LedgerKey, retain *TableRetain, allocator ...TableAllocator) int64

func LedgerKeyOpen

func LedgerKeyOpen(cook *LedgerKeyCook, base unsafe.Pointer, length int64) bool

LedgerKeyOpen is the bool convenience for the typed Open error on the handle.

func LedgerKeyReset

func LedgerKeyReset(value *LedgerKey)

LedgerKeyReset restores LedgerKey's declared defaults in place, reusing the storage the value already holds. The reader calls it before overlaying.

func LedgerKeySave

func LedgerKeySave(value *LedgerKey, buffer []byte, context ...TableWriteContext) int64

func LedgerKeySaveBody

func LedgerKeySaveBody(w *TableWriter, value *LedgerKey) bool

func LedgerKeySaveBodyFields

func LedgerKeySaveBodyFields(w *TableWriter, value *LedgerKey) bool

func LedgerKeySaveBodyFieldsRetain

func LedgerKeySaveBodyFieldsRetain(w *TableRetainWriter, value *LedgerKey) bool

func LedgerKeySaveBodyRetain

func LedgerKeySaveBodyRetain(w *TableRetainWriter, value *LedgerKey) bool

func LedgerKeySaveMessageBody

func LedgerKeySaveMessageBody(w *TableMessageWriter, value *LedgerKey) bool

func LedgerKeySaveRetain

func LedgerKeySaveRetain(value *LedgerKey, retain *TableRetain, buffer []byte, report *TableReport, allocator ...TableAllocator) int64

func LedgerKeySaveText

func LedgerKeySaveText(value *LedgerKey, context ...TableWriteContext) (string, error)

LedgerKeySaveText returns the base64 of LedgerKey's binary wire (mas-bandwidth/schema docs/SPEC-TABLES.md §16.8): the whole file, form byte first, so the text keeps the form byte, the framing check and every versioning guarantee and is opaque. It takes the write context LedgerKeySave takes.

func LedgerKeyToJson

func LedgerKeyToJson(value *LedgerKey, buffer []byte, allocator ...TableAllocator) int64

func LedgerKeyToJsonMeasure

func LedgerKeyToJsonMeasure(value *LedgerKey, allocator ...TableAllocator) int64

func LedgerValueCookFrom

func LedgerValueCookFrom(value *LedgerValue, buffer []byte, order TableByteOrder, context ...TableWriteContext) bool

func LedgerValueCookMeasure

func LedgerValueCookMeasure(value *LedgerValue, context ...TableWriteContext) int64

func LedgerValueCookMeasureReason

func LedgerValueCookMeasureReason(value *LedgerValue, context ...TableWriteContext) (int64, error)

func LedgerValueFromJson

func LedgerValueFromJson(builder *LedgerValueBuilder, text []byte, report *TableReport) bool

func LedgerValueLoadBody

func LedgerValueLoadBody(r *TableReader, value *LedgerValue) bool

func LedgerValueLoadBodyRetain

func LedgerValueLoadBodyRetain(r *TableRetainReader, value *LedgerValue) bool

func LedgerValueLoadBuilder

func LedgerValueLoadBuilder(b *LedgerValueBuilder, wire []byte, report *TableReport) bool

func LedgerValueLoadMeasure

func LedgerValueLoadMeasure(wire []byte) int64

func LedgerValueLoadMeasureReason

func LedgerValueLoadMeasureReason(wire []byte) (int64, error)

func LedgerValueLoadMessageBody

func LedgerValueLoadMessageBody(r *TableMessageReader, value *LedgerValue) bool

func LedgerValueLoadMessageBodyRetain

func LedgerValueLoadMessageBodyRetain(r *TableRetainMessageReader, value *LedgerValue) bool

func LedgerValueMeasure

func LedgerValueMeasure(value *LedgerValue, context ...TableWriteContext) int64

func LedgerValueMeasureBody

func LedgerValueMeasureBody(value *LedgerValue, ids *TableIds) int64

func LedgerValueMeasureBodyRetain

func LedgerValueMeasureBodyRetain(value *LedgerValue, ids *TableRetainIds) int64

func LedgerValueMeasureReason

func LedgerValueMeasureReason(value *LedgerValue, context ...TableWriteContext) (int64, error)

func LedgerValueMeasureRetain

func LedgerValueMeasureRetain(value *LedgerValue, retain *TableRetain, allocator ...TableAllocator) int64

func LedgerValueOpen

func LedgerValueOpen(cook *LedgerValueCook, base unsafe.Pointer, length int64) bool

LedgerValueOpen is the bool convenience for the typed Open error on the handle.

func LedgerValueReset

func LedgerValueReset(value *LedgerValue)

LedgerValueReset restores LedgerValue's declared defaults in place, reusing the storage the value already holds. The reader calls it before overlaying.

func LedgerValueSave

func LedgerValueSave(value *LedgerValue, buffer []byte, context ...TableWriteContext) int64

func LedgerValueSaveBody

func LedgerValueSaveBody(w *TableWriter, value *LedgerValue) bool

func LedgerValueSaveBodyFields

func LedgerValueSaveBodyFields(w *TableWriter, value *LedgerValue) bool

func LedgerValueSaveBodyFieldsRetain

func LedgerValueSaveBodyFieldsRetain(w *TableRetainWriter, value *LedgerValue) bool

func LedgerValueSaveBodyRetain

func LedgerValueSaveBodyRetain(w *TableRetainWriter, value *LedgerValue) bool

func LedgerValueSaveMessageBody

func LedgerValueSaveMessageBody(w *TableMessageWriter, value *LedgerValue) bool

func LedgerValueSaveRetain

func LedgerValueSaveRetain(value *LedgerValue, retain *TableRetain, buffer []byte, report *TableReport, allocator ...TableAllocator) int64

func LedgerValueSaveText

func LedgerValueSaveText(value *LedgerValue, context ...TableWriteContext) (string, error)

LedgerValueSaveText returns the base64 of LedgerValue's binary wire (mas-bandwidth/schema docs/SPEC-TABLES.md §16.8): the whole file, form byte first, so the text keeps the form byte, the framing check and every versioning guarantee and is opaque. It takes the write context LedgerValueSave takes.

func LedgerValueToJson

func LedgerValueToJson(value *LedgerValue, buffer []byte, allocator ...TableAllocator) int64

func LedgerValueToJsonMeasure

func LedgerValueToJsonMeasure(value *LedgerValue, allocator ...TableAllocator) int64

func QuarantineEntryCookFrom

func QuarantineEntryCookFrom(value *QuarantineEntry, buffer []byte, order TableByteOrder, context ...TableWriteContext) bool

func QuarantineEntryCookMeasure

func QuarantineEntryCookMeasure(value *QuarantineEntry, context ...TableWriteContext) int64

func QuarantineEntryCookMeasureReason

func QuarantineEntryCookMeasureReason(value *QuarantineEntry, context ...TableWriteContext) (int64, error)

func QuarantineEntryFromJson

func QuarantineEntryFromJson(builder *QuarantineEntryBuilder, text []byte, report *TableReport) bool

func QuarantineEntryLoadBody

func QuarantineEntryLoadBody(r *TableReader, value *QuarantineEntry) bool

func QuarantineEntryLoadBodyRetain

func QuarantineEntryLoadBodyRetain(r *TableRetainReader, value *QuarantineEntry) bool

func QuarantineEntryLoadBuilder

func QuarantineEntryLoadBuilder(b *QuarantineEntryBuilder, wire []byte, report *TableReport) bool

func QuarantineEntryLoadMeasure

func QuarantineEntryLoadMeasure(wire []byte) int64

func QuarantineEntryLoadMeasureReason

func QuarantineEntryLoadMeasureReason(wire []byte) (int64, error)

func QuarantineEntryLoadMessageBody

func QuarantineEntryLoadMessageBody(r *TableMessageReader, value *QuarantineEntry) bool

func QuarantineEntryLoadMessageBodyRetain

func QuarantineEntryLoadMessageBodyRetain(r *TableRetainMessageReader, value *QuarantineEntry) bool

func QuarantineEntryMeasure

func QuarantineEntryMeasure(value *QuarantineEntry, context ...TableWriteContext) int64

func QuarantineEntryMeasureBody

func QuarantineEntryMeasureBody(value *QuarantineEntry, ids *TableIds) int64

func QuarantineEntryMeasureBodyRetain

func QuarantineEntryMeasureBodyRetain(value *QuarantineEntry, ids *TableRetainIds) int64

func QuarantineEntryMeasureReason

func QuarantineEntryMeasureReason(value *QuarantineEntry, context ...TableWriteContext) (int64, error)

func QuarantineEntryMeasureRetain

func QuarantineEntryMeasureRetain(value *QuarantineEntry, retain *TableRetain, allocator ...TableAllocator) int64

func QuarantineEntryOpen

func QuarantineEntryOpen(cook *QuarantineEntryCook, base unsafe.Pointer, length int64) bool

QuarantineEntryOpen is the bool convenience for the typed Open error on the handle.

func QuarantineEntryReset

func QuarantineEntryReset(value *QuarantineEntry)

QuarantineEntryReset restores QuarantineEntry's declared defaults in place, reusing the storage the value already holds. The reader calls it before overlaying.

func QuarantineEntrySave

func QuarantineEntrySave(value *QuarantineEntry, buffer []byte, context ...TableWriteContext) int64

func QuarantineEntrySaveBody

func QuarantineEntrySaveBody(w *TableWriter, value *QuarantineEntry) bool

func QuarantineEntrySaveBodyFields

func QuarantineEntrySaveBodyFields(w *TableWriter, value *QuarantineEntry) bool

func QuarantineEntrySaveBodyFieldsRetain

func QuarantineEntrySaveBodyFieldsRetain(w *TableRetainWriter, value *QuarantineEntry) bool

func QuarantineEntrySaveBodyRetain

func QuarantineEntrySaveBodyRetain(w *TableRetainWriter, value *QuarantineEntry) bool

func QuarantineEntrySaveMessageBody

func QuarantineEntrySaveMessageBody(w *TableMessageWriter, value *QuarantineEntry) bool

func QuarantineEntrySaveRetain

func QuarantineEntrySaveRetain(value *QuarantineEntry, retain *TableRetain, buffer []byte, report *TableReport, allocator ...TableAllocator) int64

func QuarantineEntrySaveText

func QuarantineEntrySaveText(value *QuarantineEntry, context ...TableWriteContext) (string, error)

QuarantineEntrySaveText returns the base64 of QuarantineEntry's binary wire (mas-bandwidth/schema docs/SPEC-TABLES.md §16.8): the whole file, form byte first, so the text keeps the form byte, the framing check and every versioning guarantee and is opaque. It takes the write context QuarantineEntrySave takes.

func QuarantineEntryToJson

func QuarantineEntryToJson(value *QuarantineEntry, buffer []byte, allocator ...TableAllocator) int64

func QuarantineEntryToJsonMeasure

func QuarantineEntryToJsonMeasure(value *QuarantineEntry, allocator ...TableAllocator) int64

func TableBytesEmplace

func TableBytesEmplace(worker *TableWorker, slot *TableRef, length int64) []byte

func TableStringEmplace

func TableStringEmplace(worker *TableWorker, slot *TableRef, text []byte) []byte

func TokenValueCookFrom

func TokenValueCookFrom(value *TokenValue, buffer []byte, order TableByteOrder, context ...TableWriteContext) bool

func TokenValueCookMeasure

func TokenValueCookMeasure(value *TokenValue, context ...TableWriteContext) int64

func TokenValueCookMeasureReason

func TokenValueCookMeasureReason(value *TokenValue, context ...TableWriteContext) (int64, error)

func TokenValueFromJson

func TokenValueFromJson(builder *TokenValueBuilder, text []byte, report *TableReport) bool

func TokenValueLoadBody

func TokenValueLoadBody(r *TableReader, value *TokenValue) bool

func TokenValueLoadBodyRetain

func TokenValueLoadBodyRetain(r *TableRetainReader, value *TokenValue) bool

func TokenValueLoadBuilder

func TokenValueLoadBuilder(b *TokenValueBuilder, wire []byte, report *TableReport) bool

func TokenValueLoadMeasure

func TokenValueLoadMeasure(wire []byte) int64

func TokenValueLoadMeasureReason

func TokenValueLoadMeasureReason(wire []byte) (int64, error)

func TokenValueLoadMessageBody

func TokenValueLoadMessageBody(r *TableMessageReader, value *TokenValue) bool

func TokenValueLoadMessageBodyRetain

func TokenValueLoadMessageBodyRetain(r *TableRetainMessageReader, value *TokenValue) bool

func TokenValueMeasure

func TokenValueMeasure(value *TokenValue, context ...TableWriteContext) int64

func TokenValueMeasureBody

func TokenValueMeasureBody(value *TokenValue, ids *TableIds) int64

func TokenValueMeasureBodyRetain

func TokenValueMeasureBodyRetain(value *TokenValue, ids *TableRetainIds) int64

func TokenValueMeasureReason

func TokenValueMeasureReason(value *TokenValue, context ...TableWriteContext) (int64, error)

func TokenValueMeasureRetain

func TokenValueMeasureRetain(value *TokenValue, retain *TableRetain, allocator ...TableAllocator) int64

func TokenValueOpen

func TokenValueOpen(cook *TokenValueCook, base unsafe.Pointer, length int64) bool

TokenValueOpen is the bool convenience for the typed Open error on the handle.

func TokenValueReset

func TokenValueReset(value *TokenValue)

TokenValueReset restores TokenValue's declared defaults in place, reusing the storage the value already holds. The reader calls it before overlaying.

func TokenValueSave

func TokenValueSave(value *TokenValue, buffer []byte, context ...TableWriteContext) int64

func TokenValueSaveBody

func TokenValueSaveBody(w *TableWriter, value *TokenValue) bool

func TokenValueSaveBodyFields

func TokenValueSaveBodyFields(w *TableWriter, value *TokenValue) bool

func TokenValueSaveBodyFieldsRetain

func TokenValueSaveBodyFieldsRetain(w *TableRetainWriter, value *TokenValue) bool

func TokenValueSaveBodyRetain

func TokenValueSaveBodyRetain(w *TableRetainWriter, value *TokenValue) bool

func TokenValueSaveMessageBody

func TokenValueSaveMessageBody(w *TableMessageWriter, value *TokenValue) bool

func TokenValueSaveRetain

func TokenValueSaveRetain(value *TokenValue, retain *TableRetain, buffer []byte, report *TableReport, allocator ...TableAllocator) int64

func TokenValueSaveText

func TokenValueSaveText(value *TokenValue, context ...TableWriteContext) (string, error)

TokenValueSaveText returns the base64 of TokenValue's binary wire (mas-bandwidth/schema docs/SPEC-TABLES.md §16.8): the whole file, form byte first, so the text keeps the form byte, the framing check and every versioning guarantee and is opaque. It takes the write context TokenValueSave takes.

func TokenValueToJson

func TokenValueToJson(value *TokenValue, buffer []byte, allocator ...TableAllocator) int64

func TokenValueToJsonMeasure

func TokenValueToJsonMeasure(value *TokenValue, allocator ...TableAllocator) int64

Types

type CairnEvent

type CairnEvent uint8

CairnEvent — None = 0 implicit, variants dense from 1, wire range [0, 2] (SPEC §4.2)

const (
	CairnEventNone   CairnEvent = 0
	CairnEventopen   CairnEvent = 1
	CairnEventappend CairnEvent = 2
	CairnEventCount  CairnEvent = 2 // the declared variant count (SPEC §4.2)
	CairnEventMax    CairnEvent = 2 // the exported extent (SPEC §4.2)
)

func (CairnEvent) TableEnumId

func (value CairnEvent) TableEnumId() (uint64, bool)

TableEnumId: CairnEvent on the TABLE wire rides as the 64-bit hash of its VARIANT NAME, so a variant may be added anywhere, removed, or reordered and old data still reads (mas-bandwidth/schema docs/SPEC-TABLES.md §5). None uses reference zero; hash zero remains a valid named id. The bool is false when no variant names this value: no wire identity.

func (*CairnEvent) TableEnumValue

func (value *CairnEvent) TableEnumValue(id uint64) bool

TableEnumValue resolves a table-wire variant id to a CairnEvent, in place. The bool is false for an id this build cannot name; the value is left at None, which is what an unknown variant reads as (mas-bandwidth/schema docs/SPEC-TABLES.md §5).

type CairnLogRecord

type CairnLogRecord = CairnLogRecordRow

func CairnLogRecordLoad

func CairnLogRecordLoad(region, wire []byte, report *TableReport) *CairnLogRecord

func CairnLogRecordLoadRetain

func CairnLogRecordLoadRetain(region, wire []byte, retain *TableRetain, report *TableReport) *CairnLogRecord

func CairnLogRecordLoadText

func CairnLogRecordLoadText(text string, report *TableReport) (*CairnLogRecord, error)

CairnLogRecordLoadText reads one CairnLogRecord from a base64 wire text (mas-bandwidth/schema docs/SPEC-TABLES.md §16.8) into a builder of its own and returns the locked root, as CairnLogRecordReadStrict does: it is the STRICT read (§6.5) and refuses whenever the read's report holds an error (TableReport.Err), whatever the tolerant LoadBuilder answered, so a recovered value never comes back. It refuses by name: base64_damaged when the body does not decode, unknown_form when the decoded wire's form byte is not one this build carries, wire_damaged for framing damage, and the report's own reason (malformed, clamped, kind_mismatch, ...) otherwise. A nil report is allowed; a supplied one receives THIS read's report, so earlier counts in it never decide.

func CairnLogRecordReadStrict

func CairnLogRecordReadStrict(wire []byte) (*CairnLogRecord, error)

CairnLogRecordReadStrict is the STRICT read (mas-bandwidth/schema docs/SPEC-TABLES.md §6.5): one call, its own builder, one typed reason.

type CairnLogRecordBuilder

type CairnLogRecordBuilder struct {
	Arena TableArena
	Main  TableWorker
	// contains filtered or unexported fields
}

func (*CairnLogRecordBuilder) AsConst

func (b *CairnLogRecordBuilder) AsConst() *CairnLogRecord

func (*CairnLogRecordBuilder) GetRoot

func (b *CairnLogRecordBuilder) GetRoot() *CairnLogRecord

func (*CairnLogRecordBuilder) Init

func (b *CairnLogRecordBuilder) Init(allocator ...TableAllocator) bool

func (*CairnLogRecordBuilder) Lock

func (b *CairnLogRecordBuilder) Lock() bool

func (*CairnLogRecordBuilder) PackMeasure

func (b *CairnLogRecordBuilder) PackMeasure() int64

func (*CairnLogRecordBuilder) PackMeasureReason

func (b *CairnLogRecordBuilder) PackMeasureReason() (int64, error)

func (*CairnLogRecordBuilder) Region

func (b *CairnLogRecordBuilder) Region() []byte

func (*CairnLogRecordBuilder) Shutdown

func (b *CairnLogRecordBuilder) Shutdown()

type CairnLogRecordCook

type CairnLogRecordCook struct {
	Region       unsafe.Pointer // the DATA part's base: the root sits at offset zero
	RegionLength int64          // data_length, as the header framed it
}

CairnLogRecordCook is CairnLogRecord's cook: a pointer and a length, and then the root where it lies. Opening one is a HEADER MATCH and no copy; a reference is one add (mas-bandwidth/schema docs/SPEC-TABLES.md §7).

`Cook` is a CLAIMED suffix (§11). C++ spells the same claimed verbs as free functions — CairnLogRecordOpen, CairnLogRecordAt — and so does Go, because Go has free functions; what is a MEMBER here is only what §11 leaves a language free to make one.

THE MEMORY IS THE CONSUMER'S. Nothing here allocates, nothing here copies and nothing here pins: the region must stay put and stay aligned for as long as this handle or anything reached through it is used.

func (*CairnLogRecordCook) Open

func (cook *CairnLogRecordCook) Open(base unsafe.Pointer, length int64) error

Open checks the header in SPEC §7 order, bytewise until base alignment is established. A successful match points at the region and allocates nothing.

func (CairnLogRecordCook) RegionAlignment

func (c CairnLogRecordCook) RegionAlignment() int64

§7.1's constants, so a consumer reading this file has the facts and not a description of them. They are METHODS because §11 leaves a language whose accessors are members free to spell them that way, and a package constant per table per fact would claim names §11 does not.

func (CairnLogRecordCook) Root

Root is the root record at the region's base. It is a POINTER and not a copy: a cooked graph is walked by adding deltas to slot addresses.

func (CairnLogRecordCook) RootAlign

func (c CairnLogRecordCook) RootAlign() int64

func (CairnLogRecordCook) RootSize

func (c CairnLogRecordCook) RootSize() int64

func (CairnLogRecordCook) Type

Type is CairnLogRecord's cooked-record descriptor, the head of the graph a reflective walk follows (mas-bandwidth/schema docs/SPEC-TABLES.md §8).

type CairnLogRecordRow

type CairnLogRecordRow struct {
	EventKind CairnEvent
	Session   [129]byte // string(128): buffer, used length beside it

	SessionLength int32
	Entry         [129]byte // string(128): buffer, used length beside it

	EntryLength int32
	Stamp       int64 // *: signed self-relative delta, zero is null (§6.3)
	Publish     PublishPolicy

	Source int64 // *: signed self-relative delta, zero is null (§6.3)
	// contains filtered or unexported fields
}

CairnLogRecordRow — a cooked record. `Row` is a CLAIMED suffix (mas-bandwidth/schema docs/SPEC-TABLES.md §11), so no declaration in the unit can take it.

func CairnLogRecordAt

func CairnLogRecordAt(slot *int64, arena ...*TableArena) *CairnLogRecordRow

CairnLogRecordAt dereferences a reference, and it is the same call in a locked region and an opened cook because they are the same encoding (§6.3): the slot is eight bytes, SIGNED, self-relative from the SLOT'S OWN ADDRESS, so a deref needs no base pointer and no bounds test, and NULL IS A DELTA OF ZERO. Nothing about this call is the cook's: it is what a region reference is, and a cook is a region written verbatim.

It takes the SLOT and not its value, because a self-relative delta means nothing without the address it is relative to.

type DogfoodReceipt

type DogfoodReceipt = DogfoodReceiptRow

func DogfoodReceiptLoad

func DogfoodReceiptLoad(region, wire []byte, report *TableReport) *DogfoodReceipt

func DogfoodReceiptLoadRetain

func DogfoodReceiptLoadRetain(region, wire []byte, retain *TableRetain, report *TableReport) *DogfoodReceipt

func DogfoodReceiptLoadText

func DogfoodReceiptLoadText(text string, report *TableReport) (*DogfoodReceipt, error)

DogfoodReceiptLoadText reads one DogfoodReceipt from a base64 wire text (mas-bandwidth/schema docs/SPEC-TABLES.md §16.8) into a builder of its own and returns the locked root, as DogfoodReceiptReadStrict does: it is the STRICT read (§6.5) and refuses whenever the read's report holds an error (TableReport.Err), whatever the tolerant LoadBuilder answered, so a recovered value never comes back. It refuses by name: base64_damaged when the body does not decode, unknown_form when the decoded wire's form byte is not one this build carries, wire_damaged for framing damage, and the report's own reason (malformed, clamped, kind_mismatch, ...) otherwise. A nil report is allowed; a supplied one receives THIS read's report, so earlier counts in it never decide.

func DogfoodReceiptReadStrict

func DogfoodReceiptReadStrict(wire []byte) (*DogfoodReceipt, error)

DogfoodReceiptReadStrict is the STRICT read (mas-bandwidth/schema docs/SPEC-TABLES.md §6.5): one call, its own builder, one typed reason.

type DogfoodReceiptBuilder

type DogfoodReceiptBuilder struct {
	Arena TableArena
	Main  TableWorker
	// contains filtered or unexported fields
}

func (*DogfoodReceiptBuilder) AsConst

func (b *DogfoodReceiptBuilder) AsConst() *DogfoodReceipt

func (*DogfoodReceiptBuilder) GetRoot

func (b *DogfoodReceiptBuilder) GetRoot() *DogfoodReceipt

func (*DogfoodReceiptBuilder) Init

func (b *DogfoodReceiptBuilder) Init(allocator ...TableAllocator) bool

func (*DogfoodReceiptBuilder) Lock

func (b *DogfoodReceiptBuilder) Lock() bool

func (*DogfoodReceiptBuilder) PackMeasure

func (b *DogfoodReceiptBuilder) PackMeasure() int64

func (*DogfoodReceiptBuilder) PackMeasureReason

func (b *DogfoodReceiptBuilder) PackMeasureReason() (int64, error)

func (*DogfoodReceiptBuilder) Region

func (b *DogfoodReceiptBuilder) Region() []byte

func (*DogfoodReceiptBuilder) Shutdown

func (b *DogfoodReceiptBuilder) Shutdown()

type DogfoodReceiptCook

type DogfoodReceiptCook struct {
	Region       unsafe.Pointer // the DATA part's base: the root sits at offset zero
	RegionLength int64          // data_length, as the header framed it
}

DogfoodReceiptCook is DogfoodReceipt's cook: a pointer and a length, and then the root where it lies. Opening one is a HEADER MATCH and no copy; a reference is one add (mas-bandwidth/schema docs/SPEC-TABLES.md §7).

`Cook` is a CLAIMED suffix (§11). C++ spells the same claimed verbs as free functions — DogfoodReceiptOpen, DogfoodReceiptAt — and so does Go, because Go has free functions; what is a MEMBER here is only what §11 leaves a language free to make one.

THE MEMORY IS THE CONSUMER'S. Nothing here allocates, nothing here copies and nothing here pins: the region must stay put and stay aligned for as long as this handle or anything reached through it is used.

func (*DogfoodReceiptCook) Open

func (cook *DogfoodReceiptCook) Open(base unsafe.Pointer, length int64) error

Open checks the header in SPEC §7 order, bytewise until base alignment is established. A successful match points at the region and allocates nothing.

func (DogfoodReceiptCook) RegionAlignment

func (c DogfoodReceiptCook) RegionAlignment() int64

§7.1's constants, so a consumer reading this file has the facts and not a description of them. They are METHODS because §11 leaves a language whose accessors are members free to spell them that way, and a package constant per table per fact would claim names §11 does not.

func (DogfoodReceiptCook) Root

Root is the root record at the region's base. It is a POINTER and not a copy: a cooked graph is walked by adding deltas to slot addresses.

func (DogfoodReceiptCook) RootAlign

func (c DogfoodReceiptCook) RootAlign() int64

func (DogfoodReceiptCook) RootSize

func (c DogfoodReceiptCook) RootSize() int64

func (DogfoodReceiptCook) Type

Type is DogfoodReceipt's cooked-record descriptor, the head of the graph a reflective walk follows (mas-bandwidth/schema docs/SPEC-TABLES.md §8).

type DogfoodReceiptRow

type DogfoodReceiptRow struct {
	Tool int64 // *: signed self-relative delta, zero is null (§6.3)
	Verb int64 // *: signed self-relative delta, zero is null (§6.3)
	By   int64 // *: signed self-relative delta, zero is null (§6.3)
	At   int64 // *: signed self-relative delta, zero is null (§6.3)
	Ok   bool

	Notes        int64 // *: signed self-relative delta, zero is null (§6.3)
	Issue        int64
	IssuePresent bool // ?: one byte, in Go's model as in C++

	Closes int64 // *: signed self-relative delta, zero is null (§6.3)
	// contains filtered or unexported fields
}

DogfoodReceiptRow — a cooked record. `Row` is a CLAIMED suffix (mas-bandwidth/schema docs/SPEC-TABLES.md §11), so no declaration in the unit can take it.

func DogfoodReceiptAt

func DogfoodReceiptAt(slot *int64, arena ...*TableArena) *DogfoodReceiptRow

DogfoodReceiptAt dereferences a reference, and it is the same call in a locked region and an opened cook because they are the same encoding (§6.3): the slot is eight bytes, SIGNED, self-relative from the SLOT'S OWN ADDRESS, so a deref needs no base pointer and no bounds test, and NULL IS A DELTA OF ZERO. Nothing about this call is the cook's: it is what a region reference is, and a cook is a region written verbatim.

It takes the SLOT and not its value, because a self-relative delta means nothing without the address it is relative to.

type Fuse

type Fuse = FuseRow

func FuseEmplace

func FuseEmplace(worker *TableWorker, slot *TableRef) *Fuse

func FuseLoad

func FuseLoad(region, wire []byte, report *TableReport) *Fuse

func FuseLoadRetain

func FuseLoadRetain(region, wire []byte, retain *TableRetain, report *TableReport) *Fuse

func FuseLoadText

func FuseLoadText(text string, report *TableReport) (*Fuse, error)

FuseLoadText reads one Fuse from a base64 wire text (mas-bandwidth/schema docs/SPEC-TABLES.md §16.8) into a builder of its own and returns the locked root, as FuseReadStrict does: it is the STRICT read (§6.5) and refuses whenever the read's report holds an error (TableReport.Err), whatever the tolerant LoadBuilder answered, so a recovered value never comes back. It refuses by name: base64_damaged when the body does not decode, unknown_form when the decoded wire's form byte is not one this build carries, wire_damaged for framing damage, and the report's own reason (malformed, clamped, kind_mismatch, ...) otherwise. A nil report is allowed; a supplied one receives THIS read's report, so earlier counts in it never decide.

func FuseReadStrict

func FuseReadStrict(wire []byte) (*Fuse, error)

FuseReadStrict is the STRICT read (mas-bandwidth/schema docs/SPEC-TABLES.md §6.5): one call, its own builder, one typed reason.

type FuseBox

type FuseBox = FuseBoxRow

func FuseBoxLoad

func FuseBoxLoad(region, wire []byte, report *TableReport) *FuseBox

func FuseBoxLoadRetain

func FuseBoxLoadRetain(region, wire []byte, retain *TableRetain, report *TableReport) *FuseBox

func FuseBoxLoadText

func FuseBoxLoadText(text string, report *TableReport) (*FuseBox, error)

FuseBoxLoadText reads one FuseBox from a base64 wire text (mas-bandwidth/schema docs/SPEC-TABLES.md §16.8) into a builder of its own and returns the locked root, as FuseBoxReadStrict does: it is the STRICT read (§6.5) and refuses whenever the read's report holds an error (TableReport.Err), whatever the tolerant LoadBuilder answered, so a recovered value never comes back. It refuses by name: base64_damaged when the body does not decode, unknown_form when the decoded wire's form byte is not one this build carries, wire_damaged for framing damage, and the report's own reason (malformed, clamped, kind_mismatch, ...) otherwise. A nil report is allowed; a supplied one receives THIS read's report, so earlier counts in it never decide.

func FuseBoxReadStrict

func FuseBoxReadStrict(wire []byte) (*FuseBox, error)

FuseBoxReadStrict is the STRICT read (mas-bandwidth/schema docs/SPEC-TABLES.md §6.5): one call, its own builder, one typed reason.

type FuseBoxBuilder

type FuseBoxBuilder struct {
	Arena TableArena
	Main  TableWorker
	// contains filtered or unexported fields
}

func (*FuseBoxBuilder) AsConst

func (b *FuseBoxBuilder) AsConst() *FuseBox

func (*FuseBoxBuilder) GetRoot

func (b *FuseBoxBuilder) GetRoot() *FuseBox

func (*FuseBoxBuilder) Init

func (b *FuseBoxBuilder) Init(allocator ...TableAllocator) bool

func (*FuseBoxBuilder) Lock

func (b *FuseBoxBuilder) Lock() bool

func (*FuseBoxBuilder) PackMeasure

func (b *FuseBoxBuilder) PackMeasure() int64

func (*FuseBoxBuilder) PackMeasureReason

func (b *FuseBoxBuilder) PackMeasureReason() (int64, error)

func (*FuseBoxBuilder) Region

func (b *FuseBoxBuilder) Region() []byte

func (*FuseBoxBuilder) Shutdown

func (b *FuseBoxBuilder) Shutdown()

type FuseBoxCook

type FuseBoxCook struct {
	Region       unsafe.Pointer // the DATA part's base: the root sits at offset zero
	RegionLength int64          // data_length, as the header framed it
}

FuseBoxCook is FuseBox's cook: a pointer and a length, and then the root where it lies. Opening one is a HEADER MATCH and no copy; a reference is one add (mas-bandwidth/schema docs/SPEC-TABLES.md §7).

`Cook` is a CLAIMED suffix (§11). C++ spells the same claimed verbs as free functions — FuseBoxOpen, FuseBoxAt — and so does Go, because Go has free functions; what is a MEMBER here is only what §11 leaves a language free to make one.

THE MEMORY IS THE CONSUMER'S. Nothing here allocates, nothing here copies and nothing here pins: the region must stay put and stay aligned for as long as this handle or anything reached through it is used.

func (*FuseBoxCook) Open

func (cook *FuseBoxCook) Open(base unsafe.Pointer, length int64) error

Open checks the header in SPEC §7 order, bytewise until base alignment is established. A successful match points at the region and allocates nothing.

func (FuseBoxCook) RegionAlignment

func (c FuseBoxCook) RegionAlignment() int64

§7.1's constants, so a consumer reading this file has the facts and not a description of them. They are METHODS because §11 leaves a language whose accessors are members free to spell them that way, and a package constant per table per fact would claim names §11 does not.

func (FuseBoxCook) Root

func (c FuseBoxCook) Root() *FuseBoxRow

Root is the root record at the region's base. It is a POINTER and not a copy: a cooked graph is walked by adding deltas to slot addresses.

func (FuseBoxCook) RootAlign

func (c FuseBoxCook) RootAlign() int64

func (FuseBoxCook) RootSize

func (c FuseBoxCook) RootSize() int64

func (FuseBoxCook) Type

func (c FuseBoxCook) Type() *TableCookInfo

Type is FuseBox's cooked-record descriptor, the head of the graph a reflective walk follows (mas-bandwidth/schema docs/SPEC-TABLES.md §8).

type FuseBoxRow

type FuseBoxRow struct {
	Lockdown   int64 // *Fuse: signed self-relative delta, zero is null (§6.3)
	Quarantine TableList[QuarantineEntryRow]
}

FuseBoxRow — a cooked record. `Row` is a CLAIMED suffix (mas-bandwidth/schema docs/SPEC-TABLES.md §11), so no declaration in the unit can take it.

func FuseBoxAt

func FuseBoxAt(slot *int64, arena ...*TableArena) *FuseBoxRow

FuseBoxAt dereferences a reference, and it is the same call in a locked region and an opened cook because they are the same encoding (§6.3): the slot is eight bytes, SIGNED, self-relative from the SLOT'S OWN ADDRESS, so a deref needs no base pointer and no bounds test, and NULL IS A DELTA OF ZERO. Nothing about this call is the cook's: it is what a region reference is, and a cook is a region written verbatim.

It takes the SLOT and not its value, because a self-relative delta means nothing without the address it is relative to.

type FuseBuilder

type FuseBuilder struct {
	Arena TableArena
	Main  TableWorker
	// contains filtered or unexported fields
}

func (*FuseBuilder) AsConst

func (b *FuseBuilder) AsConst() *Fuse

func (*FuseBuilder) GetRoot

func (b *FuseBuilder) GetRoot() *Fuse

func (*FuseBuilder) Init

func (b *FuseBuilder) Init(allocator ...TableAllocator) bool

func (*FuseBuilder) Lock

func (b *FuseBuilder) Lock() bool

func (*FuseBuilder) PackMeasure

func (b *FuseBuilder) PackMeasure() int64

func (*FuseBuilder) PackMeasureReason

func (b *FuseBuilder) PackMeasureReason() (int64, error)

func (*FuseBuilder) Region

func (b *FuseBuilder) Region() []byte

func (*FuseBuilder) Shutdown

func (b *FuseBuilder) Shutdown()

type FuseCook

type FuseCook struct {
	Region       unsafe.Pointer // the DATA part's base: the root sits at offset zero
	RegionLength int64          // data_length, as the header framed it
}

FuseCook is Fuse's cook: a pointer and a length, and then the root where it lies. Opening one is a HEADER MATCH and no copy; a reference is one add (mas-bandwidth/schema docs/SPEC-TABLES.md §7).

`Cook` is a CLAIMED suffix (§11). C++ spells the same claimed verbs as free functions — FuseOpen, FuseAt — and so does Go, because Go has free functions; what is a MEMBER here is only what §11 leaves a language free to make one.

THE MEMORY IS THE CONSUMER'S. Nothing here allocates, nothing here copies and nothing here pins: the region must stay put and stay aligned for as long as this handle or anything reached through it is used.

func (*FuseCook) Open

func (cook *FuseCook) Open(base unsafe.Pointer, length int64) error

Open checks the header in SPEC §7 order, bytewise until base alignment is established. A successful match points at the region and allocates nothing.

func (FuseCook) RegionAlignment

func (c FuseCook) RegionAlignment() int64

§7.1's constants, so a consumer reading this file has the facts and not a description of them. They are METHODS because §11 leaves a language whose accessors are members free to spell them that way, and a package constant per table per fact would claim names §11 does not.

func (FuseCook) Root

func (c FuseCook) Root() *FuseRow

Root is the root record at the region's base. It is a POINTER and not a copy: a cooked graph is walked by adding deltas to slot addresses.

func (FuseCook) RootAlign

func (c FuseCook) RootAlign() int64

func (FuseCook) RootSize

func (c FuseCook) RootSize() int64

func (FuseCook) Type

func (c FuseCook) Type() *TableCookInfo

Type is Fuse's cooked-record descriptor, the head of the graph a reflective walk follows (mas-bandwidth/schema docs/SPEC-TABLES.md §8).

type FuseRow

type FuseRow struct {
	At     int64 // *: signed self-relative delta, zero is null (§6.3)
	Reason int64 // *: signed self-relative delta, zero is null (§6.3)
}

FuseRow — a cooked record. `Row` is a CLAIMED suffix (mas-bandwidth/schema docs/SPEC-TABLES.md §11), so no declaration in the unit can take it.

func FuseAt

func FuseAt(slot *int64, arena ...*TableArena) *FuseRow

FuseAt dereferences a reference, and it is the same call in a locked region and an opened cook because they are the same encoding (§6.3): the slot is eight bytes, SIGNED, self-relative from the SLOT'S OWN ADDRESS, so a deref needs no base pointer and no bounds test, and NULL IS A DELTA OF ZERO. Nothing about this call is the cook's: it is what a region reference is, and a cook is a region written verbatim.

It takes the SLOT and not its value, because a self-relative delta means nothing without the address it is relative to.

type LedgerKey

type LedgerKey = LedgerKeyRow

func LedgerKeyLoad

func LedgerKeyLoad(region, wire []byte, report *TableReport) *LedgerKey

func LedgerKeyLoadRetain

func LedgerKeyLoadRetain(region, wire []byte, retain *TableRetain, report *TableReport) *LedgerKey

func LedgerKeyLoadText

func LedgerKeyLoadText(text string, report *TableReport) (*LedgerKey, error)

LedgerKeyLoadText reads one LedgerKey from a base64 wire text (mas-bandwidth/schema docs/SPEC-TABLES.md §16.8) into a builder of its own and returns the locked root, as LedgerKeyReadStrict does: it is the STRICT read (§6.5) and refuses whenever the read's report holds an error (TableReport.Err), whatever the tolerant LoadBuilder answered, so a recovered value never comes back. It refuses by name: base64_damaged when the body does not decode, unknown_form when the decoded wire's form byte is not one this build carries, wire_damaged for framing damage, and the report's own reason (malformed, clamped, kind_mismatch, ...) otherwise. A nil report is allowed; a supplied one receives THIS read's report, so earlier counts in it never decide.

func LedgerKeyReadStrict

func LedgerKeyReadStrict(wire []byte) (*LedgerKey, error)

LedgerKeyReadStrict is the STRICT read (mas-bandwidth/schema docs/SPEC-TABLES.md §6.5): one call, its own builder, one typed reason.

type LedgerKeyBuilder

type LedgerKeyBuilder struct {
	Arena TableArena
	Main  TableWorker
	// contains filtered or unexported fields
}

func (*LedgerKeyBuilder) AsConst

func (b *LedgerKeyBuilder) AsConst() *LedgerKey

func (*LedgerKeyBuilder) GetRoot

func (b *LedgerKeyBuilder) GetRoot() *LedgerKey

func (*LedgerKeyBuilder) Init

func (b *LedgerKeyBuilder) Init(allocator ...TableAllocator) bool

func (*LedgerKeyBuilder) Lock

func (b *LedgerKeyBuilder) Lock() bool

func (*LedgerKeyBuilder) PackMeasure

func (b *LedgerKeyBuilder) PackMeasure() int64

func (*LedgerKeyBuilder) PackMeasureReason

func (b *LedgerKeyBuilder) PackMeasureReason() (int64, error)

func (*LedgerKeyBuilder) Region

func (b *LedgerKeyBuilder) Region() []byte

func (*LedgerKeyBuilder) Shutdown

func (b *LedgerKeyBuilder) Shutdown()

type LedgerKeyCook

type LedgerKeyCook struct {
	Region       unsafe.Pointer // the DATA part's base: the root sits at offset zero
	RegionLength int64          // data_length, as the header framed it
}

LedgerKeyCook is LedgerKey's cook: a pointer and a length, and then the root where it lies. Opening one is a HEADER MATCH and no copy; a reference is one add (mas-bandwidth/schema docs/SPEC-TABLES.md §7).

`Cook` is a CLAIMED suffix (§11). C++ spells the same claimed verbs as free functions — LedgerKeyOpen, LedgerKeyAt — and so does Go, because Go has free functions; what is a MEMBER here is only what §11 leaves a language free to make one.

THE MEMORY IS THE CONSUMER'S. Nothing here allocates, nothing here copies and nothing here pins: the region must stay put and stay aligned for as long as this handle or anything reached through it is used.

func (*LedgerKeyCook) Open

func (cook *LedgerKeyCook) Open(base unsafe.Pointer, length int64) error

Open checks the header in SPEC §7 order, bytewise until base alignment is established. A successful match points at the region and allocates nothing.

func (LedgerKeyCook) RegionAlignment

func (c LedgerKeyCook) RegionAlignment() int64

§7.1's constants, so a consumer reading this file has the facts and not a description of them. They are METHODS because §11 leaves a language whose accessors are members free to spell them that way, and a package constant per table per fact would claim names §11 does not.

func (LedgerKeyCook) Root

func (c LedgerKeyCook) Root() *LedgerKeyRow

Root is the root record at the region's base. It is a POINTER and not a copy: a cooked graph is walked by adding deltas to slot addresses.

func (LedgerKeyCook) RootAlign

func (c LedgerKeyCook) RootAlign() int64

func (LedgerKeyCook) RootSize

func (c LedgerKeyCook) RootSize() int64

func (LedgerKeyCook) Type

func (c LedgerKeyCook) Type() *TableCookInfo

Type is LedgerKey's cooked-record descriptor, the head of the graph a reflective walk follows (mas-bandwidth/schema docs/SPEC-TABLES.md §8).

type LedgerKeyRow

type LedgerKeyRow struct {
	Day [11]byte // string(10): buffer, used length beside it

	DayLength int32
	Card      int64 // *: signed self-relative delta, zero is null (§6.3)
	Model     int64 // *: signed self-relative delta, zero is null (§6.3)
	Repo      int64 // *: signed self-relative delta, zero is null (§6.3)
	// contains filtered or unexported fields
}

LedgerKeyRow — a cooked record. `Row` is a CLAIMED suffix (mas-bandwidth/schema docs/SPEC-TABLES.md §11), so no declaration in the unit can take it.

func LedgerKeyAt

func LedgerKeyAt(slot *int64, arena ...*TableArena) *LedgerKeyRow

LedgerKeyAt dereferences a reference, and it is the same call in a locked region and an opened cook because they are the same encoding (§6.3): the slot is eight bytes, SIGNED, self-relative from the SLOT'S OWN ADDRESS, so a deref needs no base pointer and no bounds test, and NULL IS A DELTA OF ZERO. Nothing about this call is the cook's: it is what a region reference is, and a cook is a region written verbatim.

It takes the SLOT and not its value, because a self-relative delta means nothing without the address it is relative to.

type LedgerValue

type LedgerValue = LedgerValueRow

func LedgerValueLoad

func LedgerValueLoad(region, wire []byte, report *TableReport) *LedgerValue

func LedgerValueLoadRetain

func LedgerValueLoadRetain(region, wire []byte, retain *TableRetain, report *TableReport) *LedgerValue

func LedgerValueLoadText

func LedgerValueLoadText(text string, report *TableReport) (*LedgerValue, error)

LedgerValueLoadText reads one LedgerValue from a base64 wire text (mas-bandwidth/schema docs/SPEC-TABLES.md §16.8) into a builder of its own and returns the locked root, as LedgerValueReadStrict does: it is the STRICT read (§6.5) and refuses whenever the read's report holds an error (TableReport.Err), whatever the tolerant LoadBuilder answered, so a recovered value never comes back. It refuses by name: base64_damaged when the body does not decode, unknown_form when the decoded wire's form byte is not one this build carries, wire_damaged for framing damage, and the report's own reason (malformed, clamped, kind_mismatch, ...) otherwise. A nil report is allowed; a supplied one receives THIS read's report, so earlier counts in it never decide.

func LedgerValueReadStrict

func LedgerValueReadStrict(wire []byte) (*LedgerValue, error)

LedgerValueReadStrict is the STRICT read (mas-bandwidth/schema docs/SPEC-TABLES.md §6.5): one call, its own builder, one typed reason.

type LedgerValueBuilder

type LedgerValueBuilder struct {
	Arena TableArena
	Main  TableWorker
	// contains filtered or unexported fields
}

func (*LedgerValueBuilder) AsConst

func (b *LedgerValueBuilder) AsConst() *LedgerValue

func (*LedgerValueBuilder) GetRoot

func (b *LedgerValueBuilder) GetRoot() *LedgerValue

func (*LedgerValueBuilder) Init

func (b *LedgerValueBuilder) Init(allocator ...TableAllocator) bool

func (*LedgerValueBuilder) Lock

func (b *LedgerValueBuilder) Lock() bool

func (*LedgerValueBuilder) PackMeasure

func (b *LedgerValueBuilder) PackMeasure() int64

func (*LedgerValueBuilder) PackMeasureReason

func (b *LedgerValueBuilder) PackMeasureReason() (int64, error)

func (*LedgerValueBuilder) Region

func (b *LedgerValueBuilder) Region() []byte

func (*LedgerValueBuilder) Shutdown

func (b *LedgerValueBuilder) Shutdown()

type LedgerValueCook

type LedgerValueCook struct {
	Region       unsafe.Pointer // the DATA part's base: the root sits at offset zero
	RegionLength int64          // data_length, as the header framed it
}

LedgerValueCook is LedgerValue's cook: a pointer and a length, and then the root where it lies. Opening one is a HEADER MATCH and no copy; a reference is one add (mas-bandwidth/schema docs/SPEC-TABLES.md §7).

`Cook` is a CLAIMED suffix (§11). C++ spells the same claimed verbs as free functions — LedgerValueOpen, LedgerValueAt — and so does Go, because Go has free functions; what is a MEMBER here is only what §11 leaves a language free to make one.

THE MEMORY IS THE CONSUMER'S. Nothing here allocates, nothing here copies and nothing here pins: the region must stay put and stay aligned for as long as this handle or anything reached through it is used.

func (*LedgerValueCook) Open

func (cook *LedgerValueCook) Open(base unsafe.Pointer, length int64) error

Open checks the header in SPEC §7 order, bytewise until base alignment is established. A successful match points at the region and allocates nothing.

func (LedgerValueCook) RegionAlignment

func (c LedgerValueCook) RegionAlignment() int64

§7.1's constants, so a consumer reading this file has the facts and not a description of them. They are METHODS because §11 leaves a language whose accessors are members free to spell them that way, and a package constant per table per fact would claim names §11 does not.

func (LedgerValueCook) Root

func (c LedgerValueCook) Root() *LedgerValueRow

Root is the root record at the region's base. It is a POINTER and not a copy: a cooked graph is walked by adding deltas to slot addresses.

func (LedgerValueCook) RootAlign

func (c LedgerValueCook) RootAlign() int64

func (LedgerValueCook) RootSize

func (c LedgerValueCook) RootSize() int64

func (LedgerValueCook) Type

func (c LedgerValueCook) Type() *TableCookInfo

Type is LedgerValue's cooked-record descriptor, the head of the graph a reflective walk follows (mas-bandwidth/schema docs/SPEC-TABLES.md §8).

type LedgerValueRow

type LedgerValueRow struct {
	Provider    int64 // *: signed self-relative delta, zero is null (§6.3)
	Tokens      [5]TokenValueRow
	TokensCount int32

	Rough   int64
	Sources int64 // *: signed self-relative delta, zero is null (§6.3)
	// contains filtered or unexported fields
}

LedgerValueRow — a cooked record. `Row` is a CLAIMED suffix (mas-bandwidth/schema docs/SPEC-TABLES.md §11), so no declaration in the unit can take it.

func LedgerValueAt

func LedgerValueAt(slot *int64, arena ...*TableArena) *LedgerValueRow

LedgerValueAt dereferences a reference, and it is the same call in a locked region and an opened cook because they are the same encoding (§6.3): the slot is eight bytes, SIGNED, self-relative from the SLOT'S OWN ADDRESS, so a deref needs no base pointer and no bounds test, and NULL IS A DELTA OF ZERO. Nothing about this call is the cook's: it is what a region reference is, and a cook is a region written verbatim.

It takes the SLOT and not its value, because a self-relative delta means nothing without the address it is relative to.

type PublishPolicy

type PublishPolicy uint8

PublishPolicy — None = 0 implicit, variants dense from 1, wire range [0, 4] (SPEC §4.2)

const (
	PublishPolicyNone      PublishPolicy = 0
	PublishPolicynever     PublishPolicy = 1
	PublishPolicymanual    PublishPolicy = 2
	PublishPolicydeferred  PublishPolicy = 3
	PublishPolicyimmediate PublishPolicy = 4
	PublishPolicyCount     PublishPolicy = 4 // the declared variant count (SPEC §4.2)
	PublishPolicyMax       PublishPolicy = 4 // the exported extent (SPEC §4.2)
)

func (PublishPolicy) TableEnumId

func (value PublishPolicy) TableEnumId() (uint64, bool)

TableEnumId: PublishPolicy on the TABLE wire rides as the 64-bit hash of its VARIANT NAME, so a variant may be added anywhere, removed, or reordered and old data still reads (mas-bandwidth/schema docs/SPEC-TABLES.md §5). None uses reference zero; hash zero remains a valid named id. The bool is false when no variant names this value: no wire identity.

func (*PublishPolicy) TableEnumValue

func (value *PublishPolicy) TableEnumValue(id uint64) bool

TableEnumValue resolves a table-wire variant id to a PublishPolicy, in place. The bool is false for an id this build cannot name; the value is left at None, which is what an unknown variant reads as (mas-bandwidth/schema docs/SPEC-TABLES.md §5).

type QuarantineEntry

type QuarantineEntry = QuarantineEntryRow

func QuarantineEntryLoad

func QuarantineEntryLoad(region, wire []byte, report *TableReport) *QuarantineEntry

func QuarantineEntryLoadRetain

func QuarantineEntryLoadRetain(region, wire []byte, retain *TableRetain, report *TableReport) *QuarantineEntry

func QuarantineEntryLoadText

func QuarantineEntryLoadText(text string, report *TableReport) (*QuarantineEntry, error)

QuarantineEntryLoadText reads one QuarantineEntry from a base64 wire text (mas-bandwidth/schema docs/SPEC-TABLES.md §16.8) into a builder of its own and returns the locked root, as QuarantineEntryReadStrict does: it is the STRICT read (§6.5) and refuses whenever the read's report holds an error (TableReport.Err), whatever the tolerant LoadBuilder answered, so a recovered value never comes back. It refuses by name: base64_damaged when the body does not decode, unknown_form when the decoded wire's form byte is not one this build carries, wire_damaged for framing damage, and the report's own reason (malformed, clamped, kind_mismatch, ...) otherwise. A nil report is allowed; a supplied one receives THIS read's report, so earlier counts in it never decide.

func QuarantineEntryReadStrict

func QuarantineEntryReadStrict(wire []byte) (*QuarantineEntry, error)

QuarantineEntryReadStrict is the STRICT read (mas-bandwidth/schema docs/SPEC-TABLES.md §6.5): one call, its own builder, one typed reason.

type QuarantineEntryBuilder

type QuarantineEntryBuilder struct {
	Arena TableArena
	Main  TableWorker
	// contains filtered or unexported fields
}

func (*QuarantineEntryBuilder) AsConst

func (*QuarantineEntryBuilder) GetRoot

func (*QuarantineEntryBuilder) Init

func (b *QuarantineEntryBuilder) Init(allocator ...TableAllocator) bool

func (*QuarantineEntryBuilder) Lock

func (b *QuarantineEntryBuilder) Lock() bool

func (*QuarantineEntryBuilder) PackMeasure

func (b *QuarantineEntryBuilder) PackMeasure() int64

func (*QuarantineEntryBuilder) PackMeasureReason

func (b *QuarantineEntryBuilder) PackMeasureReason() (int64, error)

func (*QuarantineEntryBuilder) Region

func (b *QuarantineEntryBuilder) Region() []byte

func (*QuarantineEntryBuilder) Shutdown

func (b *QuarantineEntryBuilder) Shutdown()

type QuarantineEntryCook

type QuarantineEntryCook struct {
	Region       unsafe.Pointer // the DATA part's base: the root sits at offset zero
	RegionLength int64          // data_length, as the header framed it
}

QuarantineEntryCook is QuarantineEntry's cook: a pointer and a length, and then the root where it lies. Opening one is a HEADER MATCH and no copy; a reference is one add (mas-bandwidth/schema docs/SPEC-TABLES.md §7).

`Cook` is a CLAIMED suffix (§11). C++ spells the same claimed verbs as free functions — QuarantineEntryOpen, QuarantineEntryAt — and so does Go, because Go has free functions; what is a MEMBER here is only what §11 leaves a language free to make one.

THE MEMORY IS THE CONSUMER'S. Nothing here allocates, nothing here copies and nothing here pins: the region must stay put and stay aligned for as long as this handle or anything reached through it is used.

func (*QuarantineEntryCook) Open

func (cook *QuarantineEntryCook) Open(base unsafe.Pointer, length int64) error

Open checks the header in SPEC §7 order, bytewise until base alignment is established. A successful match points at the region and allocates nothing.

func (QuarantineEntryCook) RegionAlignment

func (c QuarantineEntryCook) RegionAlignment() int64

§7.1's constants, so a consumer reading this file has the facts and not a description of them. They are METHODS because §11 leaves a language whose accessors are members free to spell them that way, and a package constant per table per fact would claim names §11 does not.

func (QuarantineEntryCook) Root

Root is the root record at the region's base. It is a POINTER and not a copy: a cooked graph is walked by adding deltas to slot addresses.

func (QuarantineEntryCook) RootAlign

func (c QuarantineEntryCook) RootAlign() int64

func (QuarantineEntryCook) RootSize

func (c QuarantineEntryCook) RootSize() int64

func (QuarantineEntryCook) Type

Type is QuarantineEntry's cooked-record descriptor, the head of the graph a reflective walk follows (mas-bandwidth/schema docs/SPEC-TABLES.md §8).

type QuarantineEntryRow

type QuarantineEntryRow struct {
	Surface int64 // *: signed self-relative delta, zero is null (§6.3)
	Fuse    FuseRow
}

QuarantineEntryRow — a cooked record. `Row` is a CLAIMED suffix (mas-bandwidth/schema docs/SPEC-TABLES.md §11), so no declaration in the unit can take it.

func FuseBoxQuarantineAdd

func FuseBoxQuarantineAdd(worker *TableWorker, holder *TableList[QuarantineEntryRow]) *QuarantineEntryRow

func QuarantineEntryAt

func QuarantineEntryAt(slot *int64, arena ...*TableArena) *QuarantineEntryRow

QuarantineEntryAt dereferences a reference, and it is the same call in a locked region and an opened cook because they are the same encoding (§6.3): the slot is eight bytes, SIGNED, self-relative from the SLOT'S OWN ADDRESS, so a deref needs no base pointer and no bounds test, and NULL IS A DELTA OF ZERO. Nothing about this call is the cook's: it is what a region reference is, and a cook is a region written verbatim.

It takes the SLOT and not its value, because a self-relative delta means nothing without the address it is relative to.

type TableAllocator

type TableAllocator struct {
	Alloc func(int64) []byte
	Free  func([]byte)
}

TableAllocator owns authoring and temporary writer storage. Both callbacks are required together; an empty pair uses Go-owned storage. Alloc supplies zeroed bytes aligned to tableRegionAlign and may return more than requested. Free always receives the original slice, with its original length and base. Load and LoadMeasure use caller buffers and never call this pair.

type TableArena

type TableArena struct {
	Allocator TableAllocator
	Locked    bool
	// contains filtered or unexported fields
}

func (*TableArena) At

func (a *TableArena) At(ref TableRef) unsafe.Pointer

func (*TableArena) Init

func (a *TableArena) Init(allocator ...TableAllocator) bool

func (*TableArena) Shutdown

func (a *TableArena) Shutdown()

type TableBitReader

type TableBitReader struct {
	Buffer []byte
	Offset int64
}

func (*TableBitReader) Align

func (r *TableBitReader) Align() bool

func (*TableBitReader) Get

func (r *TableBitReader) Get(n int64) (uint64, bool)

func (*TableBitReader) Skip

func (r *TableBitReader) Skip(n int64) bool

type TableBitWriter

type TableBitWriter struct {
	Buffer              []byte
	Bits                int64
	Measuring, Overflow bool
}

TableBitWriter uses the packet wire's low-bit-first order. Measuring walks the identical stream, including alignment, without touching a buffer.

func (*TableBitWriter) Align

func (w *TableBitWriter) Align()

func (*TableBitWriter) Put

func (w *TableBitWriter) Put(value uint64, n int64)

func (*TableBitWriter) Raw

func (w *TableBitWriter) Raw(data []byte)

type TableBlob

type TableBlob struct {
	Length uint32
	Zero   uint32
}

Blob ABI follows the established tool and C++ byte contract: u32 length, u32 zero. SPEC-TABLES §7.2 currently labels this u64; the big-endian fixtures distinguish them.

func TableBlobAt

func TableBlobAt(slot *TableRef, arena ...*TableArena) *TableBlob

type TableBuildVersionMismatch

type TableBuildVersionMismatch struct{ Peer, Own uint64 }

TableBuildVersionMismatch is the typed error a strict announcement refusal reports (mas-bandwidth/schema docs/SPEC-TABLES.md §3.3): the peer's build version and the reader's own, each a 64-bit number.

func (TableBuildVersionMismatch) Error

type TableByteOrder

type TableByteOrder uint8

TableByteOrder selects the target order, independently of the writing host.

const (
	TableByteOrderLittle TableByteOrder = 1
	TableByteOrderBig    TableByteOrder = 2
)

type TableBytesView

type TableBytesView struct {
	Data   []byte
	Length int64
}

TableBytesView borrows its backing region or arena. Keep that storage alive and do not free, reuse, or shut it down while using the view.

func TableBytesAt

func TableBytesAt(slot *TableRef, arena ...*TableArena) TableBytesView

type TableCookFieldInfo

type TableCookFieldInfo struct {
	Name          string
	Offset        int32 // the field's offset in the record this descriptor describes
	Size          int32 // its whole storage there, companions included
	ElemSize      int32 // one element's size, for an array; the field's own otherwise
	IsArray       bool
	ArrayBound    int32 // the DECLARED bound: a counted array's N, a string's or bytes' length
	IsPointer     bool  // an eight-byte SIGNED SELF-RELATIVE delta slot (§6.3)
	CountOffset   int32 // the count companion's offset, or -1 when the field has none
	PresentOffset int32 // an optional's presence bool, or -1
	Storage       TableCookStorage
	// Record is the record this field NAMES, behind a function so the table
	// stays constructible in any order — Go refuses an initialisation cycle
	// among package-level variables, and the DESCRIPTOR graph is cyclic by
	// design: a record's field column can name its own record. A cooked REGION
	// is never cyclic; schema cook refuses one by name (§3.1).
	// nil when the field is a scalar. Following it is how a walker DESCENDS: a
	// pointer's target, a by-value nesting, and an array's element are all
	// reached through this one column.
	Record func() *TableCookInfo
}

TableCookFieldInfo is one record's field as DATA — the mechanism behind a reflective read of a cooked region, and what a gate walks a whole graph with. A field carries the facts a region actually has: where it sits, how big it is, whether it is a POINTER EDGE, the bound its COUNT COMPANION is checked against, and the record it names.

type TableCookInfo

type TableCookInfo struct {
	Name      string
	Size      int32
	Align     int32
	NumFields int32
	Fields    []TableCookFieldInfo
}

TableCookInfo is one cooked record's layout as DATA.

type TableCookStorage

type TableCookStorage uint8

TableCookStorage is what a cooked SLOT holds, which is not always what the WIRE carries: an ENUM slot holds the ORDINAL at the enum's own derived storage width (mas-bandwidth/schema docs/SPEC-TABLES.md §7.2), where the wire rides the variant-name hash. A walker reads a slot with the width ElemSize gives and the signedness this names.

Its members are FLAT package-level constants, which is what Go already does with every enum a schema declares (SPEC.md §6.1's Go column) — so all eight spellings are claimed in mas-bandwidth/schema internal/tablenames, exactly as a declared enum's variants are claimed by the checker. C# spells the same vocabulary as one scoped enum and claims one name; the port does not get to have it both ways, and the flat form is the one a Go consumer expects to write.

const (
	TableCookStorageRecord    TableCookStorage = iota // a nested record, or an array of them: descend through it
	TableCookStorageReference                         // an eight-byte SIGNED SELF-RELATIVE delta slot (§6.3)
	TableCookStorageBool
	TableCookStorageSigned
	TableCookStorageUnsigned // an unsigned integer, an enum ordinal, a bits(N), a flags mask
	TableCookStorageFloat
	TableCookStorageString // char[N + 1] with an int32 used length beside it
	TableCookStorageBytes  // uint8[N] with an int32 used length beside it
)

type TableExtentCarve

type TableExtentCarve struct {
	Base      unsafe.Pointer
	At, Limit int64
	Worker    *TableWorker
	Refused   bool
}

func (*TableExtentCarve) Alloc

func (c *TableExtentCarve) Alloc(n, align int64) unsafe.Pointer

type TableFieldInfo

type TableFieldInfo struct {
	CookOffset, CookElemSize, CookCountOffset, CookPresentOffset uint32
	List, Map                                                    bool // unbounded by-value containers
	ElemAlign                                                    uint32
	Name                                                         string // schema field name, e.g. "health"
	Json                                                         string // the TEXT form's key: the json = "key" attribute, else Name (§16.3)
	TypeName                                                     string // schema element type, e.g. "float32", "Grade"
	DeclaredTypeName                                             string // complete schema spelling including arrays, bounds and pointers
	Id                                                           uint64 // table-wire field id (name hash; the was alias's hash after a rename)
	Pointer                                                      bool
	TargetId                                                     uint64
	Kind                                                         uint8 // table-wire kind; for arrays/strings/bytes, the ELEMENT kind
	IsArray                                                      bool  // fixed or counted array (bytes included)
	Counted                                                      bool  // a <Name>Count/<Name>Length int32 companion exists
	Optional                                                     bool  // a ?T field: a <Name>Present bool decides whether it rides

	ArrayBound    int32  // array capacity / string max length; 0 for plain scalars
	Offset        uint32 // unsafe.Offsetof the storage member
	ElemSize      uint32 // unsafe.Sizeof the member (element size for arrays)
	CountOffset   uint32 // unsafe.Offsetof the count/length companion, or 0xffffffff
	PresentOffset uint32 // unsafe.Offsetof the Present companion, or 0xffffffff

	FracBits         uint8 // fixed-point binary scale
	WideRange        bool
	WideMin, WideMax [2]uint64 // exact two-complement raw bounds, low lane first
	HasRange         bool      // a declared [min, max] (int or float)
	RangeMin         float64   // NOTE: int64 ranges beyond 2^53 lose precision here
	RangeMax         float64

	// EnumMax bounds the vocabulary: enums, the highest valid value (None = 0
	// is always valid); unions, the arm count (tag range [0, EnumMax]); a
	// FLAGS field, the highest declared BIT INDEX; else -1.
	EnumMax int64
	// EnumName is the vocabulary's names, indexed the way EnumMax bounds: an
	// enum's value -> name, a union's tag -> arm name, a FLAGS field's bit
	// index -> variant name. nil for every other kind.
	EnumName func(value uint64) string
	// VariantId is the TABLE-WIRE id of one variant (mas-bandwidth/schema docs/SPEC-TABLES.md §5): for
	// an enum, the hash of the variant's name; for a union, the hash of the
	// arm's name. Hash zero is an ordinary id; ordinal zero is None. nil
	// for every other kind — a FLAGS field's variants have no per-variant wire
	// id (§4), so a nil here beside a non-nil EnumName is what says "flags".
	VariantId func(value uint64) uint64

	// an ENUM-KEYED array (mas-bandwidth/schema docs/SPEC-TABLES.md §2.4, §8): the array has one slot
	// per variant of KeyTypeName, indexed by the variant's value, and its
	// slots ride under variant ids rather than positions. KeyName and KeyId
	// are the key's vocabulary — walk [0, ArrayBound) to print slots by name.
	// All three are nil/"" on every other field.
	KeyTypeName string
	KeyName     func(value uint64) string
	KeyId       func(value uint64) uint64

	// Arms is a union field's shape: the tag and the arms indexed by it, behind
	// a function so a descriptor graph needs no initialization order. nil for
	// every other kind.
	Arms func() *TableUnionInfo

	Guard string // branch guard, e.g. "at_rest" or "!at_rest"; "" if unguarded

	// Table is the nested table's descriptor, or nil. Held as a factory rather
	// than a value so a descriptor graph needs no initialization order: Go
	// refuses an initialization cycle across package-level variables, and a
	// table may name one declared later.
	Table func() *TableTypeInfo

	// what a PERSON wrote about the field (mas-bandwidth/schema docs/SPEC-TABLES.md §8.1): the ///
	// block above it, verbatim (SPEC §4.1). It is TableDocNone when there is
	// none, never nil. Its tags (SPEC §4.2) follow in declared order, and an
	// untagged field is 0 beside a nil list. Static package data, allocating
	// nothing.
	Doc     string
	NumTags int32
	Tags    []string
}

TableFieldInfo is one field's descriptor.

type TableFixedDst

type TableFixedDst struct {
	Dst, Stride, Aux   uint32
	Counted, Arg, Meta uint8
}

type TableFixedEntry

type TableFixedEntry struct {
	Src, Dst, Size, Aux, Guard uint32
	// Arg IS THE GUARD'S ORDINAL AT FULL WIDTH (mas-bandwidth/schema docs/FIXED-FORM-ALGORITHM.md
	// §4.1: arg : u64, "no byte lane anywhere"): a union past 255 arms or an
	// enum past 65535 variants holds its ordinal whole in this lane, and the
	// compare is made against the 64-bit tag load, never a truncation of it.
	Arg uint64
	// Guard2 / Arg2 / ArgW2 ARE THE OUTER TAG AN ARM INSIDE AN ARM ALSO ANSWERS
	// TO (mas-bandwidth/schema docs/FIXED-FORM-ALGORITHM.md §4.1): the entry runs only when BOTH tags
	// hold their ordinal. ArgW2 of zero is "no outer tag", so a plan that never
	// nests a union leaves the lane unset and the read is unchanged.
	Guard2 uint32
	Arg2   uint64
	// GuardIndex / GuardCount ARE THE GUARD CHAIN (mas-bandwidth/schema docs/FIXED-FORM-ALGORITHM.md
	// §4.1): offset+count into a pool of (guard, arg, argw) links, OUTERMOST
	// FIRST. GuardIndex is a BYTE OFFSET from the plan's own base, where the pool
	// is laid behind the entries the way the ordinal remap tables are, so the
	// plan stays one slice and the read loop one signature. Every guarded entry
	// carries its whole chain; the two lanes above stay its innermost two, the
	// special case, so the loop walks the pool only for a chain past two. The
	// only bound on a chain is the layout's 64 (tableFixedMaxDepth).
	GuardIndex, GuardCount               uint32
	Op, ArgW, DstSize, Sign, Meta, ArgW2 uint8
}

Arg is the guard's arm ordinal: tableFixedRun compares src[Guard] against it. Meta is a text entry's flavour (tableFixedTextUtf8/Wide/Bytes). They shared one lane until reference-fix 12; compiling a string under a union arm overwrote the guard with the flavour and the read skipped the string. tableFixedEntryBytes is the FILE layout entry (id+kind+size+children), not this in-memory plan row — Meta does not ride the wire. ArgW IS THE GUARD'S WIDTH IN BYTES (§5.2 THE GUARD'S WIDTH): a union tag is one, two, four or eight bytes, clamped 1..8, and 0 reads as 1. The guard is tested at that FULL width and never at its first byte — a foreign two-byte tag 0x0101 is not arm 1. Arg is the arm ordinal and carries NO BYTE LANE (§5.8 row 5): a 256-arm union's ordinal does not fit a byte.

type TableFixedGuardLink struct {
	Guard uint32
	Arg   uint64
	ArgW  uint8
}

TableFixedGuardLink is ONE LINK of a guard chain (mas-bandwidth/schema docs/FIXED-FORM-ALGORITHM.md §4.1): the offset of the tag it reads, the ordinal the tag must hold, and the width it is compared at. A chain is a CONJUNCTION — every link must hold.

type TableFixedKnownLayout

type TableFixedKnownLayout struct {
	Hash        uint64
	Layout      []byte
	LayoutBytes int
	Record      int64
}

TableFixedKnownLayout is one locked layout: the wire hash a file is matched on, the layout bytes verbatim with its byte length BESIDE the pointer, and the RECORD SIZE taken from the lock and never from the file. The members are §5.9 #19's: hash, layout, layout_bytes, record_bytes, in that order.

type TableIds

type TableIds struct {
	Numbering *TableNumbering
	Values    [tableIdCapacity]uint64

	Count    int
	Overflow bool
	// contains filtered or unexported fields
}

TableIds interns the writer's ids in first-use order. Bucket links are one-based so its zero value is ready to use, including for hash zero.

func (*TableIds) Ref

func (ids *TableIds) Ref(id uint64) uint64

func (*TableIds) RefAt

func (ids *TableIds) RefAt(ordinal int, id uint64) uint64

RefAt is Ref for a compile-time-constant id. The ordinal is that id's index in TableWireIds. A hit is one load and one compare; first-use order is still append order. Truncate clears the ordinal in O(popped) so a speculative intern does not leak into the next walk. An ordinal outside the slot range falls back to Ref; it does not index slot.

func (*TableIds) Truncate

func (ids *TableIds) Truncate(mark int)

Truncate removes speculative ids when a measured field elides, or before writing the payload whose size was just measured under the same vocabulary.

type TableList

type TableList[T any] struct {
	Ref   int64
	Count int32
	// contains filtered or unexported fields
}

func (*TableList[T]) At

func (l *TableList[T]) At(index int32, arena ...*TableArena) *T

func (*TableList[T]) Clear

func (l *TableList[T]) Clear()

type TableMap

type TableMap[T any] struct {
	Ref   int64
	Count int32
	// contains filtered or unexported fields
}

func (*TableMap[T]) At

func (m *TableMap[T]) At(index int32, arena ...*TableArena) *T

func (*TableMap[T]) Clear

func (m *TableMap[T]) Clear()

type TableMapIndex

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

type TableMessageEntry

type TableMessageEntry struct {
	Id             uint64
	Shape, Element TableMessageShape
}

type TableMessageReader

type TableMessageReader struct {
	Nodes      TableNodeMap
	Bits       TableBitReader
	Vocabulary *TableVocabulary
	Report     TableReport
	IndexBits  int64
}

type TableMessageShape

type TableMessageShape struct {
	Kind, Packing uint8
	Bits          int64
	Base          [2]uint64
	Min, Max      int64
	QMin, QDelta  float32
	QCount        uint32
}

type TableMessageWriter

type TableMessageWriter struct {
	TableBitWriter
	IndexBits int64
	Clamped   int32
	Numbering *TableNumbering
	// contains filtered or unexported fields
}

type TableMissingRequired

type TableMissingRequired struct{ Fields string }

TableMissingRequired is the typed error a strict read reports for a record that lacks a | required field (mas-bandwidth/schema docs/SPEC-TABLES.md §2.3): Fields names the missing fields, comma-separated in declaration order, at whatever depth of the record they were missing, and Error() is the report's own reason.

func (TableMissingRequired) Error

func (m TableMissingRequired) Error() string

type TableNodeDirEntry

type TableNodeDirEntry struct{ Offset, TypeId uint64 }

type TableNodeMap

type TableNodeMap struct {
	Carve   TableExtentCarve
	Base    unsafe.Pointer
	Entries []TableNodeDirEntry
	Good    bool
	Arena   bool
}

func (TableNodeMap) Resolve

func (m TableNodeMap) Resolve(slot *TableRef, index, target uint64, r *TableReport)

type TableNumbering

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

The root and arena keep the source storage live while pointer-free backing allocations hold the index and entries. Temporary storage is released by caller.

func (*TableNumbering) Index

func (n *TableNumbering) Index(slot *TableRef) (uint64, bool)

func (*TableNumbering) Release

func (n *TableNumbering) Release()

type TableOpenVerdict

type TableOpenVerdict uint8

TableOpenVerdict distinguishes an unsupported form from framing damage.

const (
	TableOpenOk TableOpenVerdict = iota
	TableOpenRefused
	TableOpenDamaged
	TableOpenBodyStopped
)

type TableReader

type TableReader struct {
	Nodes  TableNodeMap
	Buffer []byte
	Offset int64
	Report *TableReport
	Ids    []byte
	Nested bool
}

TableReader holds one bounded body and a view of the file's id trailer. Sub-readers share the trailer and report, but cannot consume sibling bytes.

func (*TableReader) Body

func (r *TableReader) Body() (TableReader, bool)

func (TableReader) EndsEarly

func (r TableReader) EndsEarly() bool

EndsEarly only recognizes an otherwise walkable body's early terminator. Other damage is decoded normally, preserving the prefix already read.

func (*TableReader) Get8

func (r *TableReader) Get8() uint8

func (*TableReader) Get16

func (r *TableReader) Get16() uint16

func (*TableReader) Get32

func (r *TableReader) Get32() uint32

func (*TableReader) Get64

func (r *TableReader) Get64() uint64

func (*TableReader) Has

func (r *TableReader) Has(n int64) bool

func (*TableReader) Leb

func (r *TableReader) Leb() (uint64, bool)

A rejected integer leaves the cursor unchanged. Its spelling must be minimal and fit in 64 bits, including the tenth byte's single value bit.

func (*TableReader) Resolve

func (r *TableReader) Resolve(ref uint64) (uint64, bool)

func (*TableReader) Room

func (r *TableReader) Room(n uint64) bool

func (*TableReader) Signed

func (r *TableReader) Signed(kind uint8) int64

func (*TableReader) Skip

func (r *TableReader) Skip(kind uint8) bool

func (*TableReader) Sub

func (r *TableReader) Sub(n int64) TableReader

func (*TableReader) Take

func (r *TableReader) Take(sub TableReader)

func (*TableReader) Unsigned

func (r *TableReader) Unsigned(kind uint8) uint64

type TableRef

type TableRef = int64

type TableRefuseReason

type TableRefuseReason uint8

TableRefuseReason is the typed error shared by file and accelerator failures. A successful call returns nil; a failure returns its first failing clause.

const (
	TableRefuseOk TableRefuseReason = iota
	TableRefuseNotACook
	TableRefuseForeignOrder
	TableRefuseWrongBuildVersion
	TableRefuseReservedNotZero
	TableRefuseBadAlignment
	TableRefuseTruncated
	TableRefuseUnalignedBase
	TableRefuseBadLayout
	TableRefuseUnknownForm
	TableRefuseCountOverLength
	TableRefuseCountOverExtentCap
	TableRefuseBlobOverSizeCap
	TableRefuseDataCycle
	TableRefuseInvalidValue
	TableRefuseAllocationFailed
	TableRefuseWireDamaged
	TableRefuseMalformed
	TableRefuseClamped
	TableRefuseKindMismatch
	TableRefuseBase64Damaged
)

func (TableRefuseReason) Error

func (r TableRefuseReason) Error() string

type TableReport

type TableReport struct {
	Retained, RetainLost int32
	Verdict              TableOpenVerdict // unsupported form is distinct from damage
	Reason               string           // why the form was refused; empty for a file read
	Widened              int32            // a compatible wider kind preserved the value
	Unknown              int32            // unknown field ids skipped (newer data)
	KindMismatch         int32            // known id, changed type — skipped, never misdecoded
	Clamped              int32            // out-of-range values clamped to declared bounds
	// Duplicate counts repeated text keys. Fixed-class wire fields do not raise it.
	// A body carrying an id twice is legal input
	// whose last occurrence wins, silently. A wire read always leaves it zero.
	Duplicate int32
	// MissingRequired counts required fields (mas-bandwidth/schema docs/SPEC-TABLES.md §2.3) the
	// record did not carry: a record an older writer produced before the field
	// became required. The refusal names the field in Reason.
	MissingRequired int32
	Malformed       bool // framing damage; decode stopped, partial result kept
	// BuildVersionPeer and BuildVersionOwn are the two build versions a strict
	// announcement refusal carries (mas-bandwidth/schema docs/SPEC-TABLES.md §3.3): the peer's
	// announcement and this unit's own. They are zero on every other read.
	BuildVersionPeer uint64
	BuildVersionOwn  uint64
	// LayoutHash is THE FILE'S hash, and it is set by ONE refusal:
	// layout_newer reports it "AND NOTHING ELSE" (§5.3). layout_unsupported
	// reports it too — the operator's other answer, a layout this build served
	// and has retired.
	LayoutHash uint64
}

TableReport is the table-wire read report — the permissive contract's ledger. Silence (all zero) means the data matched this reader's schema exactly. Err (mas-bandwidth/schema docs/SPEC-TABLES.md §6.5) is the STRICT read's typed reason for malformed, clamped, kind-mismatched, unknown form, wire-damaged and build-version-mismatched. Unknown, Widened and Retained alone are not one.

func (*TableReport) Err

func (r *TableReport) Err() error

Err is the report's typed error (mas-bandwidth/schema docs/SPEC-TABLES.md §6.5, mas-bandwidth/schema docs/VERSIONING.md The read report). A strict read refuses malformed, clamped, kind-mismatched, unknown form, wire-damaged, build-version-mismatched and missing-required (§2.3, naming the field), each as one typed reason. Unknown, Widened and Retained alone leave it nil, as does a clean read.

type TableRetain

type TableRetain struct {
	Bytes []byte
	Ids   []TableRetainId
	Used  int64
	Count int
	// contains filtered or unexported fields
}

type TableRetainId

type TableRetainId struct {
	Id   uint64
	Slot int
}

type TableRetainIds

type TableRetainIds struct {
	Numbering      *TableNumbering
	Retain         *TableRetain
	Path           tableRetainPath
	Count          int
	Overflow, Lost bool
	// contains filtered or unexported fields
}

func (*TableRetainIds) Ref

func (i *TableRetainIds) Ref(id uint64) uint64

func (*TableRetainIds) RefAt

func (i *TableRetainIds) RefAt(ordinal int, id uint64) uint64

func (*TableRetainIds) Truncate

func (i *TableRetainIds) Truncate(mark int)

type TableRetainMessageReader

type TableRetainMessageReader struct {
	Retain *TableRetain
	Path   tableRetainPath
	// contains filtered or unexported fields
}

type TableRetainReader

type TableRetainReader struct {
	Retain *TableRetain
	Path   tableRetainPath
	// contains filtered or unexported fields
}

func (*TableRetainReader) Body

func (*TableRetainReader) Take

func (r *TableRetainReader) Take(sub TableRetainReader)

type TableRetainWriter

type TableRetainWriter struct {
	Buffer    []byte
	Offset    int64
	Overflow  bool
	Measuring bool
	Ids       *TableRetainIds
}

func (*TableRetainWriter) Advance

func (w *TableRetainWriter) Advance(n int64) bool

func (*TableRetainWriter) Header

func (w *TableRetainWriter) Header(ref uint64, kind uint8)

Header writes a field's reference and kind. A reference below 128 is one LEB byte, so the pair is one two-byte store. Larger references still go through PutLeb then Put8. Bytes match that two-call spelling; a pair that does not fit now leaves the buffer alone, and Save answers -1.

func (*TableRetainWriter) Id

func (w *TableRetainWriter) Id(id uint64)

func (*TableRetainWriter) IdAt

func (w *TableRetainWriter) IdAt(ordinal int, id uint64)

func (*TableRetainWriter) Put8

func (w *TableRetainWriter) Put8(v uint8)

func (*TableRetainWriter) Put16

func (w *TableRetainWriter) Put16(v uint16)

func (*TableRetainWriter) Put32

func (w *TableRetainWriter) Put32(v uint32)

func (*TableRetainWriter) Put64

func (w *TableRetainWriter) Put64(v uint64)

func (*TableRetainWriter) Put128

func (w *TableRetainWriter) Put128(lo, hi uint64)

Put128 writes two little-endian lanes, low first, under one Advance.

func (*TableRetainWriter) PutLeb

func (w *TableRetainWriter) PutLeb(v uint64)

func (*TableRetainWriter) Raw

func (w *TableRetainWriter) Raw(data []byte)

func (*TableRetainWriter) Trailer

func (w *TableRetainWriter) Trailer()

type TableStringView

type TableStringView struct {
	Data   []byte
	Length int64
}

TableStringView has the same borrowed lifetime as TableBytesView.

func TableStringAt

func TableStringAt(slot *TableRef, arena ...*TableArena) TableStringView

type TableTimestampError

type TableTimestampError struct {
	Field string
	Time  time.Time
}

TableTimestampError is the refusal of a time.Time that no count names: its nanoseconds since the Unix epoch do not fit an int64, which is Time.UnixNano's own domain, the years 1678 through 2262 (mas-bandwidth/schema docs/SPEC-TABLES.md §2.11).

func (TableTimestampError) Error

func (e TableTimestampError) Error() string

type TableTypeInfo

type TableTypeInfo struct {
	SaveBodyRetain        func(*TableRetainWriter, unsafe.Pointer) bool
	LoadBodyRetain        func(TableRetainReader, unsafe.Pointer) bool
	LoadMessageBodyRetain func(TableRetainMessageReader, unsafe.Pointer) (TableRetainMessageReader, bool)
	CookSize, CookAlign   uint32
	Name                  string // schema type name
	Size                  uint32 // unsafe.Sizeof the storage struct
	Id                    uint64
	Variable              bool
	NodeType              func(uint64) *TableTypeInfo
	SaveBody              func(*TableWriter, unsafe.Pointer) bool
	LoadBody              func(TableReader, unsafe.Pointer) bool
	SaveMessageBody       func(*TableMessageWriter, unsafe.Pointer) bool
	LoadMessageBody       func(TableMessageReader, unsafe.Pointer) (TableMessageReader, bool)
	NumFields             int32
	Fields                []TableFieldInfo
	// Reset puts one instance back at its declared defaults, in place. A
	// generic walker that fills a value has to be able to establish the
	// defaults an absent field takes, and it holds no type to spell — this is
	// the one thing the descriptors could not express without it.
	Reset func(storage unsafe.Pointer)

	// the declaration's own doc and tags, on the same terms as a field's
	// (mas-bandwidth/schema docs/SPEC-TABLES.md §8.1, SPEC §4.1, §4.2)
	Doc     string
	NumTags int32
	Tags    []string
}

TableTypeInfo is one type's descriptor.

var CairnLogRecordTableInfo TableTypeInfo

CairnLogRecordTableInfo is CairnLogRecord's reflection descriptor (mas-bandwidth/schema docs/SPEC-TABLES.md §8).

var DogfoodReceiptTableInfo TableTypeInfo

DogfoodReceiptTableInfo is DogfoodReceipt's reflection descriptor (mas-bandwidth/schema docs/SPEC-TABLES.md §8).

var FuseBoxTableInfo TableTypeInfo

FuseBoxTableInfo is FuseBox's reflection descriptor (mas-bandwidth/schema docs/SPEC-TABLES.md §8).

var FuseTableInfo TableTypeInfo

FuseTableInfo is Fuse's reflection descriptor (mas-bandwidth/schema docs/SPEC-TABLES.md §8).

var LedgerKeyTableInfo TableTypeInfo

LedgerKeyTableInfo is LedgerKey's reflection descriptor (mas-bandwidth/schema docs/SPEC-TABLES.md §8).

var LedgerValueTableInfo TableTypeInfo

LedgerValueTableInfo is LedgerValue's reflection descriptor (mas-bandwidth/schema docs/SPEC-TABLES.md §8).

var QuarantineEntryTableInfo TableTypeInfo

QuarantineEntryTableInfo is QuarantineEntry's reflection descriptor (mas-bandwidth/schema docs/SPEC-TABLES.md §8).

var TokenValueTableInfo TableTypeInfo

TokenValueTableInfo is TokenValue's reflection descriptor (mas-bandwidth/schema docs/SPEC-TABLES.md §8).

func CairnLogRecordTableType

func CairnLogRecordTableType() *TableTypeInfo

CairnLogRecordTableType returns CairnLogRecord's reflection descriptor.

func DogfoodReceiptTableType

func DogfoodReceiptTableType() *TableTypeInfo

DogfoodReceiptTableType returns DogfoodReceipt's reflection descriptor.

func FuseBoxTableType

func FuseBoxTableType() *TableTypeInfo

FuseBoxTableType returns FuseBox's reflection descriptor.

func FuseTableType

func FuseTableType() *TableTypeInfo

FuseTableType returns Fuse's reflection descriptor.

func LedgerKeyTableType

func LedgerKeyTableType() *TableTypeInfo

LedgerKeyTableType returns LedgerKey's reflection descriptor.

func LedgerValueTableType

func LedgerValueTableType() *TableTypeInfo

LedgerValueTableType returns LedgerValue's reflection descriptor.

func QuarantineEntryTableType

func QuarantineEntryTableType() *TableTypeInfo

QuarantineEntryTableType returns QuarantineEntry's reflection descriptor.

func TokenValueTableType

func TokenValueTableType() *TableTypeInfo

TokenValueTableType returns TokenValue's reflection descriptor.

type TableUnionArmInfo

type TableUnionArmInfo struct {
	Field  TableFieldInfo               // arm shape; offsets are relative to union storage
	Void   bool                         // a selected payload-free arm
	Reset  func(storage unsafe.Pointer) // establish selected payload defaults
	Offset uint32                       // unsafe.Offsetof the arm's payload within the union storage
	Table  func() *TableTypeInfo        // the arm payload's descriptor
}

TableUnionArmInfo is one arm of a union field: where its payload sits inside the union's storage and what its payload looks like. The arm's NAME and its table-wire id come from the field's EnumName/VariantId functions at the same tag, so nothing is spelled twice (mas-bandwidth/schema docs/SPEC-TABLES.md §8).

type TableUnionInfo

type TableUnionInfo struct {
	CookTagSize uint32
	TagOffset   uint32 // unsafe.Offsetof the tag within the union storage
	TagSize     uint32 // unsafe.Sizeof the tag
	Arms        []TableUnionArmInfo
}

TableUnionInfo is a union field's shape: the tag, and the arms indexed by it. Arms run [0, EnumMax]; index 0 is the EMPTY arm and carries no payload.

type TableVocabulary

type TableVocabulary struct {
	Entries            []TableMessageEntry
	Count, RefBits     int64
	BuildVersion       uint64
	Announced, Refused bool
	MaxBytes           int64
	Strict             bool
}

Storage belongs to the caller and is resolved once for one connection direction.

func (*TableVocabulary) Entry

func (v *TableVocabulary) Entry(ref uint64) (TableMessageEntry, bool)

func (*TableVocabulary) Init

func (v *TableVocabulary) Init(storage []TableMessageEntry)

func (*TableVocabulary) Name

func (v *TableVocabulary) Name(ref uint64) (uint64, bool)

type TableWorker

type TableWorker struct {
	Arena *TableArena
	// contains filtered or unexported fields
}

func (*TableWorker) Alloc

func (w *TableWorker) Alloc(n int64) (unsafe.Pointer, TableRef)

func (*TableWorker) AllocBytes

func (w *TableWorker) AllocBytes(length int64) ([]byte, TableRef)

func (*TableWorker) AllocString

func (w *TableWorker) AllocString(length int64) ([]byte, TableRef)

type TableWriteContext

type TableWriteContext interface {
	// contains filtered or unexported methods
}

TableWriteContext selects allocation independently from reference addressing. Pass a TableAllocator for a loaded/locked region, or *TableArena for authoring references and that arena's allocation pair. Omit it for Go-owned temporaries.

type TableWriter

type TableWriter struct {
	Buffer    []byte
	Offset    int64
	Overflow  bool
	Measuring bool
	Ids       *TableIds
}

TableWriter writes into the caller's buffer, or counts exactly the same bytes in Measuring mode. Offset and every length are checked before use.

func (*TableWriter) Advance

func (w *TableWriter) Advance(n int64) bool

func (*TableWriter) Header

func (w *TableWriter) Header(ref uint64, kind uint8)

Header writes a field's reference and kind. A reference below 128 is one LEB byte, so the pair is one two-byte store. Larger references still go through PutLeb then Put8. Bytes match that two-call spelling; a pair that does not fit now leaves the buffer alone, and Save answers -1.

func (*TableWriter) Id

func (w *TableWriter) Id(id uint64)

func (*TableWriter) IdAt

func (w *TableWriter) IdAt(ordinal int, id uint64)

func (*TableWriter) Put8

func (w *TableWriter) Put8(v uint8)

func (*TableWriter) Put16

func (w *TableWriter) Put16(v uint16)

func (*TableWriter) Put32

func (w *TableWriter) Put32(v uint32)

func (*TableWriter) Put64

func (w *TableWriter) Put64(v uint64)

func (*TableWriter) Put128

func (w *TableWriter) Put128(lo, hi uint64)

Put128 writes two little-endian lanes, low first, under one Advance.

func (*TableWriter) PutLeb

func (w *TableWriter) PutLeb(v uint64)

func (*TableWriter) Raw

func (w *TableWriter) Raw(data []byte)

func (*TableWriter) Trailer

func (w *TableWriter) Trailer()

type TokenValue

type TokenValue = TokenValueRow

func TokenValueLoad

func TokenValueLoad(region, wire []byte, report *TableReport) *TokenValue

func TokenValueLoadRetain

func TokenValueLoadRetain(region, wire []byte, retain *TableRetain, report *TableReport) *TokenValue

func TokenValueLoadText

func TokenValueLoadText(text string, report *TableReport) (*TokenValue, error)

TokenValueLoadText reads one TokenValue from a base64 wire text (mas-bandwidth/schema docs/SPEC-TABLES.md §16.8) into a builder of its own and returns the locked root, as TokenValueReadStrict does: it is the STRICT read (§6.5) and refuses whenever the read's report holds an error (TableReport.Err), whatever the tolerant LoadBuilder answered, so a recovered value never comes back. It refuses by name: base64_damaged when the body does not decode, unknown_form when the decoded wire's form byte is not one this build carries, wire_damaged for framing damage, and the report's own reason (malformed, clamped, kind_mismatch, ...) otherwise. A nil report is allowed; a supplied one receives THIS read's report, so earlier counts in it never decide.

func TokenValueReadStrict

func TokenValueReadStrict(wire []byte) (*TokenValue, error)

TokenValueReadStrict is the STRICT read (mas-bandwidth/schema docs/SPEC-TABLES.md §6.5): one call, its own builder, one typed reason.

type TokenValueBuilder

type TokenValueBuilder struct {
	Arena TableArena
	Main  TableWorker
	// contains filtered or unexported fields
}

func (*TokenValueBuilder) AsConst

func (b *TokenValueBuilder) AsConst() *TokenValue

func (*TokenValueBuilder) GetRoot

func (b *TokenValueBuilder) GetRoot() *TokenValue

func (*TokenValueBuilder) Init

func (b *TokenValueBuilder) Init(allocator ...TableAllocator) bool

func (*TokenValueBuilder) Lock

func (b *TokenValueBuilder) Lock() bool

func (*TokenValueBuilder) PackMeasure

func (b *TokenValueBuilder) PackMeasure() int64

func (*TokenValueBuilder) PackMeasureReason

func (b *TokenValueBuilder) PackMeasureReason() (int64, error)

func (*TokenValueBuilder) Region

func (b *TokenValueBuilder) Region() []byte

func (*TokenValueBuilder) Shutdown

func (b *TokenValueBuilder) Shutdown()

type TokenValueCook

type TokenValueCook struct {
	Region       unsafe.Pointer // the DATA part's base: the root sits at offset zero
	RegionLength int64          // data_length, as the header framed it
}

TokenValueCook is TokenValue's cook: a pointer and a length, and then the root where it lies. Opening one is a HEADER MATCH and no copy; a reference is one add (mas-bandwidth/schema docs/SPEC-TABLES.md §7).

`Cook` is a CLAIMED suffix (§11). C++ spells the same claimed verbs as free functions — TokenValueOpen, TokenValueAt — and so does Go, because Go has free functions; what is a MEMBER here is only what §11 leaves a language free to make one.

THE MEMORY IS THE CONSUMER'S. Nothing here allocates, nothing here copies and nothing here pins: the region must stay put and stay aligned for as long as this handle or anything reached through it is used.

func (*TokenValueCook) Open

func (cook *TokenValueCook) Open(base unsafe.Pointer, length int64) error

Open checks the header in SPEC §7 order, bytewise until base alignment is established. A successful match points at the region and allocates nothing.

func (TokenValueCook) RegionAlignment

func (c TokenValueCook) RegionAlignment() int64

§7.1's constants, so a consumer reading this file has the facts and not a description of them. They are METHODS because §11 leaves a language whose accessors are members free to spell them that way, and a package constant per table per fact would claim names §11 does not.

func (TokenValueCook) Root

func (c TokenValueCook) Root() *TokenValueRow

Root is the root record at the region's base. It is a POINTER and not a copy: a cooked graph is walked by adding deltas to slot addresses.

func (TokenValueCook) RootAlign

func (c TokenValueCook) RootAlign() int64

func (TokenValueCook) RootSize

func (c TokenValueCook) RootSize() int64

func (TokenValueCook) Type

func (c TokenValueCook) Type() *TableCookInfo

Type is TokenValue's cooked-record descriptor, the head of the graph a reflective walk follows (mas-bandwidth/schema docs/SPEC-TABLES.md §8).

type TokenValueRow

type TokenValueRow struct {
	Amount        int64
	AmountPresent bool // ?: one byte, in Go's model as in C++
	// contains filtered or unexported fields
}

TokenValueRow — a cooked record. `Row` is a CLAIMED suffix (mas-bandwidth/schema docs/SPEC-TABLES.md §11), so no declaration in the unit can take it.

func TokenValueAt

func TokenValueAt(slot *int64, arena ...*TableArena) *TokenValueRow

TokenValueAt dereferences a reference, and it is the same call in a locked region and an opened cook because they are the same encoding (§6.3): the slot is eight bytes, SIGNED, self-relative from the SLOT'S OWN ADDRESS, so a deref needs no base pointer and no bounds test, and NULL IS A DELTA OF ZERO. Nothing about this call is the cook's: it is what a region reference is, and a cook is a region written verbatim.

It takes the SLOT and not its value, because a self-relative delta means nothing without the address it is relative to.

type UnitViewInfo

type UnitViewInfo struct {
	Package                                                          string
	ProtocolId                                                       uint64
	NumTypes, NumTables, NumEnums, NumFlags, NumUnions, NumConstants int32
	Types, Tables                                                    []ViewType
	Enums, Flags, Unions                                             []ViewVocabulary
	Constants                                                        []ViewConstant
}

func UnitView

func UnitView() *UnitViewInfo

type ViewConstant

type ViewConstant struct {
	Name, File, TypeName string
	IsFloat              bool
	IntValue             int64
	FloatValue           float64
	Doc                  string
	NumTags              int32
	Tags                 []string
}

UnitView returns this build's registry. Treat its descriptors and slices as immutable; lookups allocate nothing. Packet-only types gain no table codec. A packet dependency can use different storage from its table Row; its descriptor follows that storage, so every offset remains valid for the value.

type ViewType

type ViewType struct {
	Name, File string
	Table      bool
	Type       *TableTypeInfo
	Doc        string
	NumTags    int32
	Tags       []string
}

type ViewVariant

type ViewVariant struct {
	Value       uint64
	Name        string
	Id          uint64
	PayloadName string
	Payload     func() *TableTypeInfo
	Field       func() *TableFieldInfo
	Doc         string
	NumTags     int32
	Tags        []string
}

type ViewVocabulary

type ViewVocabulary struct {
	Name, File               string
	Max                      int64
	StorageBits, NumVariants int32
	PayloadOffset            uint32
	Variants                 []ViewVariant
	Doc                      string
	NumTags                  int32
	Tags                     []string
}

Jump to

Keyboard shortcuts

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