com.ibm.etill.framework.supervisor
Interface WorkItem

All Known Implementing Classes:
ApprovalExpirationWorkItem, AsynchronousApproveWorkItem, CassetteWorkItem

public interface WorkItem

Cassettes should not implement this interface. Rather, cassette objects that need to execute on a service thread should be referenced within a new CassetteWorkItem object, which implements this interface.

WorkItem defines the interface which must be implemented in order to place an object on the service queue for execution on a Service Thread.

This object can be used by cassette operations that need to occur on a separate thread, as long as no framework objects need to be locked, i.e., there is no need for synchronization on the thread. CassetteWorkItems should be used when object locks need to be obtained based on a Request object.


Method Summary
 void doYourWork()
          Called by the Framework service thread after this WorkItem is removed from the service queue for processing.
 Cassette getCassette()
          Returns the Cassette object associated with this WorkItem
 

Method Detail

doYourWork

public void doYourWork()
                throws ETillAbortOperation
Called by the Framework service thread after this WorkItem is removed from the service queue for processing.
Throws:
ETillAbortOperation - passed through to the Framework if thrown by underlying methods that are called to process the work item. If thrown, the Framework's service thread will subsequently move on to process the next queued work item.

getCassette

public Cassette getCassette()
Returns the Cassette object associated with this WorkItem
Returns:
Cassette object associated with this WorkItem