org.weborganic.ox.tool
Class TransformCommand.TransformResult
java.lang.Object
org.weborganic.ox.tool.TransformCommand.TransformResult
- All Implemented Interfaces:
- XMLWritable, Result
- Enclosing class:
- TransformCommand
public final class TransformCommand.TransformResult
- extends Object
- implements Result
- Version:
- 28 October 2013
- Author:
- Christophe Lauret
TransformCommand.TransformResult
public TransformCommand.TransformResult(PackageData data)
toXML
public void toXML(XMLWriter xml)
throws IOException
- Specified by:
toXML
in interface XMLWritable
- Throws:
IOException
model
public final Model model()
- Specified by:
model
in interface Result
- Returns:
- The model used to generate that result.
data
public final PackageData data()
- Specified by:
data
in interface Result
- Returns:
- The ID of the data that has been processed.
time
public final long time()
- Specified by:
time
in interface Result
- Returns:
- The time it took to execute the command in milliseconds.
status
public final ResultStatus status()
- Specified by:
status
in interface Result
- Returns:
- The status of that result.
error
public Exception error()
- Specified by:
error
in interface Result
- Returns:
- Any error that may have occurred and caused the command to fail.
done
public final void done()
- Invoke this method when the result are ready to compute the time consistently.
setStatus
public final void setStatus(ResultStatus status)
- Parameters:
status
- the status to set
setError
public final void setError(Exception ex)
- Parameters:
ex
- the exception causing the error.