org.eclipse.gmt.umlx.imperativeocl.util
Class ImperativeoclSwitch<T>

java.lang.Object
  extended by org.eclipse.gmt.umlx.imperativeocl.util.ImperativeoclSwitch<T>

public class ImperativeoclSwitch<T>
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:
ImperativeoclPackage

Constructor Summary
ImperativeoclSwitch()
          Creates an instance of the switch.
 
Method Summary
 T caseAltExp(AltExp object)
          Returns the result of interpretting the object as an instance of 'Alt Exp'.
 T caseAnonymousTupleLiteralExp(AnonymousTupleLiteralExp object)
          Returns the result of interpretting the object as an instance of 'Anonymous Tuple Literal Exp'.
 T caseAnonymousTupleLiteralPart(AnonymousTupleLiteralPart object)
          Returns the result of interpretting the object as an instance of 'Anonymous Tuple Literal Part'.
 T caseAnonymousTupleType(AnonymousTupleType object)
          Returns the result of interpretting the object as an instance of 'Anonymous Tuple Type'.
 T caseAssertExp(AssertExp object)
          Returns the result of interpretting the object as an instance of 'Assert Exp'.
 T caseAssignExp(AssignExp object)
          Returns the result of interpretting the object as an instance of 'Assign Exp'.
 T caseBlockExp(BlockExp object)
          Returns the result of interpretting the object as an instance of 'Block Exp'.
 T caseBreakExp(BreakExp object)
          Returns the result of interpretting the object as an instance of 'Break Exp'.
 T caseCallExp(CallExp object)
          Returns the result of interpretting the object as an instance of 'Call Exp'.
 T caseClass(Class object)
          Returns the result of interpretting the object as an instance of 'Class'.
 T caseCollectionType(CollectionType object)
          Returns the result of interpretting the object as an instance of 'Collection Type'.
 T caseComputeExp(ComputeExp object)
          Returns the result of interpretting the object as an instance of 'Compute Exp'.
 T caseContinueExp(ContinueExp object)
          Returns the result of interpretting the object as an instance of 'Continue Exp'.
 T caseDataType(DataType object)
          Returns the result of interpretting the object as an instance of 'Data Type'.
 T caseDictionaryType(DictionaryType object)
          Returns the result of interpretting the object as an instance of 'Dictionary Type'.
 T caseDictLiteralExp(DictLiteralExp object)
          Returns the result of interpretting the object as an instance of 'Dict Literal Exp'.
 T caseDictLiteralPart(DictLiteralPart object)
          Returns the result of interpretting the object as an instance of 'Dict Literal Part'.
 T caseElement(Element object)
          Returns the result of interpretting the object as an instance of 'Element'.
 T caseFeaturePropertyCall(FeaturePropertyCall object)
          Returns the result of interpretting the object as an instance of 'Feature Property Call'.
 T caseForExp(ForExp object)
          Returns the result of interpretting the object as an instance of 'For Exp'.
 T caseImperativeExpression(ImperativeExpression object)
          Returns the result of interpretting the object as an instance of 'Imperative Expression'.
 T caseImperativeIterateExp(ImperativeIterateExp object)
          Returns the result of interpretting the object as an instance of 'Imperative Iterate Exp'.
 T caseImperativeLoopExp(ImperativeLoopExp object)
          Returns the result of interpretting the object as an instance of 'Imperative Loop Exp'.
 T caseInstantiationExp(InstantiationExp object)
          Returns the result of interpretting the object as an instance of 'Instantiation Exp'.
 T caseListType(ListType object)
          Returns the result of interpretting the object as an instance of 'List Type'.
 T caseLiteralExp(LiteralExp object)
          Returns the result of interpretting the object as an instance of 'Literal Exp'.
 T caseLogExp(LogExp object)
          Returns the result of interpretting the object as an instance of 'Log Exp'.
 T caseLoopExp(LoopExp object)
          Returns the result of interpretting the object as an instance of 'Loop Exp'.
 T caseNamedElement(NamedElement object)
          Returns the result of interpretting the object as an instance of 'Named Element'.
 T caseObject(Object object)
          Returns the result of interpretting the object as an instance of 'Object'.
 T caseOclExpression(OclExpression object)
          Returns the result of interpretting the object as an instance of 'Ocl Expression'.
 T caseOperationCallExp(OperationCallExp object)
          Returns the result of interpretting the object as an instance of 'Operation Call Exp'.
 T caseRaiseExp(RaiseExp object)
          Returns the result of interpretting the object as an instance of 'Raise Exp'.
 T caseReturnExp(ReturnExp object)
          Returns the result of interpretting the object as an instance of 'Return Exp'.
 T caseSwitchExp(SwitchExp object)
          Returns the result of interpretting the object as an instance of 'Switch Exp'.
 T caseTemplateParameterType(TemplateParameterType object)
          Returns the result of interpretting the object as an instance of 'Template Parameter Type'.
 T caseTryExp(TryExp object)
          Returns the result of interpretting the object as an instance of 'Try Exp'.
 T caseTupleExp(TupleExp object)
          Returns the result of interpretting the object as an instance of 'Tuple Exp'.
 T caseType(Type object)
          Returns the result of interpretting the object as an instance of 'Type'.
 T caseTypedef(Typedef object)
          Returns the result of interpretting the object as an instance of 'Typedef'.
 T caseTypedElement(TypedElement object)
          Returns the result of interpretting the object as an instance of 'Typed Element'.
 T caseUnlinkExp(UnlinkExp object)
          Returns the result of interpretting the object as an instance of 'Unlink Exp'.
 T caseUnpackExp(UnpackExp object)
          Returns the result of interpretting the object as an instance of 'Unpack Exp'.
 T caseVariableInitExp(VariableInitExp object)
          Returns the result of interpretting the object as an instance of 'Variable Init Exp'.
 T caseWhileExp(WhileExp object)
          Returns the result of interpretting the object as an instance of 'While Exp'.
 T defaultCase(org.eclipse.emf.ecore.EObject object)
          Returns the result of interpretting the object as an instance of 'EObject'.
 T doSwitch(org.eclipse.emf.ecore.EObject theEObject)
          Calls caseXXX for 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 Detail

ImperativeoclSwitch

public ImperativeoclSwitch()
Creates an instance of the switch.

Method Detail

doSwitch

public T doSwitch(org.eclipse.emf.ecore.EObject theEObject)
Calls caseXXX for 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 caseXXX call.

caseAssignExp

public T caseAssignExp(AssignExp object)
Returns the result of interpretting the object as an instance of 'Assign Exp'. This implementation returns null; returning a non-null result will terminate the switch.

Parameters:
object - the target of the switch.
Returns:
the result of interpretting the object as an instance of 'Assign Exp'.
See Also:
doSwitch(EObject)

caseBlockExp

public T caseBlockExp(BlockExp object)
Returns the result of interpretting the object as an instance of 'Block Exp'. This implementation returns null; returning a non-null result will terminate the switch.

Parameters:
object - the target of the switch.
Returns:
the result of interpretting the object as an instance of 'Block Exp'.
See Also:
doSwitch(EObject)

caseSwitchExp

public T caseSwitchExp(SwitchExp object)
Returns the result of interpretting the object as an instance of 'Switch Exp'. This implementation returns null; returning a non-null result will terminate the switch.

Parameters:
object - the target of the switch.
Returns:
the result of interpretting the object as an instance of 'Switch Exp'.
See Also:
doSwitch(EObject)

caseVariableInitExp

public T caseVariableInitExp(VariableInitExp object)
Returns the result of interpretting the object as an instance of 'Variable Init Exp'. This implementation returns null; returning a non-null result will terminate the switch.

Parameters:
object - the target of the switch.
Returns:
the result of interpretting the object as an instance of 'Variable Init Exp'.
See Also:
doSwitch(EObject)

caseWhileExp

public T caseWhileExp(WhileExp object)
Returns the result of interpretting the object as an instance of 'While Exp'. This implementation returns null; returning a non-null result will terminate the switch.

Parameters:
object - the target of the switch.
Returns:
the result of interpretting the object as an instance of 'While Exp'.
See Also:
doSwitch(EObject)

caseComputeExp

public T caseComputeExp(ComputeExp object)
Returns the result of interpretting the object as an instance of 'Compute Exp'. This implementation returns null; returning a non-null result will terminate the switch.

Parameters:
object - the target of the switch.
Returns:
the result of interpretting the object as an instance of 'Compute Exp'.
See Also:
doSwitch(EObject)

caseAltExp

public T caseAltExp(AltExp object)
Returns the result of interpretting the object as an instance of 'Alt Exp'. This implementation returns null; returning a non-null result will terminate the switch.

Parameters:
object - the target of the switch.
Returns:
the result of interpretting the object as an instance of 'Alt Exp'.
See Also:
doSwitch(EObject)

caseUnlinkExp

public T caseUnlinkExp(UnlinkExp object)
Returns the result of interpretting the object as an instance of 'Unlink Exp'. This implementation returns null; returning a non-null result will terminate the switch.

Parameters:
object - the target of the switch.
Returns:
the result of interpretting the object as an instance of 'Unlink Exp'.
See Also:
doSwitch(EObject)

caseReturnExp

public T caseReturnExp(ReturnExp object)
Returns the result of interpretting the object as an instance of 'Return Exp'. This implementation returns null; returning a non-null result will terminate the switch.

Parameters:
object - the target of the switch.
Returns:
the result of interpretting the object as an instance of 'Return Exp'.
See Also:
doSwitch(EObject)

caseBreakExp

public T caseBreakExp(BreakExp object)
Returns the result of interpretting the object as an instance of 'Break Exp'. This implementation returns null; returning a non-null result will terminate the switch.

Parameters:
object - the target of the switch.
Returns:
the result of interpretting the object as an instance of 'Break Exp'.
See Also:
doSwitch(EObject)

caseTryExp

public T caseTryExp(TryExp object)
Returns the result of interpretting the object as an instance of 'Try Exp'. This implementation returns null; returning a non-null result will terminate the switch.

Parameters:
object - the target of the switch.
Returns:
the result of interpretting the object as an instance of 'Try Exp'.
See Also:
doSwitch(EObject)

caseRaiseExp

public T caseRaiseExp(RaiseExp object)
Returns the result of interpretting the object as an instance of 'Raise Exp'. This implementation returns null; returning a non-null result will terminate the switch.

Parameters:
object - the target of the switch.
Returns:
the result of interpretting the object as an instance of 'Raise Exp'.
See Also:
doSwitch(EObject)

caseContinueExp

public T caseContinueExp(ContinueExp object)
Returns the result of interpretting the object as an instance of 'Continue Exp'. This implementation returns null; returning a non-null result will terminate the switch.

Parameters:
object - the target of the switch.
Returns:
the result of interpretting the object as an instance of 'Continue Exp'.
See Also:
doSwitch(EObject)

caseForExp

public T caseForExp(ForExp object)
Returns the result of interpretting the object as an instance of 'For Exp'. This implementation returns null; returning a non-null result will terminate the switch.

Parameters:
object - the target of the switch.
Returns:
the result of interpretting the object as an instance of 'For Exp'.
See Also:
doSwitch(EObject)

caseTupleExp

public T caseTupleExp(TupleExp object)
Returns the result of interpretting the object as an instance of 'Tuple Exp'. This implementation returns null; returning a non-null result will terminate the switch.

Parameters:
object - the target of the switch.
Returns:
the result of interpretting the object as an instance of 'Tuple Exp'.
See Also:
doSwitch(EObject)

caseTypedef

public T caseTypedef(Typedef object)
Returns the result of interpretting the object as an instance of 'Typedef'. This implementation returns null; returning a non-null result will terminate the switch.

Parameters:
object - the target of the switch.
Returns:
the result of interpretting the object as an instance of 'Typedef'.
See Also:
doSwitch(EObject)

caseInstantiationExp

public T caseInstantiationExp(InstantiationExp object)
Returns the result of interpretting the object as an instance of 'Instantiation Exp'. This implementation returns null; returning a non-null result will terminate the switch.

Parameters:
object - the target of the switch.
Returns:
the result of interpretting the object as an instance of 'Instantiation Exp'.
See Also:
doSwitch(EObject)

caseDictionaryType

public T caseDictionaryType(DictionaryType object)
Returns the result of interpretting the object as an instance of 'Dictionary Type'. This implementation returns null; returning a non-null result will terminate the switch.

Parameters:
object - the target of the switch.
Returns:
the result of interpretting the object as an instance of 'Dictionary Type'.
See Also:
doSwitch(EObject)

caseDictLiteralExp

public T caseDictLiteralExp(DictLiteralExp object)
Returns the result of interpretting the object as an instance of 'Dict Literal Exp'. This implementation returns null; returning a non-null result will terminate the switch.

Parameters:
object - the target of the switch.
Returns:
the result of interpretting the object as an instance of 'Dict Literal Exp'.
See Also:
doSwitch(EObject)

caseDictLiteralPart

public T caseDictLiteralPart(DictLiteralPart object)
Returns the result of interpretting the object as an instance of 'Dict Literal Part'. This implementation returns null; returning a non-null result will terminate the switch.

Parameters:
object - the target of the switch.
Returns:
the result of interpretting the object as an instance of 'Dict Literal Part'.
See Also:
doSwitch(EObject)

caseTemplateParameterType

public T caseTemplateParameterType(TemplateParameterType object)
Returns the result of interpretting the object as an instance of 'Template Parameter Type'. This implementation returns null; returning a non-null result will terminate the switch.

Parameters:
object - the target of the switch.
Returns:
the result of interpretting the object as an instance of 'Template Parameter Type'.
See Also:
doSwitch(EObject)

caseLogExp

public T caseLogExp(LogExp object)
Returns the result of interpretting the object as an instance of 'Log Exp'. This implementation returns null; returning a non-null result will terminate the switch.

Parameters:
object - the target of the switch.
Returns:
the result of interpretting the object as an instance of 'Log Exp'.
See Also:
doSwitch(EObject)

caseAssertExp

public T caseAssertExp(AssertExp object)
Returns the result of interpretting the object as an instance of 'Assert Exp'. This implementation returns null; returning a non-null result will terminate the switch.

Parameters:
object - the target of the switch.
Returns:
the result of interpretting the object as an instance of 'Assert Exp'.
See Also:
doSwitch(EObject)

caseImperativeLoopExp

public T caseImperativeLoopExp(ImperativeLoopExp object)
Returns the result of interpretting the object as an instance of 'Imperative Loop Exp'. This implementation returns null; returning a non-null result will terminate the switch.

Parameters:
object - the target of the switch.
Returns:
the result of interpretting the object as an instance of 'Imperative Loop Exp'.
See Also:
doSwitch(EObject)

caseImperativeIterateExp

public T caseImperativeIterateExp(ImperativeIterateExp object)
Returns the result of interpretting the object as an instance of 'Imperative Iterate Exp'. This implementation returns null; returning a non-null result will terminate the switch.

Parameters:
object - the target of the switch.
Returns:
the result of interpretting the object as an instance of 'Imperative Iterate Exp'.
See Also:
doSwitch(EObject)

caseImperativeExpression

public T caseImperativeExpression(ImperativeExpression object)
Returns the result of interpretting the object as an instance of 'Imperative Expression'. This implementation returns null; returning a non-null result will terminate the switch.

Parameters:
object - the target of the switch.
Returns:
the result of interpretting the object as an instance of 'Imperative Expression'.
See Also:
doSwitch(EObject)

caseUnpackExp

public T caseUnpackExp(UnpackExp object)
Returns the result of interpretting the object as an instance of 'Unpack Exp'. This implementation returns null; returning a non-null result will terminate the switch.

Parameters:
object - the target of the switch.
Returns:
the result of interpretting the object as an instance of 'Unpack Exp'.
See Also:
doSwitch(EObject)

caseAnonymousTupleType

public T caseAnonymousTupleType(AnonymousTupleType object)
Returns the result of interpretting the object as an instance of 'Anonymous Tuple Type'. This implementation returns null; returning a non-null result will terminate the switch.

Parameters:
object - the target of the switch.
Returns:
the result of interpretting the object as an instance of 'Anonymous Tuple Type'.
See Also:
doSwitch(EObject)

caseAnonymousTupleLiteralExp

public T caseAnonymousTupleLiteralExp(AnonymousTupleLiteralExp object)
Returns the result of interpretting the object as an instance of 'Anonymous Tuple Literal Exp'. This implementation returns null; returning a non-null result will terminate the switch.

Parameters:
object - the target of the switch.
Returns:
the result of interpretting the object as an instance of 'Anonymous Tuple Literal Exp'.
See Also:
doSwitch(EObject)

caseAnonymousTupleLiteralPart

public T caseAnonymousTupleLiteralPart(AnonymousTupleLiteralPart object)
Returns the result of interpretting the object as an instance of 'Anonymous Tuple Literal Part'. This implementation returns null; returning a non-null result will terminate the switch.

Parameters:
object - the target of the switch.
Returns:
the result of interpretting the object as an instance of 'Anonymous Tuple Literal Part'.
See Also:
doSwitch(EObject)

caseListType

public T caseListType(ListType object)
Returns the result of interpretting the object as an instance of 'List Type'. This implementation returns null; returning a non-null result will terminate the switch.

Parameters:
object - the target of the switch.
Returns:
the result of interpretting the object as an instance of 'List Type'.
See Also:
doSwitch(EObject)

caseObject

public T caseObject(Object object)
Returns the result of interpretting the object as an instance of '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 interpretting the object as an instance of 'Object'.
See Also:
doSwitch(EObject)

caseElement

public T caseElement(Element object)
Returns the result of interpretting the object as an instance of 'Element'. This implementation returns null; returning a non-null result will terminate the switch.

Parameters:
object - the target of the switch.
Returns:
the result of interpretting the object as an instance of 'Element'.
See Also:
doSwitch(EObject)

caseNamedElement

public T caseNamedElement(NamedElement object)
Returns the result of interpretting the object as an instance of 'Named Element'. This implementation returns null; returning a non-null result will terminate the switch.

Parameters:
object - the target of the switch.
Returns:
the result of interpretting the object as an instance of 'Named Element'.
See Also:
doSwitch(EObject)

caseTypedElement

public T caseTypedElement(TypedElement object)
Returns the result of interpretting the object as an instance of 'Typed Element'. This implementation returns null; returning a non-null result will terminate the switch.

Parameters:
object - the target of the switch.
Returns:
the result of interpretting the object as an instance of 'Typed Element'.
See Also:
doSwitch(EObject)

caseOclExpression

public T caseOclExpression(OclExpression object)
Returns the result of interpretting the object as an instance of 'Ocl Expression'. This implementation returns null; returning a non-null result will terminate the switch.

Parameters:
object - the target of the switch.
Returns:
the result of interpretting the object as an instance of 'Ocl Expression'.
See Also:
doSwitch(EObject)

caseCallExp

public T caseCallExp(CallExp object)
Returns the result of interpretting the object as an instance of 'Call Exp'. This implementation returns null; returning a non-null result will terminate the switch.

Parameters:
object - the target of the switch.
Returns:
the result of interpretting the object as an instance of 'Call Exp'.
See Also:
doSwitch(EObject)

caseLoopExp

public T caseLoopExp(LoopExp object)
Returns the result of interpretting the object as an instance of 'Loop Exp'. This implementation returns null; returning a non-null result will terminate the switch.

Parameters:
object - the target of the switch.
Returns:
the result of interpretting the object as an instance of 'Loop Exp'.
See Also:
doSwitch(EObject)

caseType

public T caseType(Type object)
Returns the result of interpretting the object as an instance of 'Type'. This implementation returns null; returning a non-null result will terminate the switch.

Parameters:
object - the target of the switch.
Returns:
the result of interpretting the object as an instance of 'Type'.
See Also:
doSwitch(EObject)

caseClass

public T caseClass(Class object)
Returns the result of interpretting the object as an instance of 'Class'. This implementation returns null; returning a non-null result will terminate the switch.

Parameters:
object - the target of the switch.
Returns:
the result of interpretting the object as an instance of 'Class'.
See Also:
doSwitch(EObject)

caseDataType

public T caseDataType(DataType object)
Returns the result of interpretting the object as an instance of 'Data Type'. This implementation returns null; returning a non-null result will terminate the switch.

Parameters:
object - the target of the switch.
Returns:
the result of interpretting the object as an instance of 'Data Type'.
See Also:
doSwitch(EObject)

caseCollectionType

public T caseCollectionType(CollectionType object)
Returns the result of interpretting the object as an instance of 'Collection Type'. This implementation returns null; returning a non-null result will terminate the switch.

Parameters:
object - the target of the switch.
Returns:
the result of interpretting the object as an instance of 'Collection Type'.
See Also:
doSwitch(EObject)

caseLiteralExp

public T caseLiteralExp(LiteralExp object)
Returns the result of interpretting the object as an instance of 'Literal Exp'. This implementation returns null; returning a non-null result will terminate the switch.

Parameters:
object - the target of the switch.
Returns:
the result of interpretting the object as an instance of 'Literal Exp'.
See Also:
doSwitch(EObject)

caseFeaturePropertyCall

public T caseFeaturePropertyCall(FeaturePropertyCall object)
Returns the result of interpretting the object as an instance of 'Feature Property Call'. This implementation returns null; returning a non-null result will terminate the switch.

Parameters:
object - the target of the switch.
Returns:
the result of interpretting the object as an instance of 'Feature Property Call'.
See Also:
doSwitch(EObject)

caseOperationCallExp

public T caseOperationCallExp(OperationCallExp object)
Returns the result of interpretting the object as an instance of 'Operation Call Exp'. This implementation returns null; returning a non-null result will terminate the switch.

Parameters:
object - the target of the switch.
Returns:
the result of interpretting the object as an instance of 'Operation Call Exp'.
See Also:
doSwitch(EObject)

defaultCase

public T defaultCase(org.eclipse.emf.ecore.EObject object)
Returns the result of interpretting 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 interpretting the object as an instance of 'EObject'.
See Also:
doSwitch(org.eclipse.emf.ecore.EObject)