Class ATLSwitch<T>
java.lang.Object
org.eclipse.m2m.atl.common.ATL.util.ATLSwitch<T>
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:
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncaseActionBlock
(ActionBlock object) Returns the result of interpreting the object as an instance of 'Action Block'.caseBinding
(Binding object) Returns the result of interpreting the object as an instance of 'Binding'.caseBindingStat
(BindingStat object) Returns the result of interpreting the object as an instance of 'Binding Stat'.caseCalledRule
(CalledRule object) Returns the result of interpreting the object as an instance of 'Called Rule'.caseDropPattern
(DropPattern object) Returns the result of interpreting the object as an instance of 'Drop Pattern'.caseExpressionStat
(ExpressionStat object) Returns the result of interpreting the object as an instance of 'Expression Stat'.Returns the result of interpreting the object as an instance of 'For Each Out Pattern Element'.caseForStat
(ForStat object) Returns the result of interpreting the object as an instance of 'For Stat'.caseHelper
(Helper object) Returns the result of interpreting the object as an instance of 'Helper'.caseIfStat
(IfStat object) Returns the result of interpreting the object as an instance of 'If Stat'.caseInPattern
(InPattern object) Returns the result of interpreting the object as an instance of 'In Pattern'.caseInPatternElement
(InPatternElement object) Returns the result of interpreting the object as an instance of 'In Pattern Element'.caseLazyMatchedRule
(LazyMatchedRule object) Returns the result of interpreting the object as an instance of 'Lazy Matched Rule'.caseLibrary
(Library object) Returns the result of interpreting the object as an instance of 'Library'.caseLibraryRef
(LibraryRef object) Returns the result of interpreting the object as an instance of 'Library Ref'.caseLocatedElement
(LocatedElement object) Returns the result of interpreting the object as an instance of 'Located Element'.caseMatchedRule
(MatchedRule object) Returns the result of interpreting the object as an instance of 'Matched Rule'.caseModule
(Module object) Returns the result of interpreting the object as an instance of 'Module'.caseModuleElement
(ModuleElement object) Returns the result of interpreting the object as an instance of 'Module Element'.caseOutPattern
(OutPattern object) Returns the result of interpreting the object as an instance of 'Out Pattern'.Returns the result of interpreting the object as an instance of 'Out Pattern Element'.casePatternElement
(PatternElement object) Returns the result of interpreting the object as an instance of 'Pattern Element'.Returns the result of interpreting the object as an instance of 'Query'.Returns the result of interpreting the object as an instance of 'Rule'.Returns the result of interpreting the object as an instance of 'Rule Variable Declaration'.Returns the result of interpreting the object as an instance of 'Simple In Pattern Element'.Returns the result of interpreting the object as an instance of 'Simple Out Pattern Element'.caseStatement
(Statement object) Returns the result of interpreting the object as an instance of 'Statement'.Returns the result of interpreting the object as an instance of 'Unit'.Returns the result of interpreting the object as an instance of 'Variable Declaration'.defaultCase
(org.eclipse.emf.ecore.EObject object) Returns the result of interpreting the object as an instance of 'EObject'.protected T
doSwitch
(int classifierID, org.eclipse.emf.ecore.EObject theEObject) CallscaseXXX
for each class of the model until one returns a non null result; it yields that result.protected T
doSwitch
(org.eclipse.emf.ecore.EClass theEClass, org.eclipse.emf.ecore.EObject theEObject) CallscaseXXX
for each class of the model until one returns a non null result; it yields that result.doSwitch
(org.eclipse.emf.ecore.EObject theEObject) CallscaseXXX
for each class of the model until one returns a non null result; it yields that result.
-
Field Details
-
modelPackage
The cached model package
-
-
Constructor Details
-
ATLSwitch
public ATLSwitch()Creates an instance of the switch.
-
-
Method Details
-
doSwitch
CallscaseXXX
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.
-
doSwitch
protected T doSwitch(org.eclipse.emf.ecore.EClass theEClass, org.eclipse.emf.ecore.EObject theEObject) CallscaseXXX
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.
-
doSwitch
CallscaseXXX
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.
-
caseLocatedElement
Returns the result of interpreting the object as an instance of 'Located 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 interpreting the object as an instance of 'Located Element'.
- See Also:
-
caseUnit
Returns the result of interpreting the object as an instance of 'Unit'. 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 'Unit'.
- See Also:
-
caseLibrary
Returns the result of interpreting the object as an instance of 'Library'. 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 'Library'.
- See Also:
-
caseQuery
Returns the result of interpreting the object as an instance of 'Query'. 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 'Query'.
- See Also:
-
caseModule
Returns the result of interpreting the object as an instance of 'Module'. 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 'Module'.
- See Also:
-
caseModuleElement
Returns the result of interpreting the object as an instance of 'Module 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 interpreting the object as an instance of 'Module Element'.
- See Also:
-
caseHelper
Returns the result of interpreting the object as an instance of 'Helper'. 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 'Helper'.
- See Also:
-
caseRule
Returns the result of interpreting the object as an instance of 'Rule'. 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 'Rule'.
- See Also:
-
caseMatchedRule
Returns the result of interpreting the object as an instance of 'Matched Rule'. 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 'Matched Rule'.
- See Also:
-
caseLazyMatchedRule
Returns the result of interpreting the object as an instance of 'Lazy Matched Rule'. 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 'Lazy Matched Rule'.
- See Also:
-
caseCalledRule
Returns the result of interpreting the object as an instance of 'Called Rule'. 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 'Called Rule'.
- See Also:
-
caseInPattern
Returns the result of interpreting the object as an instance of 'In Pattern'. 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 'In Pattern'.
- See Also:
-
caseOutPattern
Returns the result of interpreting the object as an instance of 'Out Pattern'. 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 'Out Pattern'.
- See Also:
-
caseDropPattern
Returns the result of interpreting the object as an instance of 'Drop Pattern'. 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 'Drop Pattern'.
- See Also:
-
casePatternElement
Returns the result of interpreting the object as an instance of 'Pattern 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 interpreting the object as an instance of 'Pattern Element'.
- See Also:
-
caseInPatternElement
Returns the result of interpreting the object as an instance of 'In Pattern 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 interpreting the object as an instance of 'In Pattern Element'.
- See Also:
-
caseSimpleInPatternElement
Returns the result of interpreting the object as an instance of 'Simple In Pattern 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 interpreting the object as an instance of 'Simple In Pattern Element'.
- See Also:
-
caseOutPatternElement
Returns the result of interpreting the object as an instance of 'Out Pattern 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 interpreting the object as an instance of 'Out Pattern Element'.
- See Also:
-
caseSimpleOutPatternElement
Returns the result of interpreting the object as an instance of 'Simple Out Pattern 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 interpreting the object as an instance of 'Simple Out Pattern Element'.
- See Also:
-
caseForEachOutPatternElement
Returns the result of interpreting the object as an instance of 'For Each Out Pattern 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 interpreting the object as an instance of 'For Each Out Pattern Element'.
- See Also:
-
caseBinding
Returns the result of interpreting the object as an instance of 'Binding'. 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 'Binding'.
- See Also:
-
caseRuleVariableDeclaration
Returns the result of interpreting the object as an instance of 'Rule Variable Declaration'. 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 'Rule Variable Declaration'.
- See Also:
-
caseLibraryRef
Returns the result of interpreting the object as an instance of 'Library Ref'. 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 'Library Ref'.
- See Also:
-
caseActionBlock
Returns the result of interpreting the object as an instance of 'Action Block'. 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 'Action Block'.
- See Also:
-
caseStatement
Returns the result of interpreting the object as an instance of 'Statement'. 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 'Statement'.
- See Also:
-
caseExpressionStat
Returns the result of interpreting the object as an instance of 'Expression Stat'. 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 'Expression Stat'.
- See Also:
-
caseBindingStat
Returns the result of interpreting the object as an instance of 'Binding Stat'. 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 'Binding Stat'.
- See Also:
-
caseIfStat
Returns the result of interpreting the object as an instance of 'If Stat'. 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 'If Stat'.
- See Also:
-
caseForStat
Returns the result of interpreting the object as an instance of 'For Stat'. 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 'For Stat'.
- See Also:
-
caseVariableDeclaration
Returns the result of interpreting the object as an instance of 'Variable Declaration'. 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 'Variable Declaration'.
- See Also:
-
defaultCase
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:
-