|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectgov.nih.nlm.umls.meta.impl.StringInfoImpl
Default implementation of the StringInfo
interface.
Constructor Summary | |
StringInfoImpl()
Instantiates an empty StringInfo . |
|
StringInfoImpl(StringInfo si)
Instantiates a StringInfo from the specified StringInfo . |
Method Summary | |
void |
addAtom(Atom atom)
Adds the specified Atom . |
void |
clearAtoms()
Removes all Atom s. |
int |
compareTo(Object o)
Compares this StringInfo to another one. |
boolean |
equals(Object o)
Returns true if the specified object is
equal to this object. |
Atom[] |
getAtoms()
Returns all Atom s. |
List |
getAtomsAsList()
Returns all Atom s as a List . |
String |
getKeyFields()
Returns a String key which can be used
by equals, compareTo, and hashCode methods. |
String |
getName()
Sets the name (STR). |
String |
getStr()
Shorthand for getName() . |
String |
getStringIdentifier()
Return the string identifier (SUI). |
StringType |
getStringType()
Returns the StringType (STT). |
StringType |
getStt()
Shorthand for getStringType() . |
String |
getSui()
Shorthand for getStringIdentifier() . |
Term |
getTerm()
Returns the parent Term . |
int |
hashCode()
Return a hash code based on key fields. |
boolean |
hasPreferredStringIdentifier()
Indicates whether or not this has the preferred string identifier of the Term it is part of. |
boolean |
hasPreferredSui()
Shorthand for hasPreferredStringIdentifier() . |
void |
removeAtom(Atom atom)
Removes the specified Atom . |
void |
setAtoms(Atom[] l_atoms)
Replaces the Atom s with those in the specified array. |
void |
setAtoms(List atoms)
Replaces the Atom s with those in the specified List |
void |
setName(String str)
Sets the name (STR). |
void |
setStr(String str)
Shorthand for setName(String) . |
void |
setStringIdentifier(String sui)
Sets the string identifier (SUI). |
void |
setStringType(StringType stt)
Sets the StringType (STT). |
void |
setStt(StringType stt)
Shorthand for setStringType(StringType) . |
void |
setSui(String sui)
Shorthand for setStringIdentifier(String) . |
void |
setTerm(Term term)
Sets the parent Term . |
Methods inherited from class java.lang.Object |
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public StringInfoImpl()
StringInfo
.
public StringInfoImpl(StringInfo si)
StringInfo
from the specified StringInfo
.
si
- StringInfo
to be copiedMethod Detail |
public Term getTerm()
Term
.
getTerm
in interface TermElement
Term
public void setTerm(Term term)
Term
.
setTerm
in interface TermElement
term
- the parent Term
public StringType getStringType()
StringType
(STT).
getStringType
in interface StringInfo
StringType
public StringType getStt()
getStringType()
.
getStt
in interface StringInfo
StringType
public void setStringType(StringType stt)
StringType
(STT).
setStringType
in interface StringInfo
stt
- the STTpublic void setStt(StringType stt)
setStringType(StringType)
.
setStt
in interface StringInfo
stt
- the STTpublic String getSui()
getStringIdentifier()
.
getSui
in interface StringInfo
public void setSui(String sui)
setStringIdentifier(String)
.
setSui
in interface StringInfo
sui
- the SUIpublic String getStringIdentifier()
getStringIdentifier
in interface StringInfo
public void setStringIdentifier(String sui)
setStringIdentifier
in interface StringInfo
sui
- the SUIpublic String getName()
getName
in interface StringInfo
public String getStr()
getName()
.
getStr
in interface StringInfo
public void setName(String str)
setName
in interface StringInfo
str
- the namepublic void setStr(String str)
setName(String)
.
setStr
in interface StringInfo
str
- the namepublic Atom[] getAtoms()
Atom
s.
getAtoms
in interface StringInfo
Atom
spublic List getAtomsAsList()
Atom
s as a List
.
getAtomsAsList
in interface StringInfo
Atom
s as a List
public void addAtom(Atom atom)
Atom
.
addAtom
in interface StringInfo
atom
- the Atom
to addpublic void removeAtom(Atom atom)
Atom
.
removeAtom
in interface StringInfo
atom
- the Atom
to removepublic void clearAtoms()
Atom
s.
clearAtoms
in interface StringInfo
public void setAtoms(Atom[] l_atoms)
Atom
s with those in the specified array.
setAtoms
in interface StringInfo
l_atoms
- an array of Atom
spublic void setAtoms(List atoms)
Atom
s with those in the specified List
setAtoms
in interface StringInfo
atoms
- a List
of Atom
spublic String getKeyFields()
String
key which can be used
by equals, compareTo, and hashCode methods.
getKeyFields
in interface StringInfo
String
composed from the sui.public int hashCode()
public boolean equals(Object o)
true
if the specified object is
equal to this object. The specified object must be an
StringInfo
with matching key fields.
o
- an Object
to compare against
true
if Object o is equal
false
otherwisepublic int compareTo(Object o)
StringInfo
to another one. Results
are indeterminate if the specified parameter is not of the
same class.
compareTo
in interface Comparable
o
- the Object
to compare to
int
representing the relative ordering
of this and the compare-to objectpublic boolean hasPreferredStringIdentifier()
Term
it is part of. In other words, does this StringInfo
have
the same SUI as the preferred StringInfo
of the Term
.
hasPreferredStringIdentifier
in interface StringInfo
true
if so, false
otherwisepublic boolean hasPreferredSui()
hasPreferredStringIdentifier()
.
hasPreferredSui
in interface StringInfo
true
if so, false
otherwise
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |