Package com.articulate.sigma.nlg
Enum Class CaseRole
- All Implemented Interfaces:
Serializable,Comparable<CaseRole>,Constable
Identifies specific Sumo CaseRole objects. Not all Sumo CaseRoles are listed here--only those whose behavior
must be defined for NLG. Any role not defined here is assumed to behave identically to the CaseRole which it
is a subrelation of (except for the formatted string property). For example, because "(subrelation result patient)",
we expect the "result" CaseRole to generally appear as the direct object of the sentence, just like the "patient"
case role.
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>> -
Enum Constant Summary
Enum ConstantsEnum ConstantDescription -
Method Summary
Modifier and TypeMethodDescriptionstatic CaseRolegetCaseRole(Collection<String> list) From the input list, return the first string that is a valid case role.static booleanisKnownCaseRole(String input) Is the input string a valid case role? Note that this method is case-sensitive.static CaseRoletoCaseRole(String input, KB kb) Return a valid case role based on the string input.static CaseRoleReturns the enum constant of this class with the specified name.static CaseRole[]values()Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
AGENT
-
ATTENDS
-
DESTINATION
-
DIRECTION
-
EVENTPARTLYLOCATED
-
EXPERIENCER
-
INSTRUMENT
-
MOVES
-
ORIGIN
-
PATH
-
PATIENT
-
RESOURCE
-
OTHER
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (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 class has no constant with the specified nameNullPointerException- if the argument is null
-
isKnownCaseRole
Is the input string a valid case role? Note that this method is case-sensitive.- Parameters:
input-- Returns:
-
getCaseRole
From the input list, return the first string that is a valid case role.- Parameters:
list-- Returns:
- a CaseRole object if its string is found in the list; else null
-
toCaseRole
Return a valid case role based on the string input. If string does not match any case role, return OTHER.- Parameters:
input-- Returns:
-