|
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectorg.jppf.jca.util.JPPFAccessorImpl
org.jppf.jca.cci.JPPFConnectionImpl
public class JPPFConnectionImpl
Implementation of a JCA connection. This class provides an API to send tasks to a JPPF driver.
| Field Summary |
|---|
| Fields inherited from class org.jppf.jca.util.JPPFAccessorImpl |
|---|
jppfClient, logWriter |
| Constructor Summary | |
|---|---|
JPPFConnectionImpl(JPPFManagedConnection conn)
Initialize this connection from a managed connection. |
|
| Method Summary | |
|---|---|
void |
addSubmissionStatusListener(String submissionId,
SubmissionStatusListener listener)
Add a listener to the submission with the specified id. |
void |
close()
Close this connection and notify the associated managed connection. |
Interaction |
createInteraction()
Create an interaction. |
Collection<String> |
getAllSubmissionIds()
Get the ids of all currently available submissions. |
LocalTransaction |
getLocalTransaction()
Transaction management is not supported in this version. |
JPPFManagedConnection |
getManagedConnection()
Get the associated managed connection. |
ConnectionMetaData |
getMetaData()
Get the connection metadata. |
ResultSetInfo |
getResultSetInfo()
This method is not supported in this version. |
List<JPPFTask> |
getSubmissionResults(String submissionId)
Get the results of an execution request. |
SubmissionStatus |
getSubmissionStatus(String submissionId)
Get the execution status of a tasks submission. |
boolean |
isClosed()
Determine whether this connection has been closed. |
void |
removeSubmissionStatusListener(String submissionId,
SubmissionStatusListener listener)
Remove a listener from the submission with the specified id. |
void |
setAvailable()
Set the closed state of this connection. |
void |
setManagedConnection(JPPFManagedConnection conn)
Set the associated managed connection. |
String |
submitNonBlocking(JPPFJob job)
Submit an asynchronous execution request to the JPPF client. |
String |
submitNonBlocking(JPPFJob job,
SubmissionStatusListener listener)
Submit an asynchronous execution request to the JPPF client. |
List<JPPFTask> |
waitForResults(String submissionId)
Wait until all results for the specfied job submission have been received. |
| Methods inherited from class org.jppf.jca.util.JPPFAccessorImpl |
|---|
getJppfClient, getLogWriter, setJppfClient, setLogWriter |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface org.jppf.jca.util.JPPFAccessor |
|---|
getJppfClient, getLogWriter, setJppfClient, setLogWriter |
| Constructor Detail |
|---|
public JPPFConnectionImpl(JPPFManagedConnection conn)
conn - a ManagedConnection instance.| Method Detail |
|---|
public void close()
close in interface ConnectionConnection.close()public Interaction createInteraction()
createInteraction in interface ConnectionInteraction instance.Connection.createInteraction()
public LocalTransaction getLocalTransaction()
throws ResourceException
getLocalTransaction in interface ConnectionResourceException - this method always throws a NotSupportedException.Connection.getLocalTransaction()public ConnectionMetaData getMetaData()
getMetaData in interface ConnectionJPPFConnectionMetaData instance.Connection.getMetaData()
public ResultSetInfo getResultSetInfo()
throws ResourceException
getResultSetInfo in interface ConnectionResourceException - this method always throws a NotSupportedException.Connection.getResultSetInfo()
public String submitNonBlocking(JPPFJob job)
throws Exception
submitNonBlocking in interface JPPFConnectionjob - the job to execute.
IllegalArgumentException - if the job is null or empty.
Exception - if an error occurs while submitting the request.
public String submitNonBlocking(JPPFJob job,
SubmissionStatusListener listener)
throws Exception
submitNonBlocking in interface JPPFConnectionjob - the job to execute.listener - an optional listener to receive submission status change notifications, may be null.
IllegalArgumentException - if the job is null or empty.
Exception - if an error occurs while submitting the request.
public void addSubmissionStatusListener(String submissionId,
SubmissionStatusListener listener)
addSubmissionStatusListener in interface JPPFConnectionsubmissionId - the id of the submission.listener - the listener to add.
public void removeSubmissionStatusListener(String submissionId,
SubmissionStatusListener listener)
removeSubmissionStatusListener in interface JPPFConnectionsubmissionId - the id of the submission.listener - the listener to remove.
public SubmissionStatus getSubmissionStatus(String submissionId)
throws Exception
getSubmissionStatus in interface JPPFConnectionsubmissionId - the id of the submission for which to get the status.
Exception - if an error occurs while submitting the request.
public List<JPPFTask> getSubmissionResults(String submissionId)
throws Exception
getSubmissionStatus(submissionId) has returned
either COMPLETE or
FAILED
getSubmissionResults in interface JPPFConnectionsubmissionId - the id of the submission for which to get the execution results.
Exception - if an error occurs while submitting the request.public Collection<String> getAllSubmissionIds()
getAllSubmissionIds in interface JPPFConnectionpublic boolean isClosed()
isClosed in interface JPPFConnectionpublic void setAvailable()
setAvailable in interface JPPFConnectionpublic JPPFManagedConnection getManagedConnection()
getManagedConnection in interface JPPFConnectionJPPFManagedConnection instance.public void setManagedConnection(JPPFManagedConnection conn)
setManagedConnection in interface JPPFConnectionconn - a JPPFManagedConnection instance.
public List<JPPFTask> waitForResults(String submissionId)
throws Exception
waitForResults in interface JPPFConnectionsubmissionId - the id of the job submission.
JPPFTask instances.
Exception - if any error occurs.
|
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||