get-role-types [Method]


The get-role-types method finds the type of the fillers of a given role on a given concept or instance. The type is a list of concepts.


get-role-types conceptOrInstance relation


The conceptOrInstance argument is a Loom concept or instance.

The relation argument is the relation whose fillers' type is to be found.


The get-role-types method returns the type (value-restriction) that applies to conceptOrInstance for relation.


(defconcept B 
    :is (:and (:all r A) (:exactly 3 r) (:filled-by r Joe Fred))) 
(defconcept C 
    :is-primitive B 
    :implies (:and (:some s A) (:at-most 2 s)) 
    :defaults (:filled-by s Sue)) 
(tellm (C Mary)) 
(get-role-types (fc C) (fr r)) ==> (|C|A) 
(get-role-types (fc C) (fr s)) ==> NIL  
(get-role-types (fi Mary) (fr r)) ==> (|C|A) 
(get-role-types (fi Mary) (fr s)) ==> (|C|THING)

See Also

Last modified: Jun 1 1995