gov.nih.nlm.umls.meta.impl
Class AtomMappingImpl

java.lang.Object
  extended bygov.nih.nlm.umls.meta.impl.AtomMappingImpl
All Implemented Interfaces:
AtomMapping, Comparable

public class AtomMappingImpl
extends Object
implements AtomMapping

Default implementation of the AtomMapping interface.

Author:
Brian Carlsen, Deborah Shapiro

Constructor Summary
AtomMappingImpl()
          Instantiates an empty AtomMapping.
AtomMappingImpl(AtomMapping am)
          Instantiates a AtomMapping from the specified AtomMapping.
 
Method Summary
 int compareTo(Object o)
          Compares this AtomMapping to another one.
 boolean equals(Object o)
          Returns true if the specified object is equal to this object.
 AdditionalRelationshipLabel getAdditionalRelationshipLabel()
          Returns the AdditionalRelationshipLabel (RELA).
 String getAtomIdentifier()
          Returns the atom identifier for the first atom (AUI1).
 String getAui1()
          Shorthand for getAtomIdentifier().
 String getAui2()
          Shorthand for getRelatedAtomIdentifier().
 String getConceptIdentifier()
          Returns the concept identifier for the first atom (CUI1).
 String getCui1()
          Returns the concept identifier for the first atom (CUI1).
 String getCui2()
          Returns the concept identifier for the second atom (CUI2).
 String getKeyFields()
          Returns a String key which can be used by equals, compareTo, and hashCode methods.
 String getMapin()
          Returns the "in current subset" value (MAPIN).
 String getMapReason()
          Returns the reason for this AtomMapping (MAPREASON).
 RelationshipLabel getRel()
          Shorthand for getRelationshipLabel().
 AdditionalRelationshipLabel getRela()
          Shorthand for getAdditionalRelationshipLabel()).
 String getRelatedAtomIdentifier()
          Returns the atom identifier for the second atom (AUI2).
 String getRelatedConceptIdentifier()
          Returns the concept identifier for the second atom (CUI2).
 RelationshipLabel getRelationshipLabel()
          Returns the relationship between the two concepts (REL).
 String getReleaseVersion()
          Returns the release version in which the indicated change took place (VER).
 String getVer()
          Returns the release version in which the indicated change took place (VER).
 int hashCode()
          Returns a hash code based on all fields.
 boolean inCurrentSubset()
          Indicates whether or not this AtomMapping is in the current subset (MAPIN).
 void setAdditionalRelationshipLabel(AdditionalRelationshipLabel rela)
          Sets the AdditionalRelationshipLabel (RELA).
 void setAtomIdentifier(String aui1)
          Sets the atom identifier for the first atom (AUI1).
 void setAui1(String aui1)
          Shorthand for setAtomIdentifier(String).
 void setAui2(String aui2)
          Shorthand for setRelatedAtomIdentifier(String).
 void setConceptIdentifier(String cui1)
          Sets the concept identifier for the first atom (CUI1).
 void setCui1(String cui1)
          Sets the concept identifier for the first atom (CUI1).
 void setCui2(String cui2)
          Shorthand for setRelatedConceptIdentifier(String).
 void setInCurrentSubset(boolean mapin)
          Sets the flag indicating whether or not this AtomMapping is in the current subset (MAPIN).
 void setMapin(String mapin)
          Sets the "in current subset" value (MAPIN).
 void setMapReason(String reason)
          Sets the reason for this AtomMapping (MAPREASON).
 void setRel(RelationshipLabel rel)
          Shorthand for setRelationshipLabel(RelationshipLabel).
 void setRela(AdditionalRelationshipLabel rela)
          Shorthand for setAdditionalRelationshipLabel(AdditionalRelationshipLabel).
 void setRelatedAtomIdentifier(String aui2)
          Sets the atom identifier for the second atom (AUI2).
 void setRelatedConceptIdentifier(String cui2)
          Sets the concept identifier for the second atom (CUI2).
 void setRelationshipLabel(RelationshipLabel rel)
          Sets the relationship between the two concepts (REL).
 void setReleaseVersion(String ver)
          Sets the release version in which the indicated change took place (VER).
 void setVer(String ver)
          Sets the release version in which the indicated change took place (VER).
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AtomMappingImpl

public AtomMappingImpl()
Instantiates an empty AtomMapping.


AtomMappingImpl

public AtomMappingImpl(AtomMapping am)
Instantiates a AtomMapping from the specified AtomMapping.

Parameters:
am - AtomMapping to be copied
Method Detail

getConceptIdentifier

public String getConceptIdentifier()
Returns the concept identifier for the first atom (CUI1).

Specified by:
getConceptIdentifier in interface AtomMapping
Returns:
the concept identifier for the first atom

getCui1

public String getCui1()
Returns the concept identifier for the first atom (CUI1). Shorthand for getConceptIdentifier().

Specified by:
getCui1 in interface AtomMapping
Returns:
the result of getConceptIdentifier()

setConceptIdentifier

public void setConceptIdentifier(String cui1)
Sets the concept identifier for the first atom (CUI1).

Specified by:
setConceptIdentifier in interface AtomMapping
Parameters:
cui1 - the concept identifier for the first atom

setCui1

public void setCui1(String cui1)
Sets the concept identifier for the first atom (CUI1). Shorthand for setConceptIdentifier(String).

Specified by:
setCui1 in interface AtomMapping
Parameters:
cui1 - the concept identifier for the first atom

getAtomIdentifier

public String getAtomIdentifier()
Returns the atom identifier for the first atom (AUI1).

Specified by:
getAtomIdentifier in interface AtomMapping
Returns:
the atom identifier for the first atom

getAui1

public String getAui1()
Shorthand for getAtomIdentifier().

Specified by:
getAui1 in interface AtomMapping
Returns:
the result of getAtomIdentifier()

setAtomIdentifier

public void setAtomIdentifier(String aui1)
Sets the atom identifier for the first atom (AUI1).

Specified by:
setAtomIdentifier in interface AtomMapping
Parameters:
aui1 - the atom identifier for the first atom

setAui1

public void setAui1(String aui1)
Shorthand for setAtomIdentifier(String).

Specified by:
setAui1 in interface AtomMapping
Parameters:
aui1 - the atom identifier for the first atom

getReleaseVersion

public String getReleaseVersion()
Returns the release version in which the indicated change took place (VER).

Specified by:
getReleaseVersion in interface AtomMapping
Returns:
the release version in which the indicated change took place

getVer

public String getVer()
Returns the release version in which the indicated change took place (VER). This method is shortand for getReleaseVersion().

Specified by:
getVer in interface AtomMapping
Returns:
the release version in which the indicated change took place

setReleaseVersion

public void setReleaseVersion(String ver)
Sets the release version in which the indicated change took place (VER).

Specified by:
setReleaseVersion in interface AtomMapping
Parameters:
ver - the release version in which the indicated change took place

setVer

public void setVer(String ver)
Sets the release version in which the indicated change took place (VER). This method is shorthand for (@link #setReleaseVersion(String)}.

Specified by:
setVer in interface AtomMapping
Parameters:
ver - the release version in which the indicated change took place

getRelationshipLabel

public RelationshipLabel getRelationshipLabel()
Returns the relationship between the two concepts (REL).

Specified by:
getRelationshipLabel in interface AtomMapping
Returns:
the relationship between the two concepts

getRel

public RelationshipLabel getRel()
Shorthand for getRelationshipLabel().

Specified by:
getRel in interface AtomMapping
Returns:
the result of getRelationshipLabel()

setRelationshipLabel

public void setRelationshipLabel(RelationshipLabel rel)
Sets the relationship between the two concepts (REL).

Specified by:
setRelationshipLabel in interface AtomMapping
Parameters:
rel - the relationship between the two concepts

setRel

public void setRel(RelationshipLabel rel)
Shorthand for setRelationshipLabel(RelationshipLabel).

Specified by:
setRel in interface AtomMapping
Parameters:
rel - the relationship between the two concepts

getAdditionalRelationshipLabel

public AdditionalRelationshipLabel getAdditionalRelationshipLabel()
Returns the AdditionalRelationshipLabel (RELA).

Specified by:
getAdditionalRelationshipLabel in interface AtomMapping
Returns:
the AdditionalRelationshipLabel

getRela

public AdditionalRelationshipLabel getRela()
Shorthand for getAdditionalRelationshipLabel()).

Specified by:
getRela in interface AtomMapping
Returns:
the result of getAdditionalRelationshipLabel()

setAdditionalRelationshipLabel

public void setAdditionalRelationshipLabel(AdditionalRelationshipLabel rela)
Sets the AdditionalRelationshipLabel (RELA).

Specified by:
setAdditionalRelationshipLabel in interface AtomMapping
Parameters:
rela - the AdditionalRelationshipLabel

setRela

public void setRela(AdditionalRelationshipLabel rela)
Shorthand for setAdditionalRelationshipLabel(AdditionalRelationshipLabel).

Specified by:
setRela in interface AtomMapping
Parameters:
rela - the AdditionalRelationshipLabel

getRelatedConceptIdentifier

public String getRelatedConceptIdentifier()
Returns the concept identifier for the second atom (CUI2).

Specified by:
getRelatedConceptIdentifier in interface AtomMapping
Returns:
the concept identifier for the second atom

getCui2

public String getCui2()
Returns the concept identifier for the second atom (CUI2). Shorthand for getRelatedConceptIdentifier().

Specified by:
getCui2 in interface AtomMapping
Returns:
the result of getRelatedConceptIdentifier()

setRelatedConceptIdentifier

public void setRelatedConceptIdentifier(String cui2)
Sets the concept identifier for the second atom (CUI2).

Specified by:
setRelatedConceptIdentifier in interface AtomMapping
Parameters:
cui2 - the concept identifier for the second atom

setCui2

public void setCui2(String cui2)
Shorthand for setRelatedConceptIdentifier(String).

Specified by:
setCui2 in interface AtomMapping
Parameters:
cui2 - the concept identifier for the second atom

getRelatedAtomIdentifier

public String getRelatedAtomIdentifier()
Returns the atom identifier for the second atom (AUI2).

Specified by:
getRelatedAtomIdentifier in interface AtomMapping
Returns:
the atom identifier for the second atom

getAui2

public String getAui2()
Shorthand for getRelatedAtomIdentifier().

Specified by:
getAui2 in interface AtomMapping
Returns:
the result of getRelatedAtomIdentifier()

setRelatedAtomIdentifier

public void setRelatedAtomIdentifier(String aui2)
Sets the atom identifier for the second atom (AUI2).

Specified by:
setRelatedAtomIdentifier in interface AtomMapping
Parameters:
aui2 - the atom identifier for the second atom

setAui2

public void setAui2(String aui2)
Shorthand for setRelatedAtomIdentifier(String).

Specified by:
setAui2 in interface AtomMapping
Parameters:
aui2 - the atom identifier for the second atom

getMapReason

public String getMapReason()
Returns the reason for this AtomMapping (MAPREASON).

Specified by:
getMapReason in interface AtomMapping
Returns:
the reason for this AtomMapping

setMapReason

public void setMapReason(String reason)
Sets the reason for this AtomMapping (MAPREASON).

Specified by:
setMapReason in interface AtomMapping
Parameters:
reason - the reason for this AtomMapping

getMapin

public String getMapin()
Returns the "in current subset" value (MAPIN).

Specified by:
getMapin in interface AtomMapping
Returns:
the "in current subset" value

inCurrentSubset

public boolean inCurrentSubset()
Indicates whether or not this AtomMapping is in the current subset (MAPIN).

Specified by:
inCurrentSubset in interface AtomMapping
Returns:
boolean true if in current subset, boolean false if not in current subset

setMapin

public void setMapin(String mapin)
Sets the "in current subset" value (MAPIN).

Specified by:
setMapin in interface AtomMapping
Parameters:
mapin - the "in current subset" value

setInCurrentSubset

public void setInCurrentSubset(boolean mapin)
Sets the flag indicating whether or not this AtomMapping is in the current subset (MAPIN).

Specified by:
setInCurrentSubset in interface AtomMapping
Parameters:
mapin - boolean true if in current subset, boolean false if not in current subset

hashCode

public int hashCode()
Returns a hash code based on all fields.

Returns:
a hash code based on all fields

equals

public boolean equals(Object o)
Returns true if the specified object is equal to this object. The specified object must be a AtomMapping with matching key fields.

Parameters:
o - an Object to compare against
Returns:
boolean true if Object o is equal, false otherwise

compareTo

public int compareTo(Object o)
Compares this AtomMapping to another one. Results are indeterminate if the specified parameter is not of the same class.

Specified by:
compareTo in interface Comparable
Parameters:
o - the Object to compare to
Returns:
int representing the Related ordering of this and the compare-to object

getKeyFields

public String getKeyFields()
Returns a String key which can be used by equals, compareTo, and hashCode methods.

Specified by:
getKeyFields in interface AtomMapping
Returns:
a String composed from the cui1, ver, rel, rela, mapreason, cui2, and mapin.


Copyright ©2005