org.oddjob.framework
Class BaseWrapper

java.lang.Object
  extended byorg.oddjob.framework.BaseComponent
      extended byorg.oddjob.framework.BaseWrapper
All Implemented Interfaces:
ContextAware, Destroyable, org.apache.commons.beanutils.DynaBean, Iconic, Initializable, LogEnabled, Resetable, java.lang.Runnable, Stateful, Stoppable
Direct Known Subclasses:
RunnableWrapper, ServiceWrapper

public abstract class BaseWrapper
extends BaseComponent
implements java.lang.Runnable, Stateful, Resetable, org.apache.commons.beanutils.DynaBean, Stoppable, LogEnabled, ContextAware, Initializable, Destroyable


Field Summary
 
Fields inherited from class org.oddjob.framework.BaseComponent
changes, destroyed, iconHelper, location, lock, stateHandler
 
Constructor Summary
BaseWrapper()
           
 
Method Summary
 boolean contains(java.lang.String name, java.lang.String key)
           
 boolean equals(java.lang.Object other)
           
 java.lang.Object get(java.lang.String name)
           
 java.lang.Object get(java.lang.String name, int index)
           
 java.lang.Object get(java.lang.String name, java.lang.String key)
           
protected abstract  org.apache.commons.beanutils.DynaBean getDynaBean()
           
 org.apache.commons.beanutils.DynaClass getDynaClass()
           
 java.lang.String getLogger()
           
protected abstract  java.lang.Object getProxy()
           
protected  int getResult()
           
protected abstract  java.lang.Object getWrapped()
           
 void hardReset()
          Perform a hard reset on the job.
 void init()
          Initialise the job, All constant values and child components have been added by this point.
static java.lang.Class[] interfacesFor(java.lang.Object object)
           
protected  org.apache.log4j.Logger logger()
           
 void onDestroy()
          Subclasses override this method to clear up resources.
protected  void onStop()
           
 void remove(java.lang.String name, java.lang.String key)
           
 void set(java.lang.String name, int index, java.lang.Object value)
           
 void set(java.lang.String name, java.lang.Object value)
           
 void set(java.lang.String name, java.lang.String key, java.lang.Object value)
           
 boolean setContext(ArooaContext context)
          Called during construction by the framework to allow a component access to the context that's creating it.
 void softReset()
          Perform a soft reset on the job.
 void stop()
          Stop executing.
 java.lang.String toString()
           
 
Methods inherited from class org.oddjob.framework.BaseComponent
addIconListener, addJobStateListener, addPropertyChangeListener, arooaRuntime, arooaRuntime, canHardReset, canSoftReset, configure, destroy, getLocation, iconForId, lastJobStateEvent, removeIconListener, removeJobStateListener, removePropertyChangeListener, setJobStateComplete, setJobStateException, setJobStateNotComplete, setJobStateReady
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface java.lang.Runnable
run
 
Methods inherited from interface org.oddjob.Stateful
addJobStateListener, removeJobStateListener
 
Methods inherited from interface org.oddjob.framework.Destroyable
destroy
 

Constructor Detail

BaseWrapper

public BaseWrapper()
Method Detail

getWrapped

protected abstract java.lang.Object getWrapped()

getDynaBean

protected abstract org.apache.commons.beanutils.DynaBean getDynaBean()

getProxy

protected abstract java.lang.Object getProxy()

init

public void init()
Description copied from interface: Initializable
Initialise the job, All constant values and child components have been added by this point.

Specified by:
init in interface Initializable

logger

protected org.apache.log4j.Logger logger()
Specified by:
logger in class BaseComponent

getLogger

public java.lang.String getLogger()
Specified by:
getLogger in interface LogEnabled

setContext

public boolean setContext(ArooaContext context)
Called during construction by the framework to allow a component access to the context that's creating it.

Specified by:
setContext in interface ContextAware
Parameters:
context - The ArooaXMLContext.
Returns:
true.;

softReset

public void softReset()
Perform a soft reset on the job.

Specified by:
softReset in interface Resetable

hardReset

public void hardReset()
Perform a hard reset on the job.

Specified by:
hardReset in interface Resetable

equals

public boolean equals(java.lang.Object other)

toString

public java.lang.String toString()

contains

public boolean contains(java.lang.String name,
                        java.lang.String key)
Specified by:
contains in interface org.apache.commons.beanutils.DynaBean

get

public java.lang.Object get(java.lang.String name)
Specified by:
get in interface org.apache.commons.beanutils.DynaBean

get

public java.lang.Object get(java.lang.String name,
                            int index)
Specified by:
get in interface org.apache.commons.beanutils.DynaBean

get

public java.lang.Object get(java.lang.String name,
                            java.lang.String key)
Specified by:
get in interface org.apache.commons.beanutils.DynaBean

getDynaClass

public org.apache.commons.beanutils.DynaClass getDynaClass()
Specified by:
getDynaClass in interface org.apache.commons.beanutils.DynaBean

remove

public void remove(java.lang.String name,
                   java.lang.String key)
Specified by:
remove in interface org.apache.commons.beanutils.DynaBean

set

public void set(java.lang.String name,
                int index,
                java.lang.Object value)
Specified by:
set in interface org.apache.commons.beanutils.DynaBean

set

public void set(java.lang.String name,
                java.lang.Object value)
Specified by:
set in interface org.apache.commons.beanutils.DynaBean

set

public void set(java.lang.String name,
                java.lang.String key,
                java.lang.Object value)
Specified by:
set in interface org.apache.commons.beanutils.DynaBean

stop

public final void stop()
Description copied from interface: Stoppable
Stop executing.

Specified by:
stop in interface Stoppable

onStop

protected void onStop()

getResult

protected int getResult()
Returns:

onDestroy

public void onDestroy()
Description copied from class: BaseComponent
Subclasses override this method to clear up resources.

Overrides:
onDestroy in class BaseComponent

interfacesFor

public static java.lang.Class[] interfacesFor(java.lang.Object object)