grenada.things.def

Functions and other things constituting the foundation for defining Things.

->aspect

(->aspect name prereqs-pred name-pred)
Generated constructor for the aspect type.

->bar-type

(->bar-type name aspect-prereqs-pred bar-prereqs-pred valid-pred schema)
Generated constructor for the bar-type type.

->main-aspect

(->main-aspect name ncoords prereqs-pred name-pred)
Generated constructor for the main-aspect type.

aspect-defaults

Default values for Aspect definitions.

aspect?

(aspect? x__560__auto__)
Generated predicate for the aspect type.

aspect?+

(aspect?+ x)
Checks whether X is a tagged value of tag type aspect. Throws an exception
if X doesn't adhere to the schema for values of tag type aspect.

AspectSchema

Schema for the programmatic part of Aspect definitions.

assert-bar-valid

(assert-bar-valid bar-type bar)
Throws an exception if BAR doesn't comply to BAR-TYPE.

bar-type?

(bar-type? x__560__auto__)
Generated predicate for the bar-type type.

bar-type?+

(bar-type?+ x)
Checks whether X is a tagged value of tag type bar-type. Throws an exception
if X doesn't adhere to the schema for values of tag type bar-type.

blank-bar-type-def

(blank-bar-type-def bar-tag)
Defines a Bar type with name BAR-TAG that imposes no restrictions at all.

Can be used to attach Bars whose actual definition is not available. Using is
a bit smelly and can only be deodorized by checking the Thing with the proper
Bar type definition later.

main-aspect?

(main-aspect? x__560__auto__)
Generated predicate for the main-aspect type.

main-aspect?+

(main-aspect?+ x)
Checks whether X is a tagged value of tag type main-aspect. Throws an exception
if X doesn't adhere to the schema for values of tag type main-aspect.

map->aspect

(map->aspect m)
Checks whether M is a map adhering to the schema of tag type aspect. If so,
constructs a tagged value of type aspect with this map. Otherwise throws an
exception.

map->bar-type

(map->bar-type m)
Checks whether M is a map adhering to the schema of tag type bar-type. If so,
constructs a tagged value of type bar-type with this map. Otherwise throws an
exception.

map->main-aspect

(map->main-aspect m)
Checks whether M is a map adhering to the schema of tag type main-aspect. If so,
constructs a tagged value of type main-aspect with this map. Otherwise throws an
exception.

map-from-defs

(map-from-defs ds)
Given a sequence of Aspect or Bar type definitions, returns a map mapping
names of Aspects or Bar types to definitions.