public class ToolResult extends ResultSetResult
JstacsTool
.
In addition to a standard ResultSetResult
, this class stores some supplementary information
like the parameters of the tool's run, the name of the tool, and the time the tool's run finished.list
comment, datatype, name
Constructor and Description |
---|
ToolResult(StringBuffer representation)
The standard constructor for the interface
Storable . |
ToolResult(String name,
String comment,
ResultSet annotation,
ResultSet result,
ParameterSet toolParameters,
String toolName,
Date finished)
Creates a new
ToolResult with most arguments identical to those of a ListResult . |
Modifier and Type | Method and Description |
---|---|
protected void |
appendFurtherInfos(StringBuffer buf)
This method can be used in the method
Storable.toXML() to extract
further information (name, comment, datatype). |
protected void |
extractFurtherInfos(StringBuffer representation)
This method can be used in the constructor with parameter
StringBuffer to
extract the further information. |
Date |
getFinishedDate()
Returns the date and time, when the tool's run resulting in this
ToolResult finished. |
String |
getToolName()
Returns the name of the tool (see
JstacsTool.getToolName() ) used to create these results. |
ParameterSet |
getToolParameters()
Returns the tool's parameters that have been used to create the results stored in this
ToolResult . |
void |
setFromStoredParameters(ParameterSet other)
Sets the values of all parameters in
other to those stored in the internal parameters
that have been supplied upon construction. |
getAnnotation, getExport, getNumberOfResultSets, getRawResult, getValue, getXMLTag, print, setExport, sort, toString
checkDatatype, createResult, getOriginalName, isCastableResult, isComparableResult, rename
getComment, getDatatype, getName, toXML
public ToolResult(String name, String comment, ResultSet annotation, ResultSet result, ParameterSet toolParameters, String toolName, Date finished)
ToolResult
with most arguments identical to those of a ListResult
.
In addition, it stores the name of the creating tool, the parameters for the tool's run (see JstacsTool.getToolParameters()
),
and the date/time of result creation.name
- the name of the resultcomment
- a comment on the meaning of the resultannotation
- optional annotation, may be null
result
- the set of all results of the tool's runtoolParameters
- the (filled) parameters of the tool's runtoolName
- the name of the toolfinished
- the date/time the tool's run finished and results were createdpublic ToolResult(StringBuffer representation) throws NonParsableException
Storable
.
Creates a new ToolResult
from the corresponding XML
representation.representation
- the XML representation as StringBuffer
NonParsableException
- if the StringBuffer
representation
could
not be parsedpublic String getToolName()
JstacsTool.getToolName()
) used to create these results.public Date getFinishedDate()
ToolResult
finished.protected void appendFurtherInfos(StringBuffer buf)
AnnotatedEntity
Storable.toXML()
to extract
further information (name, comment, datatype).appendFurtherInfos
in class ListResult
buf
- a XML representation of the main information as
StringBuffer
Storable.toXML()
protected void extractFurtherInfos(StringBuffer representation) throws NonParsableException
AnnotatedEntity
StringBuffer
to
extract the further information.extractFurtherInfos
in class ListResult
representation
- a XML represenation of the main information as
StringBuffer
NonParsableException
- if the XML representation is not parsableAnnotatedEntity.AnnotatedEntity(StringBuffer)
public void setFromStoredParameters(ParameterSet other)
other
to those stored in the internal parameters
that have been supplied upon construction. Works successfully only if both parameter sets have an identical structure, which
should be the case if both have been created from the same tool's JstacsTool.getToolParameters()
method.other
- the parameters to be filledToolResult(String, String, ResultSet, ResultSet, ParameterSet, String, Date)
public ParameterSet getToolParameters()
ToolResult
.JstacsTool.getToolParameters()