# The top-level structure is a 'define'. This defines either a building-block --
# a 'struct' which can get pulled into the various SNACs -- or a SNAC. SNACs have
# family and subtype, and optionally a channel.
#
# 'ref' is like #include. There are some basic structures, like userinfo, which appear
# inside multiple SNACs.
#
# Then there are the data types:
# Numeric types: byte (8-bit), word (16-bit), dword (32-bit).
# Raw character data: data
# This can have a 'length prefix' attached to it.
# The length prefix is a numeric type. The value of the length prefix
# is the number of bytes of character data. The existence of this
# length prefix is why it might be useful for data to have sub-data.
# Data types can have 'counts'. A count of -1 represents an infinite count.
# Counted data is passed around as a listref. For instance, a capabilities block
# is a series of 16-byte values, so by attaching count=-1 to that data item,
# you can pass in a listref with the individual capabilities. There is also
# fixed-length character data, specified via the length attribute on the data element.
# Data can be null-terminated and padded. The value for the pad attribute specifies
# the octet value to use for padding.
#
# There are also enums, which are exactly like numeric types except the raw numeric
# values gets translated into some other values, so if you have a message-type
# word, you can have 1 => "foo", and you'll get a "foo" when decoding a 1 and a
# 1 when encoding a "foo".
#
# Things that have, or can have, length prefixes, take an optional 'default_generate'
# attribute. If set to yes, this will give them a default value of "present but empty".
#
# Note that if you have counted character data, you will get a listref of hashrefs.
# For instance:
#
#
#
#
# Will give you:
# [
# { foo => 1, bar => 2 },
# { foo => 1, bar => 4 },
# ]
#
# You can also have tlvchains and TLVs...
#
# If you attach a name to a TLV, as opposed to elements within that TLV,
# presence of that name in the data hash will correspond with presence of
# that TLV in the TLV chain, without regard to the value of said TLV.
#
#
# family=0 is a global fallback SNAC family. That is:
#
# will get picked up on for all SNACs of subtype 1 where there is no define for
# that specific family.
count_prefix (byte|word|dword) #IMPLIED
length_prefix (byte|word|dword) #IMPLIED
prefix_order (network|vax) #DEFAULT network
length CDATA #IMPLIED
default_generate (yes|no) #DEFAULT no
>
default_generate (yes|no) #DEFAULT no
name CDATA #IMPLIED
count CDATA #IMPLIED
>