FUNCTION acyclic_symbol_representation_relationship
(relation : symbol_representation_relationship, children : SET [0:?] OF symbol_representation) : BOOLEAN;
LOCAL x : SET OF symbol_representation_relationship; local_children : SET OF symbol_representation; END_LOCAL; REPEAT i:=1 TO HIINDEX(children); IF relation\representation_relationship.rep_1 :=: children[i] THEN RETURN(FALSE); END_IF; END_REPEAT; x := bag_to_set (USEDIN ( relation\representation_relationship.rep_1, 'REPRESENTATION_SCHEMA.'+ 'REPRESENTATION_RELATIONSHIP.'+ 'REP_2')); local_children := children + relation\representation_relationship.rep_1; IF SIZEOF (x) > 0 THEN REPEAT i:=1 TO HIINDEX (x); IF NOT acyclic_symbol_representation_relationship(x[i] , local_children) THEN RETURN (FALSE); END_IF; END_REPEAT; END_IF; RETURN (TRUE); END_FUNCTION; -- acyclic_symbol_representation_relationship
|