|
Oracle® Coherence Java API Reference v3.5 E14977-01 |
|||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||
java.lang.Object
com.tangosol.util.Base
com.tangosol.coherence.commonj.WorkManager.WorkHolder
protected class WorkManager.WorkHolder
A holder for a Work object that serves as a communication intermediary between a client and a [remote] service.
| Nested Class Summary | |
|---|---|
protected class |
WorkManager.WorkHolder.EventA WorkEvent implementation. |
| Field Summary | |
|---|---|
protected commonj.work.WorkListener |
m_listenerA work listener associated with the corresponding Work. |
protected java.util.List |
m_listWaitsA list of collections waiting for this Work to complete. |
protected long |
m_lWorkIdThe corresponding work id. |
protected Member |
m_memberThe server Member that is to run the Work. |
protected java.lang.Object |
m_oResultThe Work result. |
protected InvocationService |
m_serviceThe underlying Invocation service. |
protected WorkManager.WorkStatus |
m_statusCurrent Work status. |
| Constructor Summary | |
|---|---|
WorkManager.WorkHolder(long lWorkId, commonj.work.WorkListener listener, InvocationService service, Member member)Construct a WorkHolder for a Work with a given work id that is scheduled to be executed on a specified service. |
|
| Method Summary | |
|---|---|
void |
addWait(java.util.Collection collWait)Add a collection to a wait list. |
int |
compareTo(java.lang.Object o)Compare this WorkItem with the specified object for order. |
boolean |
equals(java.lang.Object o)Compare this WorkItem with the specified object for equality. |
commonj.work.WorkListener |
getListener()Return the associated WorkListener. |
commonj.work.WorkManager |
getPinnedWorkManager()Return a pinned WorkManager which represents the JVM that was used to execute this Work. |
commonj.work.Work |
getResult()Return the Work once it has completed. |
InvocationService |
getService()Return the InvocationService used to execute the corresponding Work. |
int |
getStatus()Return the current status of dispatching the Work. |
Member |
getTargetMember()Return the Member that the corresponding Work is to be executed at. |
java.util.Collection[] |
getWaits()Assemble an array of collection that wait for this Work. |
long |
getWorkId()Return the work id. |
WorkManager.WorkStatus |
getWorkStatus()Return the WorkStatus object. |
int |
hashCode()Return a hash code value for this WorkHolder. |
void |
release()Calls the remote Work object's Work.release() method. |
void |
removeWait(java.util.Collection collWait)Remove a collection from a wait list. |
protected void |
setWorkStatus(WorkManager.WorkStatus status)Update the WorkStatus. |
java.lang.String |
toString()Return a string representation of the WorkHolder object. |
| Field Detail |
|---|
protected long m_lWorkId
protected commonj.work.WorkListener m_listener
protected InvocationService m_service
protected Member m_member
protected WorkManager.WorkStatus m_status
protected java.lang.Object m_oResult
protected java.util.List m_listWaits
| Constructor Detail |
|---|
public WorkManager.WorkHolder(long lWorkId,
commonj.work.WorkListener listener,
InvocationService service,
Member member)
lWorkId - the Work idlistener - the WorkListenerservice - the InvocationService to usemember - the target Member| Method Detail |
|---|
public int getStatus()
WorkEvent for the values.getStatus in interface commonj.work.WorkItem
public commonj.work.Work getResult()
throws commonj.work.WorkException
getResult in interface commonj.work.WorkItemcommonj.work.WorkExceptionpublic commonj.work.WorkManager getPinnedWorkManager()
getPinnedWorkManager in interface commonj.work.RemoteWorkItempublic void release()
Work.release() method.release in interface commonj.work.RemoteWorkItempublic int compareTo(java.lang.Object o)
compareTo in interface java.lang.Comparablepublic long getWorkId()
public WorkManager.WorkStatus getWorkStatus()
public InvocationService getService()
public Member getTargetMember()
public commonj.work.WorkListener getListener()
protected void setWorkStatus(WorkManager.WorkStatus status)
status - the WorkStatus object to updatepublic void addWait(java.util.Collection collWait)
collWait - a collection that waits for this Workpublic void removeWait(java.util.Collection collWait)
addWait(java.util.Collection) call.collWait - a collection that waits for this Workpublic java.util.Collection[] getWaits()
public int hashCode()
public boolean equals(java.lang.Object o)
public java.lang.String toString()
|
Oracle® Coherence Java API Reference v3.5 E14977-01 |
|||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||