topheader Welcome 54.227.76.35 @ xps.scios.ch on Sat May 25 17:24:24 CEST 2019
topheader
 
DEFTEMPLATE

DEFTEMPLATE

Ordered facts encode information positionally. To access that information,

a user must know not only what data is stored in a fact but which field

contains the data. Non-ordered (or deftemplate) facts provide the user

with the ability to abstract the structure of a fact by assigning names

to each field found within the fact. The deftemplate construct is

used to create a template which can then be used by non-ordered facts to

access fields of the fact by name. The deftemplate construct is analogous

to a record or structure definition in programming languages such as Pascal

and C.

The syntax of the deftemplate construct is:

(deftemplate <deftemplate-name> [<comment>]
   <slot-definition>*)

<slot-definition>         ::= <single-slot-definition> | 
                              <multislot-definition>

<single-slot-definition>  ::= (slot <slot-name> 
                                    <template-attribute>*)

<multislot-definition>    ::= (multislot <slot-name> 
                                         <template-attribute>*)

<template-attribute>      ::= <default-attribute> |
                              <constraint-attribute>

<default-attribute>  
                   ::= (default ?DERIVE | ?NONE | <expression>*) |
                       (default-dynamic <expression>*)
 
 
clips/clip7fmt.txt · Last modified: 2010/01/04 20:47 (external edit)
topheader
© 1998-2019, SciOS Scientific Operating Systems GmbH

Legal | Credits | Profile | Contact | Customer Login