procedure: alist->record a record-layout ->
alist record-layout -> record
extract record data from alist using record-layout and result in one record.
currently, string keys are also recognized
syntax: define-record-accessors record-layout (identifier field-name) ...
syntax: define-record-setters record-layout (identifier field-name) ...
procedure: make-record record-layout ->
procedure: make-record-layout field-spec ->
(symbol ...) -> record-layout
results in a new record-layout with the given field names
procedure: record record-layout values ... ->
record-layout (any ...) -> record
create a new record by specifying the layout and the values in
the same order as they are specified in layout field-spec. not all values have to be given, unspecified fields are set to <unspecified>
procedure: record-accessor record-layout field-name ->
record-layout symbol -> procedure {record -> field-value}
returns an accessor procedure for the given record-layout and field-name.
procedure: record-accessors record-layout ->
hashtable:record-layout -> (proc ...)
returns all accessors for the given record-layout in a list
procedure: record-append ->
(vector-append vec ...) -> vector
Return a newly allocated vector that contains all elements in order
from the subsequent locations in VEC ...
procedure: record-field-names record-layout ->
hashtable:record-layout -> vector:#(symbol ...)
result in the field-names of record in the same order as they were specified.
procedure: record-field-names-unordered hashtable ->
procedure: record-layout->predicate a [type-prefix] ->
record-layout [symbol:type-name] -> procedure:{vector -> boolean}
if type-prefix is given, the first field of the record is required to contain the type-prefix
procedure: record-layout-extend! layout-1 layout-2 ->
procedure: record-layout-length hashtable ->
procedure: record-layout-merge! a b ... ->
hashtable hashtable ... -> unspecified
copy the values of hash b to hash a. existing key values are overwritten
procedure: record-layout? obj ->
procedure: record-length a ->
procedure: record-list-filter-value record-list value match-accessor retrieve-accessor ->
list procedure:accessor procedure:accessor -> false/(any ...)
filter record list entries by values retrieved by match-accessor that match the given value,
and return a list of values retrieved by retrieve-accessor
procedure: record-ref record record-layout field-name ->
record record-layout symbol -> any
get the value for field-name of the given record.
record-ref is considerably slower than using an accessor procedure
procedure: record-setter record-layout field-name ->
record-layout symbol -> procedure {record value -> unspecified}
returns a setter procedure for the given layout and field-name
procedure: record-setters record-layout ->
record-layout (symbol ...) -> proc ...
returns all setters for the given layout in a list
procedure: record-take record-layout a ->
this adjusts the length of the given vector to match the length of the layout.
extra fields in are left out if the layout is smaller
procedure: record-update record-layout a field-name/value ... ->
vector [integer any] ... -> vector
create a copy of the given record with values in fields set to new values.
field name and value are given alternatingly.
example: (record-update myrecord (quote a) #\c (quote b) #\d)
syntax: record-update-b record-layout a field-name ...
syntax: record-update-q record-layout a field-name/value ...
procedure: vector->record record-layout a ->
this adjusts the length of the given vector to match the length of the layout.
extra fields in are left out if the layout is smaller