|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectgov.nih.nlm.umls.meta.impl.StringContextImpl
public class StringContextImpl
Default implementation of the StringContext interface.
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from interface gov.nih.nlm.umls.meta.AtomElement |
|---|
AtomElement.ByLanguageRestrictor, AtomElement.BySourceRestrictor |
| Nested classes/interfaces inherited from interface gov.nih.nlm.umls.meta.SourceElement |
|---|
SourceElement.BySourceComparator, SourceElement.BySourceRestrictor |
| Constructor Summary | |
|---|---|
StringContextImpl()
Instantiates an empty StringContext. |
|
StringContextImpl(StringContext sc)
Instantiates a StringContext from the specified StringContext. |
|
| Method Summary | |
|---|---|
void |
addSourceContext(SourceContext sc)
Adds the specified SourceContext. |
void |
clearSourceContexts()
Removes all SourceContexts. |
int |
compareTo(Object o)
Compares this StringContext to another one. |
boolean |
equals(Object o)
Returns true if the specified object is
equal to this object. |
Atom |
getAtom()
Returns the Atom for this StringContext. |
ContextGroup |
getContextGroup()
Returns the ContextGroup that holds this StringContext. |
String |
getKeyFields()
Returns a String key which can be used
by equals, compareTo, and hashCode methods. |
Source |
getSource()
Returns the source for this StringContext. |
SourceContext[] |
getSourceContexts()
Returns all SourceContexts. |
List |
getSourceContextsAsList()
Returns all SourceContexts as a List. |
int |
hashCode()
Return a hash code based on key fields. |
void |
removeSourceContext(SourceContext sc)
Removes the specified SourceContext. |
void |
setAtom(Atom atom)
Sets the source for this StringContext. |
void |
setContextGroup(ContextGroup cg)
Sets the ContextGroup that holds this StringContext. |
void |
setSource(Source source)
Sets the source for this StringContext. |
void |
setSourceContexts(List scs)
Replace the SourceContexts with the ones in the specified List. |
void |
setSourceContexts(SourceContext[] scs)
Replace the SourceContexts with the ones in the specified array. |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public StringContextImpl()
StringContext.
public StringContextImpl(StringContext sc)
StringContext from the specified StringContext.
sc - StringContext to be copied| Method Detail |
|---|
public ContextGroup getContextGroup()
ContextGroup that holds this StringContext.
getContextGroup in interface StringContextContextGroup that holds this StringContextpublic void setContextGroup(ContextGroup cg)
ContextGroup that holds this StringContext.
setContextGroup in interface StringContextcg - the ContextGroup that holds this StringContextpublic SourceContext[] getSourceContexts()
SourceContexts.
getSourceContexts in interface StringContextSourceContextspublic List getSourceContextsAsList()
SourceContexts as a List.
getSourceContextsAsList in interface StringContextSourceContextspublic void addSourceContext(SourceContext sc)
SourceContext.
addSourceContext in interface StringContextsc - the SourceContext to be addedpublic void removeSourceContext(SourceContext sc)
SourceContext.
removeSourceContext in interface StringContextsc - the SourceContext to be removedpublic void clearSourceContexts()
SourceContexts.
clearSourceContexts in interface StringContextpublic void setSourceContexts(SourceContext[] scs)
SourceContexts with the ones in the specified array.
setSourceContexts in interface StringContextscs - a SourceContext[]public void setSourceContexts(List scs)
SourceContexts with the ones in the specified List.
setSourceContexts in interface StringContextscs - a List of SourceContextspublic Atom getAtom()
Atom for this StringContext.
getAtom in interface AtomElementAtompublic void setAtom(Atom atom)
StringContext.
setAtom in interface AtomElementatom - Sourcepublic Source getSource()
StringContext.
getSource in interface SourceElementSourcepublic void setSource(Source source)
StringContext.
setSource in interface SourceElementsource - Sourcepublic String getKeyFields()
String key which can be used
by equals, compareTo, and hashCode methods.
getKeyFields in interface StringContextString composed from the cui, aui, sui,
versioned source, tty, and code.public int hashCode()
hashCode in class Objectpublic boolean equals(Object o)
true if the specified object is
equal to this object. The specified object must be an
StringContext with matching key fields.
equals in class Objecto - an Object to compare against
true if Object o is equal
false otherwisepublic int compareTo(Object o)
StringContext to another one. Results
are indeterminate if the specified parameter is not of the
same class.
compareTo in interface Comparableo - the Object to compare to
int representing the relative ordering
of this and the compare-to object
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||