|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Object
|
+--uk.org.ogsadai.client.toolkit.activity.RequestComponent
|
+--uk.org.ogsadai.client.toolkit.activity.Activity
|
+--uk.org.ogsadai.client.toolkit.activity.transform.DataStore
A data store to provide data for other activities. There are two ways in which it can be used:
setItems, addItem or addItems
methods (to force the data store to behave in the former manner); or the
setInput method (to force the data store to behave in
the latter manner).
Note that data can be directly provided in the form of
Objects. These are interpreted as data items by using
the return value of their toString() method.
| Constructor Summary | |
DataStore()
Initialise a new data store. |
|
DataStore(ActivityOutput input)
Initialise a new data store to act as a buffer of data from another activity's output. |
|
DataStore(java.util.List items)
Initialise a new data store to act as a cache of data items, initially containing the given items. |
|
| Method Summary | |
void |
addItem(java.lang.Object item)
Add an item to the list of items in the data store. |
void |
addItems(java.util.List items)
Add a list of items to the existing list of items in the data store |
protected java.lang.String |
generateXML()
Generate a perform document with appropriate parameters. |
ActivityOutput |
getOutput()
Gets the activity's only output. |
void |
setInput(ActivityOutput input)
Specify the output of another activity, from which the data will be obtained. |
void |
setItems(java.util.List items)
Specify the list of items which constitute this data store. |
| Methods inherited from class uk.org.ogsadai.client.toolkit.activity.Activity |
addInput, addOutput, addOutputs, getDataResourceID, getDataServiceStub, getInputParameters, getOutputParameters, getOutputs, replaceSpecialCharacters, setDataResourceID, setDataServiceStub, setInput |
| Methods inherited from class uk.org.ogsadai.client.toolkit.activity.RequestComponent |
getName |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public DataStore()
setItems,
addItem or addItems methods must be used
to cause the data store to behave as a cache of data items; or the
setInput method must be used to cause the data store
to behave as a buffer of data from another activity.
public DataStore(java.util.List items)
items - a list of Objects to be used in the data storepublic DataStore(ActivityOutput input)
input - the output from another activity| Method Detail |
public void setInput(ActivityOutput input)
input - the output from another activity
java.lang.IllegalArgumentException - if the argument is null
java.lang.IllegalStateException - if some data items have already been providedpublic void setItems(java.util.List items)
items - the list of items
java.lang.IllegalStateException - if the output of another activity has already been specifiedpublic void addItem(java.lang.Object item)
item - the item to add
java.lang.IllegalStateException - if the output of another activity has already been specifiedpublic void addItems(java.util.List items)
items - the items to add
java.lang.IllegalStateException - if the output of another activity has already been specifiedpublic ActivityOutput getOutput()
protected java.lang.String generateXML()
generateXML in class Activityjava.lang.IllegalStateException - if no input or no items have been provided
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||