uk.org.ogsadai.client.toolkit.activity
Class RequestComponent

java.lang.Object
  |
  +--uk.org.ogsadai.client.toolkit.activity.RequestComponent
Direct Known Subclasses:
Activity, Composite

public abstract class RequestComponent
extends java.lang.Object

Superclass for components of a request.

Author:
The OGSA-DAI Team.

Constructor Summary
RequestComponent()
           
 
Method Summary
protected abstract  void addOutputs(java.util.Map allOutputs)
          Adds the outputs of this component to the given hash map.
protected abstract  java.lang.String generateXML()
          Generates the XML representing the activity.
protected  ResourceID getDataResourceID()
          Returns the resource ID of the data service resource executing this activity, or null if there is no associated resource.
protected  Stub getDataServiceStub()
          Returns the DataService object executing this activity, or null if there is no associated service.
 java.lang.String getName()
          Gets the activity name.
protected  void setDataResourceID(ResourceID id)
          Sets the ResourceID object which this activity is being executed with.
protected  void setDataServiceStub(Stub stub)
          Sets the DataService object which this activity is being executed with.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

RequestComponent

public RequestComponent()
Method Detail

getName

public java.lang.String getName()
Gets the activity name. Each activity instance will have a unique name.

Returns:
activity name

getDataResourceID

protected ResourceID getDataResourceID()
Returns the resource ID of the data service resource executing this activity, or null if there is no associated resource. This method may be called by activities which need to know the service object.

Returns:
the resource ID.

setDataResourceID

protected void setDataResourceID(ResourceID id)
Sets the ResourceID object which this activity is being executed with. If there is exactly one resource then this method need not be called, and the ResourceID object will be null.

Parameters:
id - the resource ID

getDataServiceStub

protected Stub getDataServiceStub()
Returns the DataService object executing this activity, or null if there is no associated service. This method may be called by activities which need to know the service object.

Returns:
the DataService object

setDataServiceStub

protected void setDataServiceStub(Stub stub)
Sets the DataService object which this activity is being executed with. If there is no service (i.e. the Activity Engine is executing in a stand-alone environment) then this method need not be called, and the DataService object will be null.

Parameters:
stub - the service object

generateXML

protected abstract java.lang.String generateXML()
Generates the XML representing the activity. This XML can then be inserted into a perform document that is sent to a data service.

Returns:
the XML for the activity

addOutputs

protected abstract void addOutputs(java.util.Map allOutputs)
Adds the outputs of this component to the given hash map.

Parameters:
allOutputs -