public class TemplateParameterDescriptor extends ToolParameterDescriptor
DefaultParameterDescriptor.XStreamConverter
parameterType
Constructor and Description |
---|
TemplateParameterDescriptor() |
TemplateParameterDescriptor(String name,
Class<?> type) |
TemplateParameterDescriptor(TemplateParameterDescriptor object)
Copy constructor
|
TemplateParameterDescriptor(ToolParameterDescriptor object)
Conversion constructor from a regular parameter
|
Modifier and Type | Method and Description |
---|---|
void |
addParameterDescriptor(ToolParameterDescriptor descriptor)
Adds a parameter descriptor to this template parameter
|
String |
executeTemplate(Map<String,Object> params)
Transforms (or executes) the template of this instance given a set of parameters.
|
TemplateContext |
getLastContext()
Returns the last scripting context resulted from the execution of the scripting engine
|
File |
getOutputFile() |
List<ToolParameterDescriptor> |
getParameterDescriptors()
Returns the list of the parameter descriptors of this instance
|
TemplateFile |
getTemplate()
Returns the template of this object.
|
void |
removeParameterDescriptor(ToolParameterDescriptor descriptor)
Removes a parameter descriptor from this template parameter
|
void |
setOutputFile(File outputFile)
Sets the output file of this template parameter, after the template is parsed.
|
void |
setTemplate(TemplateFile template)
Sets the template of this parameter
|
void |
setTemplateEngine(TemplateEngine engine)
Sets the scripting engine for this parameter and associates its template, if any,
with the engine.
|
getAttribute, getDefaultTypedValue, getParameterType, isParameter, isTemplateAfter, isTemplateBefore, isTemplateParameter, setAttribute, setParameterType
getAlias, getCondition, getConverterClass, getDataMemberDescriptors, getDataType, getDefaultValue, getDescription, getDomConverterClass, getFormat, getInterval, getItemAlias, getLabel, getName, getPattern, getRasterDataNodeClass, getStructureMemberDescriptors, getUnit, getValidatorClass, getValueSet, isDeprecated, isNotEmpty, isNotNull, isSimple, isStructure, isStructure, setAlias, setCondition, setConverterClass, setDataType, setDefaultValue, setDeprecated, setDescription, setDomConverterClass, setFormat, setInterval, setItemAlias, setLabel, setName, setNotEmpty, setNotNull, setPattern, setRasterDataNodeClass, setUnit, setValidatorClass, setValueSet
public TemplateParameterDescriptor()
public TemplateParameterDescriptor(ToolParameterDescriptor object)
object
- The source parameterpublic TemplateParameterDescriptor(TemplateParameterDescriptor object)
object
- The template parameter to be copied.public void addParameterDescriptor(ToolParameterDescriptor descriptor)
public void removeParameterDescriptor(ToolParameterDescriptor descriptor)
public List<ToolParameterDescriptor> getParameterDescriptors()
public void setTemplateEngine(TemplateEngine engine) throws TemplateException
engine
- The scripting engineTemplateException
public TemplateContext getLastContext()
public void setTemplate(TemplateFile template) throws TemplateException
template
- The template objectTemplateException
public TemplateFile getTemplate()
public String executeTemplate(Map<String,Object> params) throws TemplateException
params
- A collection of parameter valuesTemplateException
public File getOutputFile()
public void setOutputFile(File outputFile)
outputFile
- output file of this template parameterCopyright © 2014–2016 European Space Agency (ESA). All rights reserved.