com.rapidminer.operator.io
Class ResultWriter

java.lang.Object
  extended by com.rapidminer.operator.Operator
      extended by com.rapidminer.operator.io.ResultWriter
All Implemented Interfaces:
ConfigurationListener, PreviewListener, ParameterHandler, LoggingHandler

public class ResultWriter
extends Operator

This operator can be used at each point in an operator chain. It returns all input it receives without any modification. Every input object which implements the ResultObject interface (which is the case for almost all objects generated by the core RapidMiner operators) will write its results to the file specified by the parameter result_file. If the definition of this parameter is ommited then the global result file parameter with the same name of the ProcessRootOperator (the root of the process) will be used. If this file is also not specified the results are simply written to the console (standard out).

Author:
Ingo Mierswa

Field Summary
static java.lang.String PARAMETER_RESULT_FILE
          The parameter name for "Appends the descriptions of the input objects to this file.
 
Constructor Summary
ResultWriter(OperatorDescription description)
           
 
Method Summary
 IOObject[] apply()
          Use the ResultService to write the results of all input ResultObjects into the result file.
 java.lang.Class<?>[] getInputClasses()
          Returns an empty array.
 java.lang.Class<?>[] getOutputClasses()
          Returns an empty array.
 java.util.List<ParameterType> getParameterTypes()
          Returns a list of ParameterTypes describing the parameters of this operator.
 void processStarts()
          Called when the process starts.
 
Methods inherited from class com.rapidminer.operator.Operator
addError, addValue, addWarning, apply, checkDeprecations, checkForStop, checkIO, checkProperties, clearErrorList, cloneOperator, createExperimentTree, createExperimentTree, createFromXML, createMarkedExperimentTree, createMarkedProcessTree, createProcessTree, createProcessTree, getAddOnlyAdditionalOutput, getApplyCount, getDeliveredOutputClasses, getDeprecationInfo, getDesiredInputClasses, getEncoding, getErrorList, getExperiment, getInnerOperatorsXML, getInput, getInput, getInput, getInputDescription, getIOContainerForInApplyLoopBreakpoint, getIODescription, getLog, getName, getOperatorClassName, getOperatorDescription, getParameter, getParameterAsBoolean, getParameterAsColor, getParameterAsDouble, getParameterAsFile, getParameterAsFile, getParameterAsInputStream, getParameterAsInt, getParameterAsMatrix, getParameterAsString, getParameterList, getParameters, getParameterType, getParent, getProcess, getStartTime, getStatus, getUserDescription, getValue, getValues, getXML, hasBreakpoint, hasBreakpoint, hasInput, inApplyLoop, isDebugMode, isEnabled, isExpanded, isParallel, isParameterSet, log, logError, logNote, logWarning, performAdditionalChecks, processFinished, register, registerOperator, remove, rename, resume, setApplyCount, setBreakpoint, setEnabled, setExpanded, setInput, setListParameter, setOperatorParameters, setParameter, setParameters, setParent, setUserDescription, toString, unregisterOperator, writeXML
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

PARAMETER_RESULT_FILE

public static final java.lang.String PARAMETER_RESULT_FILE
The parameter name for "Appends the descriptions of the input objects to this file. If empty, use the general file defined in the process root operator."

See Also:
Constant Field Values
Constructor Detail

ResultWriter

public ResultWriter(OperatorDescription description)
Method Detail

apply

public IOObject[] apply()
                 throws OperatorException
Use the ResultService to write the results of all input ResultObjects into the result file.

Specified by:
apply in class Operator
Throws:
OperatorException

processStarts

public void processStarts()
                   throws OperatorException
Description copied from class: Operator
Called when the process starts. Resets all counters.

Overrides:
processStarts in class Operator
Throws:
OperatorException

getInputClasses

public java.lang.Class<?>[] getInputClasses()
Returns an empty array.

Specified by:
getInputClasses in class Operator

getOutputClasses

public java.lang.Class<?>[] getOutputClasses()
Returns an empty array.

Specified by:
getOutputClasses in class Operator

getParameterTypes

public java.util.List<ParameterType> getParameterTypes()
Description copied from class: Operator
Returns a list of ParameterTypes describing the parameters of this operator. The default implementation returns an empty list if no input objects can be retained and special parameters for those input objects which can be prevented from being consumed.

Specified by:
getParameterTypes in interface ParameterHandler
Overrides:
getParameterTypes in class Operator


Copyright © 2001-2009 by Rapid-I