|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.symcomp.scscp.Computation
public class Computation
A Computation is a container that holds the request, the state and some meta-data of a computation.
It is internally used in SCSCPClient. There is no need to manually deal with these objects.
| Field Summary | |
|---|---|
protected CookieStore |
cookies
|
protected java.util.Date |
finishedAt
|
protected java.lang.Integer |
lock
|
protected ProcedureCall |
procedureCall
|
protected ProcedureDone |
procedureDone
|
protected java.util.Date |
receivedAt
|
protected OpenMathBase |
request
|
protected OpenMathBase.ENCODINGS |
requestEncoding
|
protected OpenMathBase |
result
|
protected java.util.Date |
startedAt
|
protected java.lang.Integer |
state
|
protected CASClient |
system
|
protected java.lang.String |
token
|
| Constructor Summary | |
|---|---|
Computation()
|
|
Computation(CASClient system,
java.lang.String token,
OpenMathBase command)
|
|
| Method Summary | |
|---|---|
void |
computing()
|
void |
error(OpenMathBase result)
|
void |
error(java.lang.String result)
|
void |
finished(OpenMathBase result)
|
void |
finished(java.lang.String result)
|
java.util.Date |
getFinishedAt()
|
ProcedureCall |
getProcedureCall()
Get the computation as (OpenMath encoded) procedure call |
ProcedureDone |
getProcedureDone()
Get the result as (OpenMath encoded) ProcedureDone |
java.util.Date |
getReceivedAt()
|
OpenMathBase |
getRequest()
|
OpenMathBase.ENCODINGS |
getRequestEncoding()
|
OpenMathBase |
getResult()
|
void |
getReturn()
Request the return type of the Procedure call |
java.util.Date |
getStartedAt()
|
java.lang.Integer |
getState()
|
CASClient |
getSystem()
|
java.lang.String |
getToken()
|
void |
hasReturn(ProcedureCall.OPTION_RETURN which)
Check whether the Procedure call has a particular return type |
boolean |
isReady()
|
void |
receivedMessage(OpenMathBase b0)
Calls setProcedureCall(ProcedureCall p) or
setProcedureDone(ProcedureDone p), depending on the type of message b is. |
void |
receivedMessage(OpenMathBase b0,
OpenMathBase.ENCODINGS enc)
Calls setProcedureCall(ProcedureCall p) or
setProcedureDone(ProcedureDone p), depending on the type of message b is. |
void |
receivedMessage(java.lang.String m)
Calls setProcedureCall(ProcedureCall p) or
setProcedureDone(ProcedureDone p), depending on the type of message b is. |
void |
setCookieStore(CookieStore c)
|
void |
setFinishedAt(java.util.Date finishedAt)
|
void |
setProcedureCall(ProcedureCall p)
|
void |
setProcedureDone(ProcedureDone p)
|
void |
setReceivedAt(java.util.Date receivedAt)
|
void |
setRequest(OpenMathBase request)
|
void |
setResult(OpenMathBase result)
|
void |
setResult(java.lang.String result)
|
void |
setReturn(ProcedureCall.OPTION_RETURN which)
Set the return type of the Procedure call: cookie, option or nothing |
void |
setStartedAt(java.util.Date startedAt)
|
void |
setState(java.lang.Integer state)
|
void |
setSystem(CASClient s)
|
void |
setToken(java.lang.String token)
|
void |
waitForResult()
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected ProcedureCall procedureCall
protected ProcedureDone procedureDone
protected OpenMathBase result
protected OpenMathBase request
protected CookieStore cookies
protected java.lang.String token
protected java.util.Date receivedAt
protected java.util.Date startedAt
protected java.util.Date finishedAt
protected OpenMathBase.ENCODINGS requestEncoding
protected java.lang.Integer state
protected CASClient system
protected final java.lang.Integer lock
| Constructor Detail |
|---|
public Computation()
public Computation(CASClient system,
java.lang.String token,
OpenMathBase command)
| Method Detail |
|---|
public void setCookieStore(CookieStore c)
public void setSystem(CASClient s)
public void computing()
public void finished(OpenMathBase result)
public void finished(java.lang.String result)
public void error(OpenMathBase result)
public void error(java.lang.String result)
public void waitForResult()
public boolean isReady()
public java.lang.String getToken()
public void setToken(java.lang.String token)
public java.util.Date getReceivedAt()
public void setReceivedAt(java.util.Date receivedAt)
public java.util.Date getStartedAt()
public void setStartedAt(java.util.Date startedAt)
public java.util.Date getFinishedAt()
public void setFinishedAt(java.util.Date finishedAt)
public java.lang.Integer getState()
public void setState(java.lang.Integer state)
public OpenMathBase.ENCODINGS getRequestEncoding()
public CASClient getSystem()
public void setReturn(ProcedureCall.OPTION_RETURN which)
public void getReturn()
public void hasReturn(ProcedureCall.OPTION_RETURN which)
public ProcedureCall getProcedureCall()
public ProcedureDone getProcedureDone()
throws OpenMathException
OpenMathException - if something went wrongpublic OpenMathBase getResult()
public void setResult(java.lang.String result)
public void setResult(OpenMathBase result)
public OpenMathBase getRequest()
public void setRequest(OpenMathBase request)
public void setProcedureCall(ProcedureCall p)
public void setProcedureDone(ProcedureDone p)
public void receivedMessage(OpenMathBase b0,
OpenMathBase.ENCODINGS enc)
throws OpenMathException
setProcedureCall(ProcedureCall p) or
setProcedureDone(ProcedureDone p), depending on the type of message b is.
b0 - the message, enc the encoding the message was in (or null)
OpenMathException - if the message has the wrong format
public void receivedMessage(OpenMathBase b0)
throws OpenMathException
setProcedureCall(ProcedureCall p) or
setProcedureDone(ProcedureDone p), depending on the type of message b is.
b0 - the message
OpenMathException - if the message has the wrong format
public void receivedMessage(java.lang.String m)
throws OpenMathException
setProcedureCall(ProcedureCall p) or
setProcedureDone(ProcedureDone p), depending on the type of message b is.
b0 - the message as a string
OpenMathException - if the message has the wrong format
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||