com.bigdata.btree.keys
Enum CollatorEnum

java.lang.Object
  extended by java.lang.Enum<CollatorEnum>
      extended by com.bigdata.btree.keys.CollatorEnum
All Implemented Interfaces:
Serializable, Comparable<CollatorEnum>

public enum CollatorEnum
extends Enum<CollatorEnum>

Type-safe enumeration of collators that may be configured.

Version:
$Id: CollatorEnum.java 2265 2009-10-26 12:51:06Z thompsonbry $
Author:
Bryan Thompson

Enum Constant Summary
ASCII
          A configuration option to force the interpretation of Unicode text as ASCII (only the low byte is considered).
ICU
          ICU is the basis for the Unicode support in the JDK and also supports compressed sort keys, which can be a big savings in an index.
ICU4JNI
          A JNI plugin for ICU (native code for faster generation of sort keys).
JDK
          The JDK bundles support for generating Unicode sort keys, but that support does NOT include compressed sort keys.
 
Method Summary
static CollatorEnum valueOf(String name)
          Returns the enum constant of this type with the specified name.
static CollatorEnum[] 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

JDK

public static final CollatorEnum JDK
The JDK bundles support for generating Unicode sort keys, but that support does NOT include compressed sort keys.


ICU

public static final CollatorEnum ICU
ICU is the basis for the Unicode support in the JDK and also supports compressed sort keys, which can be a big savings in an index.


ICU4JNI

public static final CollatorEnum ICU4JNI
A JNI plugin for ICU (native code for faster generation of sort keys).

TODO:
this is notionally faster but I have never made it work myself, or at least I have not found it to be stable in my experience.

ASCII

public static final CollatorEnum ASCII
A configuration option to force the interpretation of Unicode text as ASCII (only the low byte is considered). This option can be useful when you know that your data is not actually Unicode and offers a substantial performance benefit in such cases.

Method Detail

values

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

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

valueOf

public static CollatorEnum 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


Copyright © 2006-2009 SYSTAP, LLC. All Rights Reserved.