Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func DecodeMessage ¶
unpack a map of plain values into a description of a tapestry command. doesn't operate recursively, and doesn't check to see if the command is one that exists.
func DecodeSignature ¶
given a key such as "Command noun:trait:change choice:" separate out the command name and parameter labels
Types ¶
type CustomDecoder ¶
type CustomDecoder func(dec *Decoder, slot *typeinfo.Slot, plainData any) (typeinfo.Instance, error)
create an arbitrary command from arbitrary data ex. boolean literals are stored as actual bool values.
type Decoder ¶
type Decoder struct {
// contains filtered or unexported fields
}
func (*Decoder) Customize ¶
func (dec *Decoder) Customize(c CustomDecoder) *Decoder
customize the handling of specific slots.
func (*Decoder) Decode ¶
given a desired output structure, read the passed plain data note: since plainData can be a primitive value, it's difficult to provide a line offset in error messages here.
func (*Decoder) Patternize ¶
func (dec *Decoder) Patternize(p PatternDecoder) *Decoder
handle conversion of unknown commands to scripted function calls.
type PatternDecoder ¶
type PatternDecoder func(dec *Decoder, slot *typeinfo.Slot, msg compact.Message) (typeinfo.Instance, error)
handle pattern parsing.
type SignatureTable ¶
hash to pointer to a nil value of the type ex. 15485098871275255450: (*Comparison)(nil)