com.rapidminer.operator
Class DefaultIODescription

java.lang.Object
  extended by com.rapidminer.operator.DefaultIODescription
All Implemented Interfaces:
IODescription

public class DefaultIODescription
extends java.lang.Object
implements IODescription

This class is a description of the (expected) input and (guaranteed) output classes of operators. It provides easy default implementations.

Author:
Simon Fischer, Ingo Mierswa

Field Summary
static int DELETE_UNUSED_INPUT
           
static int PASS_UNUSED_INPUT_TO_OUTPUT
           
 
Constructor Summary
DefaultIODescription(java.lang.Class[] input, java.lang.Class[] output)
          Assumes PASS_UNUSED_INPUT_TO_OUTPUT.
DefaultIODescription(java.lang.Class[] input, java.lang.Class[] output, int outputBehaviour)
          Constructs a new IODescription where all input and output classes are expected exactly once.
 
Method Summary
static boolean containsClass(java.lang.Class<?> c, java.lang.Class<?>[] oc)
          Returns true if oc contains a class which is a superclass of c.
 java.lang.Class<?>[] getInputClasses()
          Returns the classes that are expected as input.
 java.lang.Class<?>[] getOutputClasses(java.lang.Class<?>[] input, Operator operator)
          Returns the output classes dependent on the outputBehaviour PASS_UNUSED_INPUT_TO_OUTPUT:output classes are the classes used in the constructor plus those classes in input[] that were not consumed.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

PASS_UNUSED_INPUT_TO_OUTPUT

public static final int PASS_UNUSED_INPUT_TO_OUTPUT
See Also:
Constant Field Values

DELETE_UNUSED_INPUT

public static final int DELETE_UNUSED_INPUT
See Also:
Constant Field Values
Constructor Detail

DefaultIODescription

public DefaultIODescription(java.lang.Class[] input,
                            java.lang.Class[] output,
                            int outputBehaviour)
Constructs a new IODescription where all input and output classes are expected exactly once. Output is the minimum set of output classes, the real output classes are determined by the outputBehaviour. Both input and output may be null and may contain a class more than once.


DefaultIODescription

public DefaultIODescription(java.lang.Class[] input,
                            java.lang.Class[] output)
Assumes PASS_UNUSED_INPUT_TO_OUTPUT.

Method Detail

getInputClasses

public java.lang.Class<?>[] getInputClasses()
Description copied from interface: IODescription
Returns the classes that are expected as input.

Specified by:
getInputClasses in interface IODescription

getOutputClasses

public java.lang.Class<?>[] getOutputClasses(java.lang.Class<?>[] input,
                                             Operator operator)
                                      throws IllegalInputException
Description copied from interface: IODescription
Returns the output classes dependent on the outputBehaviour In either case the output classes precede the unused input classes. Their order is conserved.

Specified by:
getOutputClasses in interface IODescription
Throws:
IllegalInputException

containsClass

public static boolean containsClass(java.lang.Class<?> c,
                                    java.lang.Class<?>[] oc)
Returns true if oc contains a class which is a superclass of c.



Copyright © 2001-2009 by Rapid-I