Class ModelSwitch
java.lang.Object
org.eclipse.epf.diagram.model.util.ModelSwitch
public class ModelSwitch
extends java.lang.Object
The Switch for the model's inheritance hierarchy.
It supports the call
doSwitch(object)
to invoke the caseXXX method for each class of the model,
starting with the actual class of the object
and proceeding up the inheritance hierarchy
until a non-null result is returned,
which is the result of the switch.
- See Also:
ModelPackage
-
Constructor Summary
Constructors Constructor Description ModelSwitch()Creates an instance of the switch. -
Method Summary
Modifier and Type Method Description java.lang.ObjectcaseActivityDetailDiagram(ActivityDetailDiagram object)Returns the result of interpreting the object as an instance of 'Activity Detail Diagram'.java.lang.ObjectcaseActivityDiagram(ActivityDiagram object)Returns the result of interpreting the object as an instance of 'Activity Diagram'.java.lang.ObjectcaseDiagram(Diagram object)Returns the result of interpreting the object as an instance of 'Diagram'.java.lang.ObjectcaseLink(Link object)Returns the result of interpreting the object as an instance of 'Link'.java.lang.ObjectcaseLinkedObject(LinkedObject object)Returns the result of interpreting the object as an instance of 'Linked Object'.java.lang.ObjectcaseNamedNode(NamedNode object)Returns the result of interpreting the object as an instance of 'Named Node'.java.lang.ObjectcaseNode(Node object)Returns the result of interpreting the object as an instance of 'Node'.java.lang.ObjectcaseNodeContainer(NodeContainer object)Returns the result of interpreting the object as an instance of 'Node Container'.java.lang.ObjectcaseRoleNode(RoleNode object)Returns the result of interpreting the object as an instance of 'Role Node'.java.lang.ObjectcaseRoleTaskComposite(RoleTaskComposite object)Returns the result of interpreting the object as an instance of 'Role Task Composite'.java.lang.ObjectcaseTaskNode(TaskNode object)Returns the result of interpreting the object as an instance of 'Task Node'.java.lang.ObjectcaseTypedNode(TypedNode object)Returns the result of interpreting the object as an instance of 'Typed Node'.java.lang.ObjectcaseWorkBreakdownElementNode(WorkBreakdownElementNode object)Returns the result of interpreting the object as an instance of 'Work Breakdown Element Node'.java.lang.ObjectcaseWorkProductComposite(WorkProductComposite object)Returns the result of interpreting the object as an instance of 'Work Product Composite'.java.lang.ObjectcaseWorkProductDependencyDiagram(WorkProductDependencyDiagram object)Returns the result of interpreting the object as an instance of 'Work Product Dependency Diagram'.java.lang.ObjectcaseWorkProductDescriptorNode(WorkProductDescriptorNode object)Returns the result of interpreting the object as an instance of 'Work Product Descriptor Node'.java.lang.ObjectcaseWorkProductNode(WorkProductNode object)Returns the result of interpreting the object as an instance of 'Work Product Node'.java.lang.ObjectdefaultCase(org.eclipse.emf.ecore.EObject object)Returns the result of interpreting the object as an instance of 'EObject'.java.lang.ObjectdoSwitch(org.eclipse.emf.ecore.EObject theEObject)CallscaseXXXfor each class of the model until one returns a non null result; it yields that result.Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Constructor Details
-
ModelSwitch
public ModelSwitch()Creates an instance of the switch.
-
-
Method Details
-
doSwitch
public java.lang.Object doSwitch(org.eclipse.emf.ecore.EObject theEObject)CallscaseXXXfor each class of the model until one returns a non null result; it yields that result.- Returns:
- the first non-null result returned by a
caseXXXcall.
-
caseDiagram
Returns the result of interpreting the object as an instance of 'Diagram'. This implementation returns null; returning a non-null result will terminate the switch.- Parameters:
object- the target of the switch.- Returns:
- the result of interpreting the object as an instance of 'Diagram'.
- See Also:
doSwitch(EObject)
-
caseLink
Returns the result of interpreting the object as an instance of 'Link'. This implementation returns null; returning a non-null result will terminate the switch.- Parameters:
object- the target of the switch.- Returns:
- the result of interpreting the object as an instance of 'Link'.
- See Also:
doSwitch(EObject)
-
caseLinkedObject
Returns the result of interpreting the object as an instance of 'Linked Object'. This implementation returns null; returning a non-null result will terminate the switch.- Parameters:
object- the target of the switch.- Returns:
- the result of interpreting the object as an instance of 'Linked Object'.
- See Also:
doSwitch(EObject)
-
caseNamedNode
Returns the result of interpreting the object as an instance of 'Named Node'. This implementation returns null; returning a non-null result will terminate the switch.- Parameters:
object- the target of the switch.- Returns:
- the result of interpreting the object as an instance of 'Named Node'.
- See Also:
doSwitch(EObject)
-
caseNode
Returns the result of interpreting the object as an instance of 'Node'. This implementation returns null; returning a non-null result will terminate the switch.- Parameters:
object- the target of the switch.- Returns:
- the result of interpreting the object as an instance of 'Node'.
- See Also:
doSwitch(EObject)
-
caseActivityDiagram
Returns the result of interpreting the object as an instance of 'Activity Diagram'. This implementation returns null; returning a non-null result will terminate the switch.- Parameters:
object- the target of the switch.- Returns:
- the result of interpreting the object as an instance of 'Activity Diagram'.
- See Also:
doSwitch(EObject)
-
caseTypedNode
Returns the result of interpreting the object as an instance of 'Typed Node'. This implementation returns null; returning a non-null result will terminate the switch.- Parameters:
object- the target of the switch.- Returns:
- the result of interpreting the object as an instance of 'Typed Node'.
- See Also:
doSwitch(EObject)
-
caseWorkProductDependencyDiagram
Returns the result of interpreting the object as an instance of 'Work Product Dependency Diagram'. This implementation returns null; returning a non-null result will terminate the switch.- Parameters:
object- the target of the switch.- Returns:
- the result of interpreting the object as an instance of 'Work Product Dependency Diagram'.
- See Also:
doSwitch(EObject)
-
caseWorkProductNode
Returns the result of interpreting the object as an instance of 'Work Product Node'. This implementation returns null; returning a non-null result will terminate the switch.- Parameters:
object- the target of the switch.- Returns:
- the result of interpreting the object as an instance of 'Work Product Node'.
- See Also:
doSwitch(EObject)
-
caseActivityDetailDiagram
Returns the result of interpreting the object as an instance of 'Activity Detail Diagram'. This implementation returns null; returning a non-null result will terminate the switch.- Parameters:
object- the target of the switch.- Returns:
- the result of interpreting the object as an instance of 'Activity Detail Diagram'.
- See Also:
doSwitch(EObject)
-
caseNodeContainer
Returns the result of interpreting the object as an instance of 'Node Container'. This implementation returns null; returning a non-null result will terminate the switch.- Parameters:
object- the target of the switch.- Returns:
- the result of interpreting the object as an instance of 'Node Container'.
- See Also:
doSwitch(EObject)
-
caseRoleNode
Returns the result of interpreting the object as an instance of 'Role Node'. This implementation returns null; returning a non-null result will terminate the switch.- Parameters:
object- the target of the switch.- Returns:
- the result of interpreting the object as an instance of 'Role Node'.
- See Also:
doSwitch(EObject)
-
caseRoleTaskComposite
Returns the result of interpreting the object as an instance of 'Role Task Composite'. This implementation returns null; returning a non-null result will terminate the switch.- Parameters:
object- the target of the switch.- Returns:
- the result of interpreting the object as an instance of 'Role Task Composite'.
- See Also:
doSwitch(EObject)
-
caseTaskNode
Returns the result of interpreting the object as an instance of 'Task Node'. This implementation returns null; returning a non-null result will terminate the switch.- Parameters:
object- the target of the switch.- Returns:
- the result of interpreting the object as an instance of 'Task Node'.
- See Also:
doSwitch(EObject)
-
caseWorkProductDescriptorNode
Returns the result of interpreting the object as an instance of 'Work Product Descriptor Node'. This implementation returns null; returning a non-null result will terminate the switch.- Parameters:
object- the target of the switch.- Returns:
- the result of interpreting the object as an instance of 'Work Product Descriptor Node'.
- See Also:
doSwitch(EObject)
-
caseWorkBreakdownElementNode
Returns the result of interpreting the object as an instance of 'Work Breakdown Element Node'. This implementation returns null; returning a non-null result will terminate the switch.- Parameters:
object- the target of the switch.- Returns:
- the result of interpreting the object as an instance of 'Work Breakdown Element Node'.
- See Also:
doSwitch(EObject)
-
caseWorkProductComposite
Returns the result of interpreting the object as an instance of 'Work Product Composite'. This implementation returns null; returning a non-null result will terminate the switch.- Parameters:
object- the target of the switch.- Returns:
- the result of interpreting the object as an instance of 'Work Product Composite'.
- See Also:
doSwitch(EObject)
-
defaultCase
public java.lang.Object defaultCase(org.eclipse.emf.ecore.EObject object)Returns the result of interpreting the object as an instance of 'EObject'. This implementation returns null; returning a non-null result will terminate the switch, but this is the last case anyway.- Parameters:
object- the target of the switch.- Returns:
- the result of interpreting the object as an instance of 'EObject'.
- See Also:
doSwitch(org.eclipse.emf.ecore.EObject)
-