org.carrot2.text.clustering
Enum MultilingualClustering.LanguageAggregationStrategy

java.lang.Object
  extended by java.lang.Enum<MultilingualClustering.LanguageAggregationStrategy>
      extended by org.carrot2.text.clustering.MultilingualClustering.LanguageAggregationStrategy
All Implemented Interfaces:
Serializable, Comparable<MultilingualClustering.LanguageAggregationStrategy>
Enclosing class:
MultilingualClustering

public static enum MultilingualClustering.LanguageAggregationStrategy
extends Enum<MultilingualClustering.LanguageAggregationStrategy>

Defines how monolingual partial clusters will be combined to form final results.


Enum Constant Summary
FLATTEN_ALL
          Combines clusters created for all languages into one flat list.
FLATTEN_MAJOR_LANGUAGE
          Puts clusters generated for the largest language partition on the first level of the hierarchy.
FLATTEN_NONE
          Puts clusters corresponding to language names, e.g.
 
Method Summary
 String toString()
           
static MultilingualClustering.LanguageAggregationStrategy valueOf(String name)
          Returns the enum constant of this type with the specified name.
static MultilingualClustering.LanguageAggregationStrategy[] 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, valueOf
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Enum Constant Detail

FLATTEN_ALL

public static final MultilingualClustering.LanguageAggregationStrategy FLATTEN_ALL
Combines clusters created for all languages into one flat list. In this setting, the first level of the clusters hierarchy will contain labels in all input languages.


FLATTEN_MAJOR_LANGUAGE

public static final MultilingualClustering.LanguageAggregationStrategy FLATTEN_MAJOR_LANGUAGE
Puts clusters generated for the largest language partition on the first level of the hierarchy. Clusters generated for the other languages are placed in the "Other Languages" cluster appended at the end of the list.


FLATTEN_NONE

public static final MultilingualClustering.LanguageAggregationStrategy FLATTEN_NONE
Puts clusters corresponding to language names, e.g. English, German, Spanish, on the first level of the hierarchy. Each such cluster contains the actual clusters generated for documents in the corresponding language.

Method Detail

values

public static MultilingualClustering.LanguageAggregationStrategy[] 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 (MultilingualClustering.LanguageAggregationStrategy c : MultilingualClustering.LanguageAggregationStrategy.values())
    System.out.println(c);

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

valueOf

public static MultilingualClustering.LanguageAggregationStrategy 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

toString

public String toString()
Overrides:
toString in class Enum<MultilingualClustering.LanguageAggregationStrategy>


Copyright (c) Dawid Weiss, Stanislaw Osinski