opennlp.tools.tokenize
Enum Detokenizer.DetokenizationOperation

java.lang.Object
  extended by java.lang.Enum<Detokenizer.DetokenizationOperation>
      extended by opennlp.tools.tokenize.Detokenizer.DetokenizationOperation
All Implemented Interfaces:
Serializable, Comparable<Detokenizer.DetokenizationOperation>
Enclosing interface:
Detokenizer

public static enum Detokenizer.DetokenizationOperation
extends Enum<Detokenizer.DetokenizationOperation>

This enum contains an operation for every token to merge the tokens together to their detokenized form.


Enum Constant Summary
MERGE_BOTH
          The current token should be attached to the string on the left side, as well as to the begin token on the right side.
MERGE_TO_LEFT
          The current token should be attached to the string on the left side.
MERGE_TO_RIGHT
          The current token should be attached to the begin token on the right side.
NO_OPERATION
          Do not perform a merge operation for this token, but is possible that another token can be attached to the left or right side of this one.
 
Method Summary
static Detokenizer.DetokenizationOperation valueOf(String name)
          Returns the enum constant of this type with the specified name.
static Detokenizer.DetokenizationOperation[] values()
          Returns an array containing the constants of this enum type, in the order they're declared.
 
Methods inherited from class java.lang.Enum
compareTo, equals, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Enum Constant Detail

MERGE_TO_RIGHT

public static final Detokenizer.DetokenizationOperation MERGE_TO_RIGHT
The current token should be attached to the begin token on the right side.


MERGE_TO_LEFT

public static final Detokenizer.DetokenizationOperation MERGE_TO_LEFT
The current token should be attached to the string on the left side.


MERGE_BOTH

public static final Detokenizer.DetokenizationOperation MERGE_BOTH
The current token should be attached to the string on the left side, as well as to the begin token on the right side.


NO_OPERATION

public static final Detokenizer.DetokenizationOperation NO_OPERATION
Do not perform a merge operation for this token, but is possible that another token can be attached to the left or right side of this one.

Method Detail

values

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

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

valueOf

public static Detokenizer.DetokenizationOperation 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


Copyright © 2013 The Apache Software Foundation. All Rights Reserved.