ADK CVS

tryllian.afc.task.group
Class JoinGroupTask

java.lang.Object
  extended bytryllian.afc.task.AbstractTask
      extended bytryllian.afc.task.DefaultTask
          extended bytryllian.afc.task.group.AbstractGroupTask
              extended bytryllian.afc.task.group.JoinGroupTask
All Implemented Interfaces:
java.util.EventListener, MessageHandler, java.io.Serializable, Task

public class JoinGroupTask
extends tryllian.afc.task.group.AbstractGroupTask

Task that lets this agent join a Group. This Task sends a request to the JNDI System Agent requesting it to join a group:
request : join-group ( [ <parent-name>, ] <group-name> )

This request (and this Task) can only be expected to succeed if the specified group exists.

Joining a Group is idempotent.

See Also:
Serialized Form

Field Summary
 
Fields inherited from class tryllian.afc.task.AbstractTask
NL
 
Fields inherited from interface tryllian.afc.task.Task
EMPTY_FINISH_VALUE, FORCED_FINISH_FAILURE, NO_TIME_OUT, TASK_TIMED_OUT
 
Constructor Summary
JoinGroupTask(java.lang.String groupName)
          Create a Task that lets the agent join a top-level Group.
JoinGroupTask(java.lang.String parentName, java.lang.String groupName)
          Create a Task that lets the agent join a Group relative to another.
 
Method Summary
protected  tryllian.afc.task.group.GroupName getGroupName()
           
 void handleMessage(IncomingMessage message)
          Implemented to process the request reply messages.
protected  void taskStarted()
          Implemented to create and send the request.
 
Methods inherited from class tryllian.afc.task.DefaultTask
addFinishingTask, addTask, getSubtasks, handleHeartbeat, propagateHeartbeat
 
Methods inherited from class tryllian.afc.task.AbstractTask
addTaskListener, fail, fail, finish, finish, finish, forceFinish, forceFinish, getAgentContext, getFinishValue, getState, getSupertask, getTimeOut, heartbeatReceived, logException, messageReceived, removeTaskListener, setAgentContext, setFinishValue, setTimeOut, succeed, succeed, taskAdded, taskEnded, taskRemoved
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JoinGroupTask

public JoinGroupTask(java.lang.String groupName)
Create a Task that lets the agent join a top-level Group.


JoinGroupTask

public JoinGroupTask(java.lang.String parentName,
                     java.lang.String groupName)
Create a Task that lets the agent join a Group relative to another.

Method Detail

taskStarted

protected void taskStarted()
Implemented to create and send the request.

Overrides:
taskStarted in class AbstractTask

handleMessage

public void handleMessage(IncomingMessage message)
Implemented to process the request reply messages.

Overrides:
handleMessage in class AbstractTask

getGroupName

protected tryllian.afc.task.group.GroupName getGroupName()

Copyright 2005, Tryllian Solutions B.V.