|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Object | +--antsim.impl.RandomResourceSet
RandomResourceSet is a simple implementation of ResourceSet
which generates RandomResources. Each random resource has a generic
name, which is the string representing a random long value. Requests are obtained
by selecting randomly one of the resources stored in this ResourceSet
and by returning the string containing the resource name.
| Field Summary | |
static String |
PAR_SIZE
String name of the parameter used to determine the number of of resources contained in this resource set. |
| Fields inherited from interface antsim.ResourceSet |
NAME |
| Constructor Summary | |
RandomResourceSet(Factory factory,
String name)
Initializes a new random resource set. |
|
| Method Summary | |
void |
clear()
Restores the object to its initial state. |
List |
getResources()
Return an array containing the resources generated and stored in this ResourceSet. |
int |
size()
Return the number of resources generated and stored in this ResourceSet. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
public static final String PAR_SIZE
| Constructor Detail |
public RandomResourceSet(Factory factory,
String name)
factory - the factory to be used to read configuration arguments
and to create other configurable objectsname - the name that is associated to this instance in the
configuration file| Method Detail |
public void clear()
clear in interface Clearablepublic int size()
ResourceSet.
public List getResources()
ResourceSet.
getResources in interface ResourceSet
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||