org.eclipse.uml2.uml
Interface Clause

All Superinterfaces:
Element, EModelElement, EObject, Notifier

public interface Clause
extends Element

A representation of the model object 'Clause'. A clause is an element that represents a single branch of a conditional construct, including a test and a body section. The body section is executed only if (but not necessarily if) the test section evaluates true.

The following features are supported:

See Also:
UMLPackage.getClause()

Method Summary
 EList getBodies()
          Returns the value of the 'Body' reference list.
 ExecutableNode getBody(String name)
          Retrieves the first ExecutableNode with the specified 'Name' from the 'Body' reference list
 ExecutableNode getBody(String name, boolean ignoreCase, EClass eClass)
          Retrieves the first ExecutableNode with the specified 'Name' from the 'Body' reference list
 OutputPin getBodyOutput(String name, Type type)
          Retrieves the first OutputPin with the specified 'Name', and 'Type' from the 'Body Output' reference list
 OutputPin getBodyOutput(String name, Type type, boolean ignoreCase)
          Retrieves the first OutputPin with the specified 'Name', and 'Type' from the 'Body Output' reference list
 EList getBodyOutputs()
          Returns the value of the 'Body Output' reference list.
 OutputPin getDecider()
          Returns the value of the 'Decider' reference
 EList getPredecessorClauses()
          Returns the value of the 'Predecessor Clause' reference list.
 EList getSuccessorClauses()
          Returns the value of the 'Successor Clause' reference list.
 ExecutableNode getTest(String name)
          Retrieves the first ExecutableNode with the specified 'Name' from the 'Test' reference list
 ExecutableNode getTest(String name, boolean ignoreCase, EClass eClass)
          Retrieves the first ExecutableNode with the specified 'Name' from the 'Test' reference list
 EList getTests()
          Returns the value of the 'Test' reference list.
 void setDecider(OutputPin value)
          Sets the value of the 'Decider' reference
 boolean validateBodyOutputPins(DiagnosticChain diagnostics, Map context)
           The bodyOutput pins are output pins on actions in the body of the clause.
 boolean validateDeciderOutput(DiagnosticChain diagnostics, Map context)
           The decider output pin must be for the test body or a node contained by the test body as a structured node.
 
Methods inherited from interface org.eclipse.uml2.uml.Element
addKeyword, allOwnedElements, applyStereotype, createEAnnotation, createOwnedComment, destroy, getApplicableStereotype, getApplicableStereotypes, getAppliedStereotype, getAppliedStereotypes, getAppliedSubstereotype, getAppliedSubstereotypes, getKeywords, getModel, getNearestPackage, getOwnedComments, getOwnedElements, getOwner, getRelationships, getRelationships, getRequiredStereotype, getRequiredStereotypes, getSourceDirectedRelationships, getSourceDirectedRelationships, getStereotypeApplication, getStereotypeApplications, getTargetDirectedRelationships, getTargetDirectedRelationships, getValue, hasKeyword, hasValue, isStereotypeApplicable, isStereotypeApplied, isStereotypeRequired, mustBeOwned, removeKeyword, setValue, unapplyStereotype, validateHasOwner, validateNotOwnSelf
 
Methods inherited from interface org.eclipse.emf.ecore.EModelElement
getEAnnotation, getEAnnotations
 
Methods inherited from interface org.eclipse.emf.ecore.EObject
eAllContents, eClass, eContainer, eContainingFeature, eContainmentFeature, eContents, eCrossReferences, eGet, eGet, eIsProxy, eIsSet, eResource, eSet, eUnset
 
Methods inherited from interface org.eclipse.emf.common.notify.Notifier
eAdapters, eDeliver, eNotify, eSetDeliver
 

Method Detail

getTests

public EList getTests()
Returns the value of the 'Test' reference list. The list contents are of type ExecutableNode. A nested activity fragment with a designated output pin that specifies the result of the test.

Returns:
the value of the 'Test' reference list.
See Also:
UMLPackage.getClause_Test()

getTest

public ExecutableNode getTest(String name)
Retrieves the first ExecutableNode with the specified 'Name' from the 'Test' reference list.

Parameters:
name - The 'Name' of the ExecutableNode to retrieve, or null.
Returns:
The first ExecutableNode with the specified 'Name', or null.
See Also:
Clause.getTests()

getTest

public ExecutableNode getTest(String name,
                              boolean ignoreCase,
                              EClass eClass)
Retrieves the first ExecutableNode with the specified 'Name' from the 'Test' reference list.

Parameters:
name - The 'Name' of the ExecutableNode to retrieve, or null.
ignoreCase - Whether to ignore case in String comparisons.
eClass - The Ecore class of the ExecutableNode to retrieve, or null.
Returns:
The first ExecutableNode with the specified 'Name', or null.
See Also:
Clause.getTests()

getBodies

public EList getBodies()
Returns the value of the 'Body' reference list. The list contents are of type ExecutableNode. A nested activity fragment that is executed if the test evaluates to true and the clause is chosen over any concurrent clauses that also evaluate to true.

Returns:
the value of the 'Body' reference list.
See Also:
UMLPackage.getClause_Body()

getBody

public ExecutableNode getBody(String name)
Retrieves the first ExecutableNode with the specified 'Name' from the 'Body' reference list.

Parameters:
name - The 'Name' of the ExecutableNode to retrieve, or null.
Returns:
The first ExecutableNode with the specified 'Name', or null.
See Also:
Clause.getBodies()

getBody

public ExecutableNode getBody(String name,
                              boolean ignoreCase,
                              EClass eClass)
Retrieves the first ExecutableNode with the specified 'Name' from the 'Body' reference list.

Parameters:
name - The 'Name' of the ExecutableNode to retrieve, or null.
ignoreCase - Whether to ignore case in String comparisons.
eClass - The Ecore class of the ExecutableNode to retrieve, or null.
Returns:
The first ExecutableNode with the specified 'Name', or null.
See Also:
Clause.getBodies()

getPredecessorClauses

public EList getPredecessorClauses()
Returns the value of the 'Predecessor Clause' reference list. The list contents are of type Clause. It is bidirectional and its opposite is 'Successor Clause'. A set of clauses whose tests must all evaluate false before the current clause can be tested.

Returns:
the value of the 'Predecessor Clause' reference list.
See Also:
UMLPackage.getClause_PredecessorClause(), Clause.getSuccessorClauses()

getSuccessorClauses

public EList getSuccessorClauses()
Returns the value of the 'Successor Clause' reference list. The list contents are of type Clause. It is bidirectional and its opposite is 'Predecessor Clause'. A set of clauses which may not be tested unless the current clause tests false.

Returns:
the value of the 'Successor Clause' reference list.
See Also:
UMLPackage.getClause_SuccessorClause(), Clause.getPredecessorClauses()

getDecider

public OutputPin getDecider()
Returns the value of the 'Decider' reference. An output pin within the test fragment the value of which is examined after execution of the test to determine whether the body should be executed.

Returns:
the value of the 'Decider' reference.
See Also:
Clause.setDecider(OutputPin), UMLPackage.getClause_Decider()

setDecider

public void setDecider(OutputPin value)
Sets the value of the 'Decider' reference.

Parameters:
value - the new value of the 'Decider' reference.
See Also:
Clause.getDecider()

getBodyOutputs

public EList getBodyOutputs()
Returns the value of the 'Body Output' reference list. The list contents are of type OutputPin. A list of output pins within the body fragment whose values are moved to the result pins of the containing conditional node after execution of the clause body.

Returns:
the value of the 'Body Output' reference list.
See Also:
UMLPackage.getClause_BodyOutput()

getBodyOutput

public OutputPin getBodyOutput(String name,
                               Type type)
Retrieves the first OutputPin with the specified 'Name', and 'Type' from the 'Body Output' reference list.

Parameters:
name - The 'Name' of the OutputPin to retrieve, or null.
type - The 'Type' of the OutputPin to retrieve, or null.
Returns:
The first OutputPin with the specified 'Name', and 'Type', or null.
See Also:
Clause.getBodyOutputs()

getBodyOutput

public OutputPin getBodyOutput(String name,
                               Type type,
                               boolean ignoreCase)
Retrieves the first OutputPin with the specified 'Name', and 'Type' from the 'Body Output' reference list.

Parameters:
name - The 'Name' of the OutputPin to retrieve, or null.
type - The 'Type' of the OutputPin to retrieve, or null.
ignoreCase - Whether to ignore case in String comparisons.
Returns:
The first OutputPin with the specified 'Name', and 'Type', or null.
See Also:
Clause.getBodyOutputs()

validateDeciderOutput

public boolean validateDeciderOutput(DiagnosticChain diagnostics,
                                     Map context)
The decider output pin must be for the test body or a node contained by the test body as a structured node. true


validateBodyOutputPins

public boolean validateBodyOutputPins(DiagnosticChain diagnostics,
                                      Map context)
The bodyOutput pins are output pins on actions in the body of the clause. true


Copyright 2003, 2006 IBM Corporation and others.
All Rights Reserved.