Items
and their associated children. A relation has a name and a list of items, and is added to an Utterance
via an UtteranceProcessor
.
Four methods for creating commonly used predicates over binary relations are provided: {@link #function(Expression,Expression)}, {@link #partialFunction(Expression,Expression)}, {@link #acyclic()}, and {@link #totalOrder(Relation,Relation,Relation)}. Using these methods to generate desired predicates will result in faster constraint solving than creating the same predicates via other API calls.
@specfield name: String @specfield arity: int @invariant no children @author Emina TorlakRelations can also be linked to other Relations. To create such a link, use the link() method of this class. To remove such a link, use the unlink() method. A group of linked relations behaves exactly as if it were one relation directly linked to all the ports linked to by each relation. In particular, the connectedPortList() method of the Port class returns the same list whether a single relation is used or a relation group. The order in which the ports are listed is the order in which links were made between the port and relations in the relation group. It is not relevant which relation in a relation group the port links to.
Derived classes may wish to disallow links under certain circumstances, for example if the proposed port is not an instance of an appropriate subclass of Port, or if the relation cannot support any more links. Such derived classes should override the protected method _checkPort() or _checkRelation() to throw an exception. @author Edward A. Lee, Neil Smyth @version $Id: Relation.java,v 1.141 2005/11/22 23:33:29 eal Exp $ @since Ptolemy II 0.2 @Pt.ProposedRating Green (eal) @Pt.AcceptedRating Green (acataldo) @see Port @see Entity
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|