com.iternum.swlink.activator
Class AbstractActivator

java.lang.Object
  extended bycom.iternum.swlink.activator.AbstractActivator
All Implemented Interfaces:
Activator
Direct Known Subclasses:
ActionEventActivator, ChangeEventActivator, FocusLostActivator, KeyReleasedActivator, PropertyChangeActivator, SelectionChangedActivator

public abstract class AbstractActivator
extends java.lang.Object
implements Activator

Author:
bankkar Abstract superclass for Activators with several convenience methods, lifecycle handling and storage for the Activatable.

Constructor Summary
AbstractActivator()
           
 
Method Summary
 void close()
          Deregisters the source object by calling deregisterFromSource().
protected abstract  void deregisterFromSource()
          Deregister this link with its source.
 Activatable getActivatable()
           
 java.lang.Object getSource()
           
protected abstract  void registerWithSource()
          Register this link with its source.
 void setActivatable(Activatable pActivatable)
          Sets the link to activate.
 void setSource(java.lang.Object pSource)
          Set the source object and register with source.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface com.iternum.swlink.Activator
setActivatorParam
 

Constructor Detail

AbstractActivator

public AbstractActivator()
Method Detail

getSource

public final java.lang.Object getSource()
Specified by:
getSource in interface Activator
Returns:
The source of the activator
See Also:
Activator.getSource()

setSource

public final void setSource(java.lang.Object pSource)
Set the source object and register with source. If the passsed object is an EndpointProxy register with the endpoint proxy instead

Specified by:
setSource in interface Activator
Parameters:
pSource - The source to register

setActivatable

public final void setActivatable(Activatable pActivatable)
Sets the link to activate.

Specified by:
setActivatable in interface Activator
Parameters:
pActivatable - - The activatable to activate

getActivatable

public final Activatable getActivatable()
Returns:
The Activatable this Activator activates.

close

public final void close()
Deregisters the source object by calling deregisterFromSource().

Specified by:
close in interface Activator

registerWithSource

protected abstract void registerWithSource()
Register this link with its source. To be implemented in concrete subclasses.


deregisterFromSource

protected abstract void deregisterFromSource()
Deregister this link with its source. To be implemented in concrete subclasses