org.eclipse.uml2.uml.LoopNode Maven / Gradle / Ivy
The newest version!
/*
* Copyright (c) 2005, 2014 IBM Corporation, CEA, and others.
* All rights reserved. This program and the accompanying materials
* are made available under the terms of the Eclipse Public License v1.0
* which accompanies this distribution, and is available at
* http://www.eclipse.org/legal/epl-v10.html
*
* Contributors:
* IBM - initial API and implementation
* Kenn Hussey (CEA) - 327039, 397141, 418466
* Christian W. Damus (CEA) - 251963
*
*/
package org.eclipse.uml2.uml;
import java.util.Map;
import org.eclipse.emf.common.util.DiagnosticChain;
import org.eclipse.emf.common.util.EList;
import org.eclipse.emf.ecore.EClass;
/**
*
* A representation of the model object 'Loop Node'.
*
*
*
* A LoopNode is a StructuredActivityNode that represents an iterative loop with setup, test, and body sections.
* From package UML::Actions.
*
*
*
* The following features are supported:
*
* - {@link org.eclipse.uml2.uml.LoopNode#getBodyOutputs Body Output}
* - {@link org.eclipse.uml2.uml.LoopNode#getBodyParts Body Part}
* - {@link org.eclipse.uml2.uml.LoopNode#getDecider Decider}
* - {@link org.eclipse.uml2.uml.LoopNode#isTestedFirst Is Tested First}
* - {@link org.eclipse.uml2.uml.LoopNode#getLoopVariables Loop Variable}
* - {@link org.eclipse.uml2.uml.LoopNode#getLoopVariableInputs Loop Variable Input}
* - {@link org.eclipse.uml2.uml.LoopNode#getResults Result}
* - {@link org.eclipse.uml2.uml.LoopNode#getSetupParts Setup Part}
* - {@link org.eclipse.uml2.uml.LoopNode#getTests Test}
*
*
*
* @see org.eclipse.uml2.uml.UMLPackage#getLoopNode()
* @model
* @generated
*/
public interface LoopNode
extends StructuredActivityNode {
/**
* Returns the value of the 'Is Tested First' attribute.
* The default value is "false"
.
*
*
*
* If true, the test is performed before the first execution of the bodyPart. If false, the bodyPart is executed once before the test is performed.
* From package UML::Actions.
*
* @return the value of the 'Is Tested First' attribute.
* @see #setIsTestedFirst(boolean)
* @see org.eclipse.uml2.uml.UMLPackage#getLoopNode_IsTestedFirst()
* @model default="false" dataType="org.eclipse.uml2.types.Boolean" required="true" ordered="false"
* @generated
*/
boolean isTestedFirst();
/**
* Sets the value of the '{@link org.eclipse.uml2.uml.LoopNode#isTestedFirst Is Tested First}' attribute.
*
*
* @param value the new value of the 'Is Tested First' attribute.
* @see #isTestedFirst()
* @generated
*/
void setIsTestedFirst(boolean value);
/**
* Returns the value of the 'Body Part' reference list.
* The list contents are of type {@link org.eclipse.uml2.uml.ExecutableNode}.
*
*
*
* The set of ExecutableNodes that perform the repetitive computations of the loop. The bodyPart is executed as long as the test section produces a true value.
* From package UML::Actions.
*
* @return the value of the 'Body Part' reference list.
* @see org.eclipse.uml2.uml.UMLPackage#getLoopNode_BodyPart()
* @model ordered="false"
* @generated
*/
EList getBodyParts();
/**
* Retrieves the first {@link org.eclipse.uml2.uml.ExecutableNode} with the specified 'Name' from the 'Body Part' reference list.
*
*
* @param name The 'Name' of the {@link org.eclipse.uml2.uml.ExecutableNode} to retrieve, or null
.
* @return The first {@link org.eclipse.uml2.uml.ExecutableNode} with the specified 'Name', or null
.
* @see #getBodyParts()
* @generated
*/
ExecutableNode getBodyPart(String name);
/**
* Retrieves the first {@link org.eclipse.uml2.uml.ExecutableNode} with the specified 'Name' from the 'Body Part' reference list.
*
*
* @param name The 'Name' of the {@link org.eclipse.uml2.uml.ExecutableNode} to retrieve, or null
.
* @param ignoreCase Whether to ignore case in {@link java.lang.String} comparisons.
* @param eClass The Ecore class of the {@link org.eclipse.uml2.uml.ExecutableNode} to retrieve, or null
.
* @return The first {@link org.eclipse.uml2.uml.ExecutableNode} with the specified 'Name', or null
.
* @see #getBodyParts()
* @generated
*/
ExecutableNode getBodyPart(String name, boolean ignoreCase, EClass eClass);
/**
* Returns the value of the 'Setup Part' reference list.
* The list contents are of type {@link org.eclipse.uml2.uml.ExecutableNode}.
*
*
*
* The set of ExecutableNodes executed before the first iteration of the loop, in order to initialize values or perform other setup computations.
* From package UML::Actions.
*
* @return the value of the 'Setup Part' reference list.
* @see org.eclipse.uml2.uml.UMLPackage#getLoopNode_SetupPart()
* @model ordered="false"
* @generated
*/
EList getSetupParts();
/**
* Retrieves the first {@link org.eclipse.uml2.uml.ExecutableNode} with the specified 'Name' from the 'Setup Part' reference list.
*
*
* @param name The 'Name' of the {@link org.eclipse.uml2.uml.ExecutableNode} to retrieve, or null
.
* @return The first {@link org.eclipse.uml2.uml.ExecutableNode} with the specified 'Name', or null
.
* @see #getSetupParts()
* @generated
*/
ExecutableNode getSetupPart(String name);
/**
* Retrieves the first {@link org.eclipse.uml2.uml.ExecutableNode} with the specified 'Name' from the 'Setup Part' reference list.
*
*
* @param name The 'Name' of the {@link org.eclipse.uml2.uml.ExecutableNode} to retrieve, or null
.
* @param ignoreCase Whether to ignore case in {@link java.lang.String} comparisons.
* @param eClass The Ecore class of the {@link org.eclipse.uml2.uml.ExecutableNode} to retrieve, or null
.
* @return The first {@link org.eclipse.uml2.uml.ExecutableNode} with the specified 'Name', or null
.
* @see #getSetupParts()
* @generated
*/
ExecutableNode getSetupPart(String name, boolean ignoreCase, EClass eClass);
/**
* Returns the value of the 'Decider' reference.
*
*
*
* An OutputPin on an Action in the test section whose Boolean value determines whether to continue executing the loop bodyPart.
* From package UML::Actions.
*
* @return the value of the 'Decider' reference.
* @see #setDecider(OutputPin)
* @see org.eclipse.uml2.uml.UMLPackage#getLoopNode_Decider()
* @model required="true" ordered="false"
* @generated
*/
OutputPin getDecider();
/**
* Sets the value of the '{@link org.eclipse.uml2.uml.LoopNode#getDecider Decider}' reference.
*
*
* @param value the new value of the 'Decider' reference.
* @see #getDecider()
* @generated
*/
void setDecider(OutputPin value);
/**
* Returns the value of the 'Test' reference list.
* The list contents are of type {@link org.eclipse.uml2.uml.ExecutableNode}.
*
*
*
* The set of ExecutableNodes executed in order to provide the test result for the loop.
* From package UML::Actions.
*
* @return the value of the 'Test' reference list.
* @see org.eclipse.uml2.uml.UMLPackage#getLoopNode_Test()
* @model required="true" ordered="false"
* @generated
*/
EList getTests();
/**
* Retrieves the first {@link org.eclipse.uml2.uml.ExecutableNode} with the specified 'Name' from the 'Test' reference list.
*
*
* @param name The 'Name' of the {@link org.eclipse.uml2.uml.ExecutableNode} to retrieve, or null
.
* @return The first {@link org.eclipse.uml2.uml.ExecutableNode} with the specified 'Name', or null
.
* @see #getTests()
* @generated
*/
ExecutableNode getTest(String name);
/**
* Retrieves the first {@link org.eclipse.uml2.uml.ExecutableNode} with the specified 'Name' from the 'Test' reference list.
*
*
* @param name The 'Name' of the {@link org.eclipse.uml2.uml.ExecutableNode} to retrieve, or null
.
* @param ignoreCase Whether to ignore case in {@link java.lang.String} comparisons.
* @param eClass The Ecore class of the {@link org.eclipse.uml2.uml.ExecutableNode} to retrieve, or null
.
* @return The first {@link org.eclipse.uml2.uml.ExecutableNode} with the specified 'Name', or null
.
* @see #getTests()
* @generated
*/
ExecutableNode getTest(String name, boolean ignoreCase, EClass eClass);
/**
* Returns the value of the 'Result' containment reference list.
* The list contents are of type {@link org.eclipse.uml2.uml.OutputPin}.
*
* This feature redefines the following features:
*
* - '{@link org.eclipse.uml2.uml.StructuredActivityNode#getStructuredNodeOutputs() Structured Node Output}'
*
*
*
*
*
* A list of OutputPins that receive the loopVariable values after the last iteration of the loop and constitute the output of the LoopNode.
* From package UML::Actions.
*
* @return the value of the 'Result' containment reference list.
* @see org.eclipse.uml2.uml.UMLPackage#getLoopNode_Result()
* @model containment="true" resolveProxies="true"
* @generated
*/
EList getResults();
/**
* Creates a new {@link org.eclipse.uml2.uml.OutputPin}, with the specified 'Name', and 'Type', and appends it to the 'Result' containment reference list.
*
*
* @param name The 'Name' for the new {@link org.eclipse.uml2.uml.OutputPin}, or null
.
* @param type The 'Type' for the new {@link org.eclipse.uml2.uml.OutputPin}, or null
.
* @return The new {@link org.eclipse.uml2.uml.OutputPin}.
* @see #getResults()
* @generated
*/
OutputPin createResult(String name, Type type);
/**
* Retrieves the first {@link org.eclipse.uml2.uml.OutputPin} with the specified 'Name', and 'Type' from the 'Result' containment reference list.
*
*
* @param name The 'Name' of the {@link org.eclipse.uml2.uml.OutputPin} to retrieve, or null
.
* @param type The 'Type' of the {@link org.eclipse.uml2.uml.OutputPin} to retrieve, or null
.
* @return The first {@link org.eclipse.uml2.uml.OutputPin} with the specified 'Name', and 'Type', or null
.
* @see #getResults()
* @generated
*/
OutputPin getResult(String name, Type type);
/**
* Retrieves the first {@link org.eclipse.uml2.uml.OutputPin} with the specified 'Name', and 'Type' from the 'Result' containment reference list.
*
*
* @param name The 'Name' of the {@link org.eclipse.uml2.uml.OutputPin} to retrieve, or null
.
* @param type The 'Type' of the {@link org.eclipse.uml2.uml.OutputPin} to retrieve, or null
.
* @param ignoreCase Whether to ignore case in {@link java.lang.String} comparisons.
* @param createOnDemand Whether to create a {@link org.eclipse.uml2.uml.OutputPin} on demand if not found.
* @return The first {@link org.eclipse.uml2.uml.OutputPin} with the specified 'Name', and 'Type', or null
.
* @see #getResults()
* @generated
*/
OutputPin getResult(String name, Type type, boolean ignoreCase,
boolean createOnDemand);
/**
* Returns the value of the 'Loop Variable' containment reference list.
* The list contents are of type {@link org.eclipse.uml2.uml.OutputPin}.
*
* This feature subsets the following features:
*
* - '{@link org.eclipse.uml2.uml.Element#getOwnedElements() Owned Element}'
*
*
*
*
*
* A list of OutputPins that hold the values of the loop variables during an execution of the loop. When the test fails, the values are moved to the result OutputPins of the loop.
* From package UML::Actions.
*
* @return the value of the 'Loop Variable' containment reference list.
* @see org.eclipse.uml2.uml.UMLPackage#getLoopNode_LoopVariable()
* @model containment="true" resolveProxies="true"
* @generated
*/
EList getLoopVariables();
/**
* Creates a new {@link org.eclipse.uml2.uml.OutputPin}, with the specified 'Name', and 'Type', and appends it to the 'Loop Variable' containment reference list.
*
*
* @param name The 'Name' for the new {@link org.eclipse.uml2.uml.OutputPin}, or null
.
* @param type The 'Type' for the new {@link org.eclipse.uml2.uml.OutputPin}, or null
.
* @return The new {@link org.eclipse.uml2.uml.OutputPin}.
* @see #getLoopVariables()
* @generated
*/
OutputPin createLoopVariable(String name, Type type);
/**
* Retrieves the first {@link org.eclipse.uml2.uml.OutputPin} with the specified 'Name', and 'Type' from the 'Loop Variable' containment reference list.
*
*
* @param name The 'Name' of the {@link org.eclipse.uml2.uml.OutputPin} to retrieve, or null
.
* @param type The 'Type' of the {@link org.eclipse.uml2.uml.OutputPin} to retrieve, or null
.
* @return The first {@link org.eclipse.uml2.uml.OutputPin} with the specified 'Name', and 'Type', or null
.
* @see #getLoopVariables()
* @generated
*/
OutputPin getLoopVariable(String name, Type type);
/**
* Retrieves the first {@link org.eclipse.uml2.uml.OutputPin} with the specified 'Name', and 'Type' from the 'Loop Variable' reference list.
*
*
* @param name The 'Name' of the {@link org.eclipse.uml2.uml.OutputPin} to retrieve, or null
.
* @param type The 'Type' of the {@link org.eclipse.uml2.uml.OutputPin} to retrieve, or null
.
* @param ignoreCase Whether to ignore case in {@link java.lang.String} comparisons.
* @return The first {@link org.eclipse.uml2.uml.OutputPin} with the specified 'Name', and 'Type', or null
.
* @see #getLoopVariables()
* @generated NOT
*/
OutputPin getLoopVariable(String name, Type type, boolean ignoreCase);
/**
* Retrieves the first {@link org.eclipse.uml2.uml.OutputPin} with the specified 'Name', and 'Type' from the 'Loop Variable' containment reference list.
*
*
* @param name The 'Name' of the {@link org.eclipse.uml2.uml.OutputPin} to retrieve, or null
.
* @param type The 'Type' of the {@link org.eclipse.uml2.uml.OutputPin} to retrieve, or null
.
* @param ignoreCase Whether to ignore case in {@link java.lang.String} comparisons.
* @param createOnDemand Whether to create a {@link org.eclipse.uml2.uml.OutputPin} on demand if not found.
* @return The first {@link org.eclipse.uml2.uml.OutputPin} with the specified 'Name', and 'Type', or null
.
* @see #getLoopVariables()
* @generated
*/
OutputPin getLoopVariable(String name, Type type, boolean ignoreCase,
boolean createOnDemand);
/**
* Returns the value of the 'Body Output' reference list.
* The list contents are of type {@link org.eclipse.uml2.uml.OutputPin}.
*
*
*
* The OutputPins on Actions within the bodyPart, the values of which are moved to the loopVariable OutputPins after the completion of each execution of the bodyPart, before the next iteration of the loop begins or before the loop exits.
* From package UML::Actions.
*
* @return the value of the 'Body Output' reference list.
* @see org.eclipse.uml2.uml.UMLPackage#getLoopNode_BodyOutput()
* @model
* @generated
*/
EList getBodyOutputs();
/**
* Retrieves the first {@link org.eclipse.uml2.uml.OutputPin} with the specified 'Name', and 'Type' from the 'Body Output' reference list.
*
*
* @param name The 'Name' of the {@link org.eclipse.uml2.uml.OutputPin} to retrieve, or null
.
* @param type The 'Type' of the {@link org.eclipse.uml2.uml.OutputPin} to retrieve, or null
.
* @return The first {@link org.eclipse.uml2.uml.OutputPin} with the specified 'Name', and 'Type', or null
.
* @see #getBodyOutputs()
* @generated
*/
OutputPin getBodyOutput(String name, Type type);
/**
* Retrieves the first {@link org.eclipse.uml2.uml.OutputPin} with the specified 'Name', and 'Type' from the 'Body Output' reference list.
*
*
* @param name The 'Name' of the {@link org.eclipse.uml2.uml.OutputPin} to retrieve, or null
.
* @param type The 'Type' of the {@link org.eclipse.uml2.uml.OutputPin} to retrieve, or null
.
* @param ignoreCase Whether to ignore case in {@link java.lang.String} comparisons.
* @return The first {@link org.eclipse.uml2.uml.OutputPin} with the specified 'Name', and 'Type', or null
.
* @see #getBodyOutputs()
* @generated
*/
OutputPin getBodyOutput(String name, Type type, boolean ignoreCase);
/**
* Returns the value of the 'Loop Variable Input' containment reference list.
* The list contents are of type {@link org.eclipse.uml2.uml.InputPin}.
*
* This feature redefines the following features:
*
* - '{@link org.eclipse.uml2.uml.StructuredActivityNode#getStructuredNodeInputs() Structured Node Input}'
*
*
*
*
*
* A list of InputPins whose values are moved into the loopVariable Pins before the first iteration of the loop.
* From package UML::Actions.
*
* @return the value of the 'Loop Variable Input' containment reference list.
* @see org.eclipse.uml2.uml.UMLPackage#getLoopNode_LoopVariableInput()
* @model containment="true" resolveProxies="true"
* @generated
*/
EList getLoopVariableInputs();
/**
* Creates a new {@link org.eclipse.uml2.uml.InputPin}, with the specified 'Name', and 'Type', and appends it to the 'Loop Variable Input' containment reference list.
*
*
* @param name The 'Name' for the new {@link org.eclipse.uml2.uml.InputPin}, or null
.
* @param type The 'Type' for the new {@link org.eclipse.uml2.uml.InputPin}, or null
.
* @param eClass The Ecore class of the {@link org.eclipse.uml2.uml.InputPin} to create.
* @return The new {@link org.eclipse.uml2.uml.InputPin}.
* @see #getLoopVariableInputs()
* @generated
*/
InputPin createLoopVariableInput(String name, Type type, EClass eClass);
/**
* Creates a new {@link org.eclipse.uml2.uml.InputPin}, with the specified 'Name', and 'Type', and appends it to the 'Loop Variable Input' containment reference list.
*
*
* @param name The 'Name' for the new {@link org.eclipse.uml2.uml.InputPin}, or null
.
* @param type The 'Type' for the new {@link org.eclipse.uml2.uml.InputPin}, or null
.
* @return The new {@link org.eclipse.uml2.uml.InputPin}.
* @see #getLoopVariableInputs()
* @generated
*/
InputPin createLoopVariableInput(String name, Type type);
/**
* Retrieves the first {@link org.eclipse.uml2.uml.InputPin} with the specified 'Name', and 'Type' from the 'Loop Variable Input' containment reference list.
*
*
* @param name The 'Name' of the {@link org.eclipse.uml2.uml.InputPin} to retrieve, or null
.
* @param type The 'Type' of the {@link org.eclipse.uml2.uml.InputPin} to retrieve, or null
.
* @return The first {@link org.eclipse.uml2.uml.InputPin} with the specified 'Name', and 'Type', or null
.
* @see #getLoopVariableInputs()
* @generated
*/
InputPin getLoopVariableInput(String name, Type type);
/**
* Retrieves the first {@link org.eclipse.uml2.uml.InputPin} with the specified 'Name', and 'Type' from the 'Loop Variable Input' containment reference list.
*
*
* @param name The 'Name' of the {@link org.eclipse.uml2.uml.InputPin} to retrieve, or null
.
* @param type The 'Type' of the {@link org.eclipse.uml2.uml.InputPin} to retrieve, or null
.
* @param ignoreCase Whether to ignore case in {@link java.lang.String} comparisons.
* @param eClass The Ecore class of the {@link org.eclipse.uml2.uml.InputPin} to retrieve, or null
.
* @param createOnDemand Whether to create a {@link org.eclipse.uml2.uml.InputPin} on demand if not found.
* @return The first {@link org.eclipse.uml2.uml.InputPin} with the specified 'Name', and 'Type', or null
.
* @see #getLoopVariableInputs()
* @generated
*/
InputPin getLoopVariableInput(String name, Type type, boolean ignoreCase,
EClass eClass, boolean createOnDemand);
/**
*
*
*
* The loopVariableInputs must not have outgoing edges.
* loopVariableInput.outgoing->isEmpty()
* @param diagnostics The chain of diagnostics to which problems are to be appended.
* @param context The cache of context-specific information.
*
* @model
* @generated
*/
boolean validateInputEdges(DiagnosticChain diagnostics,
Map