Class Role

java.lang.Object
  |
  +--Role
All Implemented Interfaces:
java.io.Serializable

public class Role
extends java.lang.Object
implements java.io.Serializable

Role contains information on the syntactic and semantic role of a word or group of words.

See Also:
Serialized Form

Constructor Summary
Role(java.lang.String newSyntax, java.lang.String newSelectional, java.lang.String newInterpretation)
          Create a role from strings.
 
Method Summary
 void addSemantics(java.lang.String newSelectional, java.lang.String newInterpretation)
          Add semantics to this role.
 boolean inCat(java.lang.String cat)
          Check if this role is in some syntactic category.
 java.lang.String interpretation()
          Get the interpretation of this role.
 java.lang.String selectionalType()
          Get the selectional type of this role.
 java.lang.String syntax()
          Get the syntax of this role.
 java.lang.String toString()
          Represent this role as a string.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Role

public Role(java.lang.String newSyntax,
            java.lang.String newSelectional,
            java.lang.String newInterpretation)
Create a role from strings.

Parameters:
newSyntax - the syntax.
newSelectional - the selectional type.
newInterpretation - the interpretation.
Method Detail

toString

public java.lang.String toString()
Represent this role as a string.

Overrides:
toString in class java.lang.Object
Returns:
the string.

syntax

public java.lang.String syntax()
Get the syntax of this role.

Returns:
the syntax.

selectionalType

public java.lang.String selectionalType()
Get the selectional type of this role.

Returns:
the selectional type.

interpretation

public java.lang.String interpretation()
Get the interpretation of this role.

Returns:
the interpretation.

addSemantics

public void addSemantics(java.lang.String newSelectional,
                         java.lang.String newInterpretation)
Add semantics to this role. If it already has semantics, change them.

Parameters:
newSelectional - the new selectional type.
newInterpretation - the new interpretation.

inCat

public boolean inCat(java.lang.String cat)
Check if this role is in some syntactic category. Straightforward str comparison.

Parameters:
cat - the category.
Returns:
true if in the category.