api
Class Argument

java.lang.Object
  extended by api.Argument
All Implemented Interfaces:
java.io.Serializable

public class Argument
extends java.lang.Object
implements java.io.Serializable

Result object generated by a task, destined for a successor object or the client

See Also:
Serialized Form

Constructor Summary
Argument(TaskId creatorId, java.lang.Object value)
          Constructor for Result class with no successor.
Argument(TaskId creatorId, TaskId successorId, int successorInputIndex, java.lang.Object value)
          Constructor for Result class
 
Method Summary
 TaskId getCreatorId()
          Gets the id of the creator of this result
 TaskId getSuccessorId()
          Gets the id of the successor task.
 int getSuccessorInputIndex()
          Gets the input index of the successor
 java.lang.Object getValue()
          Gets the value stored in the result
 boolean hasSuccesor()
          Method for determining if this Result object has a successor
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Argument

public Argument(TaskId creatorId,
                TaskId successorId,
                int successorInputIndex,
                java.lang.Object value)
Constructor for Result class

Parameters:
creatorId - id of the task that created the result
successorId - id of the successor task. null if there is no successor.
successorInputIndex - input index for the successor. this value is not used if the successor id is null.
value - the value of the result

Argument

public Argument(TaskId creatorId,
                java.lang.Object value)
Constructor for Result class with no successor.

Parameters:
creatorId - id of the task that created the result
value - the value of the result
Method Detail

hasSuccesor

public boolean hasSuccesor()
Method for determining if this Result object has a successor

Returns:
true if this Result object has a successor, false otherwise

getSuccessorInputIndex

public int getSuccessorInputIndex()
Gets the input index of the successor

Returns:
the input index of the successor

getCreatorId

public TaskId getCreatorId()
Gets the id of the creator of this result

Returns:
the id of the creator of this result

getSuccessorId

public TaskId getSuccessorId()
Gets the id of the successor task. This value can be null if there is no successor.

Returns:
the id of the successor task. This value can be null if there is no successor.

getValue

public java.lang.Object getValue()
Gets the value stored in the result

Returns:
the value stored in the result