public class JavaDependency
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
factoryLocation
The assumed package location of the JavaFactory factory, which is used
to create instances of complex (generic) types, or user-defined types.
|
Constructor and Description |
---|
JavaDependency()
Constructs this JavaDependency visitor.
|
Modifier and Type | Method and Description |
---|---|
void |
analyse(TestSuite testSuite)
Analyses the TestSuite looking for complex types in the inputs and
outputs of each tested Operation.
|
protected void |
analyseInput(Input input)
Analyses one Input parameter to determine whether it is of a complex
generic, or factory-created type.
|
protected void |
analyseOutput(Output output)
Analyses one Output parameter to determine whether it is of a complex
generic, or factory-created type.
|
java.util.List<java.lang.String> |
getImports()
Returns all the needed package locations as a List of Strings.
|
java.util.Set<java.lang.String> |
getSourcePackages()
Returns the user-defined source package names as a set of Strings.
|
java.lang.String |
getTargetPackage()
Returns the name of the user-defined target package.
|
boolean |
hasFactory()
Reports whether this JavaDependency detected the need for a Factory.
|
boolean |
hasFactoryInputs()
Reports whether this JavaDependency has detected a need to build
factory inputs.
|
boolean |
hasFactoryOutputs()
Reports whether this JavaDependency has detected a need to build
factory outputs.
|
boolean |
hasGenericInputs()
Reports whether this JavaDependency has detected a need to encode
generic inputs.
|
boolean |
hasGenericOutputs()
Reports whether this JavaDependency has detected a need to decode
generic outputs.
|
protected boolean |
isGeneric(java.lang.String type)
Tests whether the supplied model type is a generic type.
|
void |
useSourcePackage(java.lang.String packageInfo)
Adds a package path name to the set of package names for source files.
|
void |
useTargetPackage(java.lang.String packageInfo)
Sets the path name of the package for the generated target file.
|
public static java.lang.String factoryLocation
public JavaDependency()
public void analyse(TestSuite testSuite)
testSuite
- the TestSuite to be analysed.protected void analyseInput(Input input)
input
- the Input parameter.protected void analyseOutput(Output output)
output
- the Output parameter.protected boolean isGeneric(java.lang.String type)
type
- the model type, possibly containing [] generic brackets.public void useSourcePackage(java.lang.String packageInfo)
packageInfo
- the package location as a String.public void useTargetPackage(java.lang.String packageInfo)
packageInfo
- the package location as a String.public java.util.Set<java.lang.String> getSourcePackages()
public java.lang.String getTargetPackage()
public boolean hasFactory()
public boolean hasGenericInputs()
public boolean hasGenericOutputs()
public boolean hasFactoryInputs()
public boolean hasFactoryOutputs()
public java.util.List<java.lang.String> getImports()