org.eclipse.emf.ecore.util
Class EContentAdapter
java.lang.Object
|
+--org.eclipse.emf.common.notify.impl.AdapterImpl
|
+--org.eclipse.emf.ecore.util.EContentAdapter
- All Implemented Interfaces:
- Adapter
- public class EContentAdapter
- extends AdapterImpl
An adapter that maintains itself as an adapter for all contained objects
as they come and go.
It can be installed for an EObject
, a Resource
, or a ResourceSet
.
Method Summary |
protected void |
handleContainment(Notification notification)
Handles a containment change by adding and removing the adapter as appropriate. |
void |
notifyChanged(Notification notification)
Handles a notification by calling selfAdapter . |
protected void |
selfAdapt(Notification notification)
Handles a notification by calling handleContainment
for any containment-based notification. |
void |
setTarget(Notifier target)
Handles installation of the adapter
by adding the adapter to each of the directly contained objects. |
protected void |
unsetTarget(java.lang.Object target)
Handles installation of the adapter
by adding the adapter to each of the directly contained objects. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
EContentAdapter
public EContentAdapter()
notifyChanged
public void notifyChanged(Notification notification)
- Handles a notification by calling
selfAdapter
.
- Overrides:
notifyChanged
in class AdapterImpl
- Following copied from interface:
org.eclipse.emf.common.notify.Adapter
- Parameters:
notification
- a description of the change.
selfAdapt
protected void selfAdapt(Notification notification)
- Handles a notification by calling
handleContainment
for any containment-based notification.
handleContainment
protected void handleContainment(Notification notification)
- Handles a containment change by adding and removing the adapter as appropriate.
setTarget
public void setTarget(Notifier target)
- Handles installation of the adapter
by adding the adapter to each of the directly contained objects.
- Overrides:
setTarget
in class AdapterImpl
- Following copied from interface:
org.eclipse.emf.common.notify.Adapter
- Parameters:
newTarget
- the new notifier.- See Also:
Adapter.getTarget()
unsetTarget
protected void unsetTarget(java.lang.Object target)
- Handles installation of the adapter
by adding the adapter to each of the directly contained objects.