|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.waveset.object.PersistentObject
com.waveset.object.TaskResult
public class TaskResult
This class represents the result of an individual operation within the execution of a larger task.
Previously, a TaskInstance contained its entire WavesetResult. However, this made the task instance large, and this meant that the entire (increasingly large) task instance had to be serialized and re-written into the repository in order to add and persist another individual result. By separating the result from the task, and by separating each item of the result, we can make it easier to incrementally update (and to incrementally display) large results.
An instance ordinarily contains a WavesetResult
object.
Nested Class Summary |
---|
Nested classes/interfaces inherited from class com.waveset.object.PersistentObject |
---|
PersistentObject.Comparator, PersistentObject.InitialInstance |
Field Summary | |
---|---|
static java.lang.String |
code_id
|
static java.lang.String |
EL_TASKREF
|
static java.lang.String |
FROM_SEQUENCE
Option key to specify the start of a sequence number range. |
static java.lang.String |
JUST_LIST_THEM
Option key to specify the end of a sequence number range. |
static java.lang.String |
TO_SEQUENCE
Option key to specify the end of a sequence number range. |
Fields inherited from class com.waveset.object.PersistentObject |
---|
INITIAL_OBJECT_VERSION |
Constructor Summary | |
---|---|
TaskResult()
Create an empty task result, ready to be filled. |
|
TaskResult(org.w3c.dom.Element e)
Build a work item from its XML representation. |
|
TaskResult(com.waveset.object.TaskInstance task)
Build a result for one part of a task. |
|
TaskResult(com.waveset.object.TaskInstance task,
int sequence)
Build a result for one part of a task. |
Method Summary | |
---|---|
static AttributeCondition[] |
forTask(java.lang.String taskId)
|
static AttributeCondition[] |
forTask(com.waveset.object.TaskInstance ti)
|
static java.lang.String |
getName(java.lang.String taskId,
int sequence)
|
static java.lang.String |
getName(com.waveset.object.TaskInstance task,
int sequence)
|
static java.lang.String |
getNameBase(java.lang.String taskId)
|
static java.lang.String |
getParentTaskId(java.lang.String taskResultName)
|
WavesetResult |
getResult()
|
int |
getSequence()
|
com.waveset.object.TaskInstance |
getTask()
Get the resolved TaskInstance to which this result belongs. |
com.waveset.object.ObjectRef |
getTaskRef()
Get a reference to the TaskInstance that contains our WorkflowCase. |
com.waveset.object.Type |
getType()
Returns the associated Type object. |
java.util.List |
listQueryableAttributes()
|
java.util.List |
listSummaryAttributes()
Returns the complete list of defined attributes
that this type of persistent object exposes as summary attributes
(regardless of whether this particular object has a value for each). |
void |
setResult(WavesetResult result)
Embed a WavesetResult in this extended result. |
void |
setSequence(int sequence)
Set the sequence number for this extended result. |
Methods inherited from class java.lang.Object |
---|
getClass, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static final java.lang.String code_id
public static final java.lang.String EL_TASKREF
public static final java.lang.String FROM_SEQUENCE
public static final java.lang.String JUST_LIST_THEM
public static final java.lang.String TO_SEQUENCE
Constructor Detail |
---|
public TaskResult()
public TaskResult(org.w3c.dom.Element e) throws com.waveset.util.WavesetException
com.waveset.util.WavesetException
public TaskResult(com.waveset.object.TaskInstance task)
public TaskResult(com.waveset.object.TaskInstance task, int sequence)
Method Detail |
---|
public static AttributeCondition[] forTask(java.lang.String taskId)
public static AttributeCondition[] forTask(com.waveset.object.TaskInstance ti)
public static java.lang.String getName(java.lang.String taskId, int sequence)
public static java.lang.String getName(com.waveset.object.TaskInstance task, int sequence)
public static java.lang.String getNameBase(java.lang.String taskId)
public static java.lang.String getParentTaskId(java.lang.String taskResultName) throws com.waveset.util.InvalidArgument
null
if it cannot parse
an id from the task result name.
In effect, an inverse of getName()
.
com.waveset.util.InvalidArgument
getName(String,int)
public WavesetResult getResult()
WavesetResult
from this extended result.public int getSequence()
public com.waveset.object.TaskInstance getTask() throws com.waveset.util.WavesetException
com.waveset.util.WavesetException
public com.waveset.object.ObjectRef getTaskRef()
public com.waveset.object.Type getType()
getType
in class PersistentObject
public java.util.List listQueryableAttributes()
listQueryableAttributes
in class PersistentObject
defined attributes
that this type of persistent object exposes as queryable attributes
(regardless of whether this particular object has a value for each).
Any subclass of PersistentObject that overrides this method
should first invoke super.listQueryableAttributes()
to ensure that the subclass includes queryable attributes
that are common to all PersistentObjects.
public java.util.List listSummaryAttributes()
PersistentObject
defined attributes
that this type of persistent object exposes as summary attributes
(regardless of whether this particular object has a value for each).
Any subclass of PersistentObject that overrides this method
should first invoke super.listSummaryAttributes()
to ensure that the subclass includes summary attributes
that are common to all PersistentObjects.
Any subclass that overrides this implementation must also consider the length of the summary string that will be generated from these attributes.
listSummaryAttributes
in class PersistentObject
defined attributes
that this type of persistent object exposes as summary attributes
(regardless of whether this particular object has a value for each).
Any subclass of PersistentObject that overrides this method
should first invoke super.listSummaryAttributes()
to ensure that the subclass includes summary attributes
that are common to all PersistentObjects.
Constants.MAX_SUMMARY_STRING_LENGTH
,
PersistentObject.getSummaryString()
public void setResult(WavesetResult result)
WavesetResult
in this extended result.
This allows the same TaskResult
object
to be re-used.
public void setSequence(int sequence)
This mutator allows the same TaskResult
object
to be re-used.
|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |