public class GroovyCodeFactory extends AbstractCodeFactory
ICodeFactory.Parameter
Modifier and Type | Field and Description |
---|---|
static List<String> |
RESERVED_KEYWORDS |
LINE_DELIMITER
TRACE_MODULE_WRAPPER
Constructor and Description |
---|
GroovyCodeFactory() |
Modifier and Type | Method and Description |
---|---|
String |
classInstantiation(Class<?> clazz,
String[] parameters)
Create code to instantiate a java class.
|
String |
createFunctionWrapper(IEnvironment environment,
String moduleVariable,
Method method)
Create code for a wrapper function in the global namespace of the script engine.
|
String |
getSaveVariableName(String variableName)
Converts a given string to a save variable name for the target language.
|
createCommentedString, createFunctionCall, createKeywordHeader, createWrapper, getDefaultValue, getMethodAliases, getMethodNames, getPostExecutionCode, getPreExecutionCode
public String classInstantiation(Class<?> clazz, String[] parameters)
ICodeFactory
clazz
- class to instantiateparameters
- parameters used for class instantiationpublic String getSaveVariableName(String variableName)
ICodeFactory
variableName
- variable name candidatepublic String createFunctionWrapper(IEnvironment environment, String moduleVariable, Method method)
AbstractCodeFactory
environment
- environment instancemoduleVariable
- function name to be usedmethod
- method to refer to