class-name
is the name of a class of objects known to KnowledgeWorks.
variable
is a variable beginning with
?
.
slot-name
is the name of a slot in the class.
term
is an expression composed of Lisp data structures and KnowledgeWorks variables.
If variable is unbound a new instance of class class-name is created with the named slots containing the value of the term immediately following the slot name. If variable is bound, that bound instance has its named slots modified to contain the value of the term immediately following the slot name. It is an error if the bound object is not of the named class.
It is an error to put an unbound variable into a slot of an object in the object base.
(assert (truck ?truck driver ?driver))
(assert (possible-trucks ? trucks (?truck . ?trucks))