All Packages Class Hierarchy This Package Previous Next Index
Class jdsltools.testers.pqtester.PriorityQFactory
java.lang.Object
|
+----jdsltools.testers.GenericFactory
|
+----jdsltools.testers.pqtester.PriorityQFactory
- public class PriorityQFactory
- extends GenericFactory
Builds PriorityQueues.
MT_PQ Empty priority queue
ONE_TEN PQ with ten elements in it with keys 1-10
ONE_TEN Also represents the ten locators
RND_L Locator with a random key and element
BAD_L HeapLocator with a bad key
L_BAD HeapLocator with a bad container
THREE Locator with a key of 3
- Author:
- Marco da Silva (mds)
-
BAD_L
-
-
L_BAD
-
-
MT_PQ
-
-
ONE_TEN
-
-
RND_L
-
-
THREE
-
-
PriorityQFactory(String)
- The constructor of this factory takes the fully qualified name of the
class of the
PriorityQueue
-
PriorityQFactory(String, String)
-
-
generate(int, int)
- Generates a data structure based on the type and position key.
-
init(String)
- call to avoid null pointer exceptions, creates structures that take
parameters.
-
location(int)
- Returns the current container and a new location for that container
-
makeALocator(int)
-
-
setContainer(Object)
- Returns the current container.
MT_PQ
public static final int MT_PQ
RND_L
public static final int RND_L
BAD_L
public static final int BAD_L
L_BAD
public static final int L_BAD
THREE
public static final int THREE
ONE_TEN
public static final int ONE_TEN
PriorityQFactory
public PriorityQFactory(String structToBuild)
- The constructor of this factory takes the fully qualified name of the
class of the
PriorityQueue
- Parameters:
- structToBuild - The fully qualified name of the class to build.
PriorityQFactory
public PriorityQFactory(String structToBuild,
String arguments)
init
public void init(String arguments)
- call to avoid null pointer exceptions, creates structures that take
parameters.
generate
public TestStructure generate(int structure,
int location)
- Generates a data structure based on the type and position key.
- Overrides:
- generate in class GenericFactory
setContainer
public void setContainer(Object container)
- Returns the current container.
- Overrides:
- setContainer in class GenericFactory
location
public TestStructure location(int location)
- Returns the current container and a new location for that container
- Overrides:
- location in class GenericFactory
makeALocator
public Locator makeALocator(int key)
All Packages Class Hierarchy This Package Previous Next Index