public enum PartOfSpeech extends java.lang.Enum<PartOfSpeech>
Enum Constant and Description |
---|
ADJECTIVE |
ADVERB |
AUXILIARY_VERB |
CONJUNCTION |
DETERMINER |
INTERJECTION |
NOUN |
PREPOSITION |
PRONOUN |
VERB |
Modifier and Type | Method and Description |
---|---|
static boolean |
canContinueClause(PartOfSpeech pos,
PartOfSpeech clauseType)
Determine whether the given part of speech can continue a noun or verb
clause
|
static boolean |
canStartClause(PartOfSpeech pos,
PartOfSpeech clauseType)
Determine whether the given part of speech can start a noun or verb
clause
|
static PartOfSpeech |
convertTag(java.lang.String tag)
Convert a tag used in the Brown Corpus or Princeton WordNet to a
PartOfSpeech enumerated value.
|
static PartOfSpeech |
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name.
|
static PartOfSpeech[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final PartOfSpeech NOUN
public static final PartOfSpeech PRONOUN
public static final PartOfSpeech AUXILIARY_VERB
public static final PartOfSpeech VERB
public static final PartOfSpeech ADJECTIVE
public static final PartOfSpeech ADVERB
public static final PartOfSpeech PREPOSITION
public static final PartOfSpeech CONJUNCTION
public static final PartOfSpeech INTERJECTION
public static final PartOfSpeech DETERMINER
public static PartOfSpeech[] values()
for (PartOfSpeech c : PartOfSpeech.values()) System.out.println(c);
public static PartOfSpeech valueOf(java.lang.String name)
name
- the name of the enum constant to be returned.java.lang.IllegalArgumentException
- if this enum type has no constant
with the specified namejava.lang.NullPointerException
- if the argument is nullpublic static boolean canContinueClause(PartOfSpeech pos, PartOfSpeech clauseType)
pos
- The part of speech to testclauseType
- the clause type - either NOUN or VERBpublic static boolean canStartClause(PartOfSpeech pos, PartOfSpeech clauseType)
pos
- The part of speech to testclauseType
- the clause type - either NOUN or VERBpublic static PartOfSpeech convertTag(java.lang.String tag)
tag
- the tag used in the Brown Corpus