org.knime.base.node.preproc.groupby
Enum ColumnNamePolicy

java.lang.Object
  extended by java.lang.Enum<ColumnNamePolicy>
      extended by org.knime.base.node.preproc.groupby.ColumnNamePolicy
All Implemented Interfaces:
Serializable, Comparable<ColumnNamePolicy>

public enum ColumnNamePolicy
extends Enum<ColumnNamePolicy>

This enum defines the different aggregation column name versions.

Author:
Tobias Koetter, University of Konstanz

Enum Constant Summary
AGGREGATION_METHOD_COLUMN_NAME
          Combines the aggregation method with the column name e.g.
COLUMN_NAME_AGGREGATION_METHOD
          Combines the column name with the aggregation method e.g.
KEEP_ORIGINAL_NAME
          Keeps the original column name.
 
Method Summary
 String createColumName(String origName, AggregationMethod aggrMethod)
           
static ColumnNamePolicy getDefault()
           
 String getLabel()
           
static ColumnNamePolicy getPolicy4Label(String label)
           
static String[] getPolicyLabels()
           
static ColumnNamePolicy valueOf(String name)
          Returns the enum constant of this type with the specified name.
static ColumnNamePolicy[] values()
          Returns an array containing the constants of this enum type, in the order they are declared.
 
Methods inherited from class java.lang.Enum
clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Enum Constant Detail

KEEP_ORIGINAL_NAME

public static final ColumnNamePolicy KEEP_ORIGINAL_NAME
Keeps the original column name.


AGGREGATION_METHOD_COLUMN_NAME

public static final ColumnNamePolicy AGGREGATION_METHOD_COLUMN_NAME
Combines the aggregation method with the column name e.g. Avg(col1).


COLUMN_NAME_AGGREGATION_METHOD

public static final ColumnNamePolicy COLUMN_NAME_AGGREGATION_METHOD
Combines the column name with the aggregation method e.g. col1(Avg).

Method Detail

values

public static ColumnNamePolicy[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:
for (ColumnNamePolicy c : ColumnNamePolicy.values())
    System.out.println(c);

Returns:
an array containing the constants of this enum type, in the order they are declared

valueOf

public static ColumnNamePolicy valueOf(String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)

Parameters:
name - the name of the enum constant to be returned.
Returns:
the enum constant with the specified name
Throws:
IllegalArgumentException - if this enum type has no constant with the specified name
NullPointerException - if the argument is null

getLabel

public String getLabel()
Returns:
the label of this column name policy

createColumName

public String createColumName(String origName,
                              AggregationMethod aggrMethod)
Parameters:
origName - the original name of the column
aggrMethod - the AggregationMethod to use
Returns:
the column name of the aggregation column

getPolicy4Label

public static ColumnNamePolicy getPolicy4Label(String label)
Parameters:
label - the label of the ColumnNamePolicy
Returns:
the ColumnNamePolicy with the given label

getPolicyLabels

public static String[] getPolicyLabels()
Returns:
the labels of all available ColumnNamePolicy options

getDefault

public static ColumnNamePolicy getDefault()
Returns:
the default ColumnNamePolicy


Copyright, 2003 - 2010. All rights reserved.
University of Konstanz, Germany.
Chair for Bioinformatics and Information Mining, Prof. Dr. Michael R. Berthold.
You may not modify, publish, transmit, transfer or sell, reproduce, create derivative works from, distribute, perform, display, or in any way exploit any of the content, in whole or in part, except as otherwise expressly permitted in writing by the copyright owner or as specified in the license file distributed with this product.