edu.mit.jwi.item
Class VerbFrame

java.lang.Object
  extended by edu.mit.jwi.item.VerbFrame
All Implemented Interfaces:
IVerbFrame, java.io.Serializable

public class VerbFrame
extends java.lang.Object
implements IVerbFrame

Default, hard-coded, implementation of IVerbFrame that does not read from the actual file. This is not implemented as an Enum so that clients can instantiate their own custom verb frame objects.

Since:
JWI 2.1.0
Version:
2.4.0
See Also:
Serialized Form

Field Summary
static VerbFrame NUM_01
           
static VerbFrame NUM_02
           
static VerbFrame NUM_03
           
static VerbFrame NUM_04
           
static VerbFrame NUM_05
           
static VerbFrame NUM_06
           
static VerbFrame NUM_07
           
static VerbFrame NUM_08
           
static VerbFrame NUM_09
           
static VerbFrame NUM_10
           
static VerbFrame NUM_11
           
static VerbFrame NUM_12
           
static VerbFrame NUM_13
           
static VerbFrame NUM_14
           
static VerbFrame NUM_15
           
static VerbFrame NUM_16
           
static VerbFrame NUM_17
           
static VerbFrame NUM_18
           
static VerbFrame NUM_19
           
static VerbFrame NUM_20
           
static VerbFrame NUM_21
           
static VerbFrame NUM_22
           
static VerbFrame NUM_23
           
static VerbFrame NUM_24
           
static VerbFrame NUM_25
           
static VerbFrame NUM_26
           
static VerbFrame NUM_27
           
static VerbFrame NUM_28
           
static VerbFrame NUM_29
           
static VerbFrame NUM_30
           
static VerbFrame NUM_31
           
static VerbFrame NUM_32
           
static VerbFrame NUM_33
           
static VerbFrame NUM_34
           
static VerbFrame NUM_35
           
 
Constructor Summary
VerbFrame(int num, java.lang.String template)
          Constructs a new verb frame.
 
Method Summary
static VerbFrame getFrame(int number)
          Returns the frame indexed by the specified number defined in this class, or null if there is
 int getNumber()
          The id number of this verb frame.
 java.lang.String getTemplate()
          The string form of the template, drawn directly from the data file.
 java.lang.String instantiateTemplate(java.lang.String verb)
          Takes the supplied surface form of a verb and instantiates it into the template for the verb frame.
protected  java.lang.Object readResolve()
          This utility method implements the appropriate deserialization for this object.
 java.lang.String toString()
           
static java.util.Collection<VerbFrame> values()
          This emulates the Enum.values() method, in that it returns an unmodifiable collection of all the static instances declared in this class, in the order they were declared.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

NUM_01

public static final VerbFrame NUM_01

NUM_02

public static final VerbFrame NUM_02

NUM_03

public static final VerbFrame NUM_03

NUM_04

public static final VerbFrame NUM_04

NUM_05

public static final VerbFrame NUM_05

NUM_06

public static final VerbFrame NUM_06

NUM_07

public static final VerbFrame NUM_07

NUM_08

public static final VerbFrame NUM_08

NUM_09

public static final VerbFrame NUM_09

NUM_10

public static final VerbFrame NUM_10

NUM_11

public static final VerbFrame NUM_11

NUM_12

public static final VerbFrame NUM_12

NUM_13

public static final VerbFrame NUM_13

NUM_14

public static final VerbFrame NUM_14

NUM_15

public static final VerbFrame NUM_15

NUM_16

public static final VerbFrame NUM_16

NUM_17

public static final VerbFrame NUM_17

NUM_18

public static final VerbFrame NUM_18

NUM_19

public static final VerbFrame NUM_19

NUM_20

public static final VerbFrame NUM_20

NUM_21

public static final VerbFrame NUM_21

NUM_22

public static final VerbFrame NUM_22

NUM_23

public static final VerbFrame NUM_23

NUM_24

public static final VerbFrame NUM_24

NUM_25

public static final VerbFrame NUM_25

NUM_26

public static final VerbFrame NUM_26

NUM_27

public static final VerbFrame NUM_27

NUM_28

public static final VerbFrame NUM_28

NUM_29

public static final VerbFrame NUM_29

NUM_30

public static final VerbFrame NUM_30

NUM_31

public static final VerbFrame NUM_31

NUM_32

public static final VerbFrame NUM_32

NUM_33

public static final VerbFrame NUM_33

NUM_34

public static final VerbFrame NUM_34

NUM_35

public static final VerbFrame NUM_35
Constructor Detail

VerbFrame

public VerbFrame(int num,
                 java.lang.String template)
Constructs a new verb frame.

Parameters:
num - the verb frame number
template - the template representing the verb frame
Since:
JWI 2.1.0
Method Detail

getNumber

public int getNumber()
Description copied from interface: IVerbFrame
The id number of this verb frame. Should always return 1 or greater.

Specified by:
getNumber in interface IVerbFrame
Returns:
the id number of the verb frame, will be positive

getTemplate

public java.lang.String getTemplate()
Description copied from interface: IVerbFrame
The string form of the template, drawn directly from the data file. Will never return null

Specified by:
getTemplate in interface IVerbFrame
Returns:
the non-null, non-empty template of the verb frame

instantiateTemplate

public java.lang.String instantiateTemplate(java.lang.String verb)
Description copied from interface: IVerbFrame
Takes the supplied surface form of a verb and instantiates it into the template for the verb frame. This is a convenience method; the method does no morphological processing; it does not check to see if the passed in word is actually a verb.

Specified by:
instantiateTemplate in interface IVerbFrame
Parameters:
verb - the string to be substituted into the template
Returns:
the instantiated template

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object

readResolve

protected java.lang.Object readResolve()
This utility method implements the appropriate deserialization for this object.

Returns:
the appropriate deserialized object.
Since:
JWI 2.4.0

values

public static java.util.Collection<VerbFrame> values()
This emulates the Enum.values() method, in that it returns an unmodifiable collection of all the static instances declared in this class, in the order they were declared.

Returns:
an unmodifiable collection of verb frames defined in this class
Since:
JWI 2.1.0

getFrame

public static VerbFrame getFrame(int number)
Returns the frame indexed by the specified number defined in this class, or null if there is

Parameters:
number - the verb frame number
Returns:
the verb frame with the specified number, or null if nuone
Since:
JWI 2.1.0


Copyright © 2007-2013 Massachusetts Institute of Technology. All Rights Reserved.