org.mule.ra
Class DelegateWorkManager

java.lang.Object
  extended byorg.mule.ra.DelegateWorkManager
All Implemented Interfaces:
Disposable, Executor, Lifecycle, Startable, Stoppable, UMOWorkManager, WorkManager

public class DelegateWorkManager
extends Object
implements UMOWorkManager

DelegateWorkManager is a wrapper around a WorkManager provided by a JCA container.


Nested Class Summary
protected static class DelegateWorkManager.RunnableWorkAdapter
           
 
Field Summary
 
Fields inherited from interface javax.resource.spi.work.WorkManager
IMMEDIATE, INDEFINITE, UNKNOWN
 
Constructor Summary
DelegateWorkManager(WorkManager workManager)
           
 
Method Summary
 void dispose()
          A lifecycle method where implementor should free up any resources.
 void doWork(Work work)
           
 void doWork(Work work, long l, ExecutionContext executionContext, WorkListener workListener)
           
 void execute(Runnable command)
           
 void scheduleWork(Work work)
           
 void scheduleWork(Work work, long l, ExecutionContext executionContext, WorkListener workListener)
           
 void start()
           
 long startWork(Work work)
           
 long startWork(Work work, long l, ExecutionContext executionContext, WorkListener workListener)
           
 void stop()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DelegateWorkManager

public DelegateWorkManager(WorkManager workManager)
Method Detail

doWork

public void doWork(Work work)
            throws WorkException
Specified by:
doWork in interface WorkManager
Throws:
WorkException

doWork

public void doWork(Work work,
                   long l,
                   ExecutionContext executionContext,
                   WorkListener workListener)
            throws WorkException
Specified by:
doWork in interface WorkManager
Throws:
WorkException

startWork

public long startWork(Work work)
               throws WorkException
Specified by:
startWork in interface WorkManager
Throws:
WorkException

startWork

public long startWork(Work work,
                      long l,
                      ExecutionContext executionContext,
                      WorkListener workListener)
               throws WorkException
Specified by:
startWork in interface WorkManager
Throws:
WorkException

scheduleWork

public void scheduleWork(Work work)
                  throws WorkException
Specified by:
scheduleWork in interface WorkManager
Throws:
WorkException

scheduleWork

public void scheduleWork(Work work,
                         long l,
                         ExecutionContext executionContext,
                         WorkListener workListener)
                  throws WorkException
Specified by:
scheduleWork in interface WorkManager
Throws:
WorkException

execute

public void execute(Runnable command)
Specified by:
execute in interface Executor

start

public void start()
           throws UMOException
Specified by:
start in interface Startable
Throws:
UMOException

stop

public void stop()
          throws UMOException
Specified by:
stop in interface Stoppable
Throws:
UMOException

dispose

public void dispose()
Description copied from interface: Disposable
A lifecycle method where implementor should free up any resources. If an exception is thrown it should just be logged and processing should continue. This method should not throw Runtime exceptions.

Specified by:
dispose in interface Disposable


Copyright © 2003-2008 MuleSource, Inc.. All Rights Reserved.