## org.eclipse.emf.common.notify.impl
Class AdapterImpl

    java.lang.Object
      org.eclipse.emf.common.notify.impl.AdapterImpl

All Implemented Interfaces:
  Adapter, Adapter.Internal

Direct Known Subclasses:
  AdapterFactoryEditingDomain.EditingDomainProvider, EContentAdapter, EMFPropertyListener, ESuperAdapter, ItemProviderAdapter, MappingRootImpl.MappedObjectStateAdapter, ResourceImpl.ModificationTrackingAdapter

    public class AdapterImpl

extends java.lang.Object
implements Adapter.Internal

An extensible adapter implementation.

Nested Class Summary

Nested classes/interfaces inherited from interface org.eclipse.emf.common.notify.Adapter
`Adapter.Internal`

Field Summary
`protected Notifier` `target` The last notifier set to this adapter.

Constructor Summary
`AdapterImpl()` Creates an instance.

Method Summary
`Notifier` `getTarget()` Returns the target from which the adapter receives notification.
`boolean` `isAdapterForType(java.lang.Object type)` Returns `false`
`void` `notifyChanged(Notification msg)` Does nothing; clients may override so that it does something.
`void` `setTarget(Notifier newTarget)` Sets the target from which the adapter will receive notification.
`void` `unsetTarget(Notifier oldTarget)` Unsets the target from which the adapter will receive notification.

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### target

    protected Notifier target

  The last notifier set to this adapter.

Constructor Detail

### AdapterImpl

    public AdapterImpl()

  Creates an instance.

Method Detail

### isAdapterForType

    public boolean isAdapterForType(java.lang.Object type)

  Returns `false`

  Specified by:
    `isAdapterForType` in interface `Adapter`
  Parameters:
    `type` - the type.
  Returns:
    `false`
  See Also:
    `AdapterFactory.isFactoryForType(java.lang.Object)`

### notifyChanged

    public void notifyChanged(Notification msg)

  Does nothing; clients may override so that it does something.

  Specified by:
    `notifyChanged` in interface `Adapter`
  Parameters:
    `msg` - a description of the change.

### getTarget

    public Notifier getTarget()

  Description copied from interface: `Adapter`
  Returns the target from which the adapter receives notification. In general, an adapter may be shared by more than one notifier.

  Specified by:
    `getTarget` in interface `Adapter`
  Returns:
    the target notifier.
  See Also:
    `Adapter.setTarget(org.eclipse.emf.common.notify.Notifier)`

### setTarget

    public void setTarget(Notifier newTarget)

  Description copied from interface: `Adapter`
  Sets the target from which the adapter will receive notification. This method is only to be called by a notifier when this adapter is added to or removed from its adapter list. In general, an adapter may be shared by more than one notifier.

  Specified by:
    `setTarget` in interface `Adapter`
  Parameters:
    `newTarget` - the new notifier.
  See Also:
    `Adapter.getTarget()`

### unsetTarget

    public void unsetTarget(Notifier oldTarget)

  Description copied from interface: `Adapter.Internal`
  Unsets the target from which the adapter will receive notification. This method is only to be called by a notifier when this adapter is removed from its adapter list. In general, an adapter may be shared by more than one notifier, so this mechanism allows the adapter to know specifically which notifier will no longer be notifying.

  Specified by:
    `unsetTarget` in interface `Adapter.Internal`
  Parameters:
    `oldTarget` - the old notifier.
  See Also:
    `Adapter.getTarget()`, `Adapter.setTarget(Notifier)`

Copyright 2001-2006 IBM Corporation and others. All Rights Reserved.