next up previous

12.16.1.18 Getting the List of Facets for a Slot

This function returns a multifield listing the facet values for the specified slot (the slot can be inherited or explicitly defined for the class). A multifield of length zero is returned if an error occurs. Following is a table indicating what each field represents and its possible values:


Field  Meaning              Values           Explanation

1      Field Type           SGL/MLT          Singlefield or multifield

2      Default Value        STC/DYN/NIL      Static, dynamic or none

3      Inheritance          INH/NIL          Inheritable by other classes or not

4      Access               RW/R/INT         Readwrite, readonly or
                                             initializeonly

5      Storage              LCL/SHR          Local or shared

6      PatternMatch         RCT/NIL          Reactive or nonreactive

7      Source               EXC/CMP          Exclusive or composite

8      Visibility           PUB/PRV          Public or private

9      Automatic Accessors  R/W/RW/NIL       Read, write, read-write or none

10     Override-Message     <message-name>   Name of message sent for
                                             slotoverrides



See section 9.3.3 for more details on slot facets.

Syntax

(slot-facets <class-name> <slot-name>)

Example

CLIPS> (clear)
CLIPS> (defclass A (is-a USER) (slot x (access read-only)))
CLIPS> (defclass B (is-a A) (multislot y))
CLIPS> (slot-facets B x)
(SGL STC INH R LCL RCT EXC PRV NIL NIL)
CLIPS> (slot-facets B y)
(MLT STC INH RW LCL RCT EXC PRV NIL put-y)
CLIPS>


next up previous