Package cruise.umple.compiler
Class TestGenerator
java.lang.Object
cruise.umple.compiler.CodeGeneratorWithSubptions
cruise.umple.compiler.TestGenerator
- All Implemented Interfaces:
CodeGenerator
public class TestGenerator extends CodeGeneratorWithSubptions
-
Constructor Summary
Constructors Constructor Description TestGenerator()
-
Method Summary
Modifier and Type Method Description java.lang.String
addTranslate(java.lang.String key, java.lang.String value)
void
delete()
java.lang.String
dependencyInjection(UmpleClass uClass)
dependency injection for a classvoid
generate()
Allows independent code generation tools Different generators will do different things regarding where the files are put, etc.ILang
getLanguageFor(UmpleElement aElement)
UmpleModel
getModel()
Contains various aspects from an Umple file (.ump), such as classes, attributes, associations and methods.java.lang.String
getOutput()
java.util.Random
getRandom()
java.util.HashMap<java.lang.String,java.lang.String>
getTestingCredentialsLookUpMap()
java.lang.String
initializeModel(UmpleModel model)
initiate the whole model with minimum requirementsjava.lang.String
initiateClass(UmpleClass uClass)
class object initiationboolean
levelClasses()
dependency handling class levelingvoid
prepareDependency()
boolean
processDependencyNodes()
process Dependencies for each class and create dependency nodes for each dependencyvoid
resetInitializedObject()
resets initialized objects: use to control scope of objectsboolean
setModel(UmpleModel aModel)
Allows independent code generation tools Different generators will do different things regarding where the files are put, etc.boolean
setOutput(java.lang.String aOutput)
Allows independent code generation tools Different generators will do different things regarding where the files are put, etc.boolean
setRandom(java.util.Random aRandom)
boolean
setTestingCredentialsLookUpMap(java.util.HashMap<java.lang.String,java.lang.String> aTestingCredentialsLookUpMap)
java.lang.String
toString()
java.lang.String
translate(java.lang.String aString)
java.lang.String
translate(java.lang.String stirng, UmpleClass uClass)
int
traverseDependency(UmpleClass inClass)
java.lang.String
writeFile(UmpleClass aClass)
void
writeModelFile()
Methods inherited from class cruise.umple.compiler.CodeGeneratorWithSubptions
addSuboption, getSuboption, getSuboptions, getSuboptionValue, hasSuboption, hasSuboptions, indexOfSuboption, numberOfSuboptions, postpare, prepare, removeSuboption, setSuboption
-
Constructor Details
-
TestGenerator
public TestGenerator()
-
-
Method Details
-
setModel
Description copied from class:CodeGeneratorWithSubptions
Allows independent code generation tools Different generators will do different things regarding where the files are put, etc.- Specified by:
setModel
in interfaceCodeGenerator
- Overrides:
setModel
in classCodeGeneratorWithSubptions
-
setOutput
public boolean setOutput(java.lang.String aOutput)Description copied from class:CodeGeneratorWithSubptions
Allows independent code generation tools Different generators will do different things regarding where the files are put, etc.- Specified by:
setOutput
in interfaceCodeGenerator
- Overrides:
setOutput
in classCodeGeneratorWithSubptions
-
setRandom
public boolean setRandom(java.util.Random aRandom) -
setTestingCredentialsLookUpMap
public boolean setTestingCredentialsLookUpMap(java.util.HashMap<java.lang.String,java.lang.String> aTestingCredentialsLookUpMap) -
getModel
Contains various aspects from an Umple file (.ump), such as classes, attributes, associations and methods. Generated output is based off of what's contained in here. -
getOutput
public java.lang.String getOutput() -
getRandom
public java.util.Random getRandom() -
getTestingCredentialsLookUpMap
public java.util.HashMap<java.lang.String,java.lang.String> getTestingCredentialsLookUpMap() -
delete
public void delete()- Overrides:
delete
in classCodeGeneratorWithSubptions
-
translate
public java.lang.String translate(java.lang.String aString) -
addTranslate
public java.lang.String addTranslate(java.lang.String key, java.lang.String value) -
translate
-
prepareDependency
public void prepareDependency() -
processDependencyNodes
public boolean processDependencyNodes()process Dependencies for each class and create dependency nodes for each dependency -
writeFile
-
getLanguageFor
-
writeModelFile
public void writeModelFile() -
levelClasses
public boolean levelClasses()dependency handling class leveling -
traverseDependency
-
initiateClass
class object initiation -
resetInitializedObject
public void resetInitializedObject()resets initialized objects: use to control scope of objects -
initializeModel
initiate the whole model with minimum requirements -
dependencyInjection
dependency injection for a class -
generate
public void generate()Description copied from class:CodeGeneratorWithSubptions
Allows independent code generation tools Different generators will do different things regarding where the files are put, etc.- Specified by:
generate
in interfaceCodeGenerator
- Overrides:
generate
in classCodeGeneratorWithSubptions
-
toString
public java.lang.String toString()- Overrides:
toString
in classCodeGeneratorWithSubptions
-