edu.northwestern.at.wordhoard.model.morphology
Class BensonLemma

java.lang.Object
  extended by edu.northwestern.at.wordhoard.model.morphology.BensonLemma
All Implemented Interfaces:
PersistentObject

public class BensonLemma
extends java.lang.Object
implements PersistentObject

A Benson lemma.

Benson lemmas have the following attributes:


Constructor Summary
BensonLemma()
          Creates a new Benson lemma.
 
Method Summary
 boolean equals(java.lang.Object obj)
          Returns true if some other object is equal to this one.
 void export(TableExporterImporter exporterImporter)
          Exports the object to a MySQL table exporter/importer.
 java.lang.String getComment()
          Gets the comment.
 java.lang.String getDefinition()
          Gets the definition.
 int getHomonym()
          Gets the homonym.
 java.lang.Long getId()
          Gets the unique id.
 java.lang.String getOedLemma()
          Gets the OED lemma.
 java.lang.String getTag()
          Gets the tag.
 java.lang.String getWord()
          Gets the word.
 java.lang.String getWordClass()
          Gets the word class.
 int hashCode()
          Returns a hash code for the object.
 void setComment(java.lang.String comment)
          Sets the comment.
 void setDefinition(java.lang.String definition)
          Sets the definition.
 void setHomonym(int homonym)
          Sets the homonym.
 void setId(java.lang.Long id)
          Sets the unique id.
 void setOedLemma(java.lang.String oedLemma)
          Sets the OED lemma.
 void setWord(java.lang.String word)
          Sets the word.
 void setWordClass(java.lang.String wordClass)
          Sets the word class.
 java.lang.String toString()
          Gets a string representation of the Benson lemma.
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

BensonLemma

public BensonLemma()
Creates a new Benson lemma.

Method Detail

getId

public java.lang.Long getId()
Gets the unique id.

Specified by:
getId in interface PersistentObject
Returns:
The unique id.

setId

public void setId(java.lang.Long id)
Sets the unique id.

Parameters:
id - The unique id.

getWord

public java.lang.String getWord()
Gets the word.

Returns:
The word.

setWord

public void setWord(java.lang.String word)
Sets the word.

Parameters:
word - The word.

getWordClass

public java.lang.String getWordClass()
Gets the word class.

Returns:
The word class.

setWordClass

public void setWordClass(java.lang.String wordClass)
Sets the word class.

Parameters:
wordClass - The word class.

getHomonym

public int getHomonym()
Gets the homonym.

Returns:
The homonym.

setHomonym

public void setHomonym(int homonym)
Sets the homonym.

Parameters:
homonym - The homonym.

getDefinition

public java.lang.String getDefinition()
Gets the definition.

Returns:
The definition, with any trailing "," character removed.

setDefinition

public void setDefinition(java.lang.String definition)
Sets the definition.

Parameters:
definition - The definition.

getComment

public java.lang.String getComment()
Gets the comment.

Returns:
The comment.

setComment

public void setComment(java.lang.String comment)
Sets the comment.

Parameters:
comment - The comment.

getOedLemma

public java.lang.String getOedLemma()
Gets the OED lemma.

Returns:
The OED lemma.

setOedLemma

public void setOedLemma(java.lang.String oedLemma)
Sets the OED lemma.

Parameters:
oedLemma - The OED lemma.

getTag

public java.lang.String getTag()
Gets the tag.

The tag is: word (wordClass) (homonym)

Returns:
The tag.

toString

public java.lang.String toString()
Gets a string representation of the Benson lemma.

Overrides:
toString in class java.lang.Object
Returns:
The tag (same as getTag).

export

public void export(TableExporterImporter exporterImporter)
Exports the object to a MySQL table exporter/importer.

Parameters:
exporterImporter - MySQL table exporter/importer.

equals

public boolean equals(java.lang.Object obj)
Returns true if some other object is equal to this one.

The two Benson lemmas are equal if their tags are equal.

Overrides:
equals in class java.lang.Object
Parameters:
obj - The other object.
Returns:
True if this object equals the other object.

hashCode

public int hashCode()
Returns a hash code for the object.

Overrides:
hashCode in class java.lang.Object
Returns:
The hash code.