com.tivoli.twg.engine
Class TWGRemoteTaskClients

java.lang.Object
  extended bycom.tivoli.twg.engine.TWGRemoteTaskClients

public class TWGRemoteTaskClients
extends java.lang.Object

This class maintains the list of clients for a task activation in a remote task server (i.e. running in a JVM besides the core engine's JVM). The clients that are off line will have an initial task status of either CLIENT_TASK_PENDING or CLIENT_TASK_FAILED_OFFLINE depending on how the task was activated. If this is a scheduled job configured to watch for off-line target systems to come on-line, then subsequent subtask activations will occur for those stations with them marked as online and started. So, for this activation, the task server should only be concerned with processing clients that are on-line and had the client task sucessfully started.


Method Summary
 java.util.Enumeration enumerateClients()
          Get an enumeration of the clients in this collection.
 TWGRemoteTaskActivation getActivation()
           
 TWGRemoteManagedObject getClient(long moid)
          Retrieve a TWGRemoteManagedObject from this collection or null if the specified ID is not included.
 void setClientTaskStatus(long moid, int status)
          Set the client task status on the specified client
 void setClientTaskStatus(TWGRemoteManagedObject rmo, int status)
          Set the client task status on the specified client
 int size()
          Get the number of clients in this collection.
 void stopClient(long moid, int status)
          Stop the client task on the specified client.
 void stopClient(TWGRemoteManagedObject rmo, int status)
          Stop the client task on the specified client
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getClient

public TWGRemoteManagedObject getClient(long moid)
Retrieve a TWGRemoteManagedObject from this collection or null if the specified ID is not included.

Returns:
TWGRemoteManagedObject or null if ID not found in collection.

enumerateClients

public java.util.Enumeration enumerateClients()
Get an enumeration of the clients in this collection.

Returns:
Enumeration

size

public int size()
Get the number of clients in this collection.

Returns:
int

getActivation

public TWGRemoteTaskActivation getActivation()

stopClient

public final void stopClient(long moid,
                             int status)
Stop the client task on the specified client. This causes a command to be sent back to the server so that the client service will be stopped.

Parameters:
moid - the ID of the remote managed object to stop the task on
status - final status to give the remote managed object for the task processing. Use one of the following constants from TWGTaskConstants for the status:
  • CLIENT_TASK_COMPLETE
  • CLIENT_TASK_FAILED_ERROR
  • CLIENT_TASK_FAILED_OFFLINE
  • CLIENT_TASK_INCOMPLETE

stopClient

public final void stopClient(TWGRemoteManagedObject rmo,
                             int status)
Stop the client task on the specified client

Parameters:
rmo - remote managed object to stop the task on
status - final status to give the remote managed object for the task processing. Use one of the following constants from TWGTaskConstants for the status:
  • CLIENT_TASK_COMPLETE
  • CLIENT_TASK_FAILED_ERROR
  • CLIENT_TASK_FAILED_OFFLINE
  • CLIENT_TASK_INCOMPLETE

setClientTaskStatus

public final void setClientTaskStatus(TWGRemoteManagedObject rmo,
                                      int status)
Set the client task status on the specified client

Parameters:
rmo - remote managed object to set the status on
status - final status to give the remote managed object for the task processing. Use one of the following constants from TWGTaskConstants for the status:
  • CLIENT_TASK_COMPLETE
  • CLIENT_TASK_FAILED_ERROR
  • CLIENT_TASK_FAILED_OFFLINE
  • CLIENT_TASK_INCOMPLETE

setClientTaskStatus

public final void setClientTaskStatus(long moid,
                                      int status)
Set the client task status on the specified client

Parameters:
moid - ID of remote managed object to set the status on
status - final status to give the remote managed object for the task processing. Use one of the following constants from TWGTaskConstants for the status:
  • CLIENT_TASK_COMPLETE
  • CLIENT_TASK_FAILED_ERROR
  • CLIENT_TASK_FAILED_OFFLINE
  • CLIENT_TASK_INCOMPLETE