|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.eclipse.emf.ecore.util.Switch<T>
public abstract class Switch<T>
An abstract base class for all switch classes.
Constructor Summary | |
---|---|
Switch()
|
Method Summary | |
---|---|
T |
defaultCase(EObject eObject)
Returns the result of interpreting the object as an instance of 'EObject'. |
protected T |
doSwitch(EClass eClass,
EObject eObject)
Calls caseXXX for each (super-)class of the model until one returns a non-null result;
it yields that result. |
T |
doSwitch(EObject eObject)
Dispatches the target object to the appropriate caseXXX methods. |
protected T |
doSwitch(int classifierID,
EObject eObject)
Calls caseXXX for each class of the model until one returns a non-null result;
it yields that result. |
protected abstract boolean |
isSwitchFor(EPackage ePackage)
Indicates whether the receiver is a switch for the specified package. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public Switch()
Method Detail |
---|
public T defaultCase(EObject eObject)
eObject
- the target of the switch.
doSwitch(org.eclipse.emf.ecore.EObject)
protected T doSwitch(EClass eClass, EObject eObject)
caseXXX
for each (super-)class of the model until one returns a non-null result;
it yields that result.
eClass
- the class or superclass of eObject
to consider.
The class's containing EPackage
determines whether the receiving switch object can handle the request.eObject
- the model object to pass to the appropriate caseXXX
.
caseXXX
call.public T doSwitch(EObject eObject)
caseXXX
methods.
eObject
- the model object to pass to the appropriate caseXXX
.
caseXXX
call.protected T doSwitch(int classifierID, EObject eObject)
caseXXX
for each class of the model until one returns a non-null result;
it yields that result.
classifierID
- the classifier ID
of the (super-)class of eObject
relative to its defining EPackage
.eObject
- the model object to pass to the appropriate caseXXX
method.
caseXXX
call.protected abstract boolean isSwitchFor(EPackage ePackage)
ePackage
- the package of interest.
true
if the receiver is a switch for package
.
|
Copyright 2001-2012 IBM Corporation and others. All Rights Reserved. |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |