gov.nih.nlm.umls.meta
Interface Concept

All Superinterfaces:
Comparable
All Known Implementing Classes:
ConceptImpl, DisplayableConcept, PlaceholderConcept

public interface Concept
extends Comparable

Represents a UMLS Concept.

Author:
Brian Carlsen, Deborah Shapiro

Nested Class Summary
static class Concept.ByCUIComparator
          Inner class compares Concepts based on cui.
static class Concept.ByPreferredNameComparator
          Sorts the Concepts based on String order.
 
Method Summary
 void addAtom(Atom atom)
          Adds the specified Atom.
 void addAttribute(Attribute att)
          Adds the specified Attribute.
 void addComponentHistory(ComponentHistory map)
          Adds a ComponentHistory.
 void addContext(Context cxt)
          Adds the specified Context.
 void addCoocurrence(Coocurrence coc)
          Adds the specified Coocurrence.
 void addDefinition(Definition def)
          Adds the specified Definition.
 void addLocator(Locator loc)
          Add the specified Locator.
 void addMapping(Mapping map)
          Adds a Mapping.
 void addRelationship(Relationship rel)
          Adds the specified Relationship.
 void addSemanticType(SemanticType sty)
          Adds a SemanticType.
 void clear()
          This removes all of the Concept's components.
 void clearAtoms()
          Remove all Atoms.
 void clearAttributes()
          Remove all Attributes.
 void clearComponentHistories()
          Removes all ComponentHistorys.
 void clearContexts()
          Remove all Contexts.
 void clearCoocurrences()
          Remove all Coocurrences.
 void clearDefinitions()
          Remove all Definitions.
 void clearLocators()
          Remove all Locators.
 void clearMappings()
          Removes all Mappings.
 void clearRelationships()
          Remove all Relationships.
 void clearSemanticTypes()
          Removes all SemanticTypes.
 Atom[] getAtoms()
          Returns the Atoms.
 Atom[] getAtoms(Restrictor restrictor)
          Returns a subset of this Concept's Atoms.
 List getAtomsAsList()
          Returns the Atoms as a List.
 Attribute[] getAttributes()
          Returns the Attributes.
 List getAttributesAsList()
          Returns the Attributes as a List.
 Attribute[] getAttributesForAtom(Atom atom)
          Returns the attributes with aui that matches that of the given Atom.
 List getAttributesForAtomAsList(Atom atom)
          Returns the attributes with aui that matches that of the given Atom in a List.
 AtomAttribute[] getAttributesForRelationship(AtomRelationship rel)
          Returns the attributes with aui that matches that of the given Relationship.
 List getAttributesForRelationshipAsList(AtomRelationship rel)
          Returns the attributes with aui that matches that of the given Relationship in a List.
 ComponentHistory[] getComponentHistories()
          Returns the ComponentHistorys.
 List getComponentHistoriesAsList()
          Returns the ComponentHistorys as a List.
 String getConceptIdentifier()
          Returns the concept unique identifier (CUI) for the Concept.
 ContextGroup[] getContextGroups()
          Return the ContextGroups.
 List getContextGroupsAsList()
          Returns the ContextGroups as a List.
 Context[] getContexts()
          Return the Contexts.
 Context[] getContexts(Restrictor restrictor)
          Returns a subset of this Concept's Contexts.
 List getContextsAsList()
          Returns the Contexts as a List.
 CoocurrenceGroup[] getCoocurrenceGroups()
          Returns the CoocurrenceGroups.
 List getCoocurrenceGroupsAsList()
          Returns the CoocurrenceGroups as a List.
 Coocurrence[] getCoocurrences()
          Returns the Coocurrences.
 Coocurrence[] getCoocurrences(Restrictor restrictor)
          Returns a subset of this Concept's Coocurrences.
 List getCoocurrencesAsList()
          Returns the Coocurrences as a List.
 String getCui()
          Returns the concept unique identifier (CUI) for the Concept.
 Definition[] getDefinitions()
          Returns the Definitions.
 Definition[] getDefinitions(Restrictor restrictor)
          Returns a subset of this Concept's Definitions.
 List getDefinitionsAsList()
          Returns the Definitions as a List.
 String getKeyFields()
          Returns a String key which can be used by equals, compareTo, and hashCode methods.
 Locator[] getLocators()
          Returns the Locators.
 List getLocatorsAsList()
          Returns the Locators as a List.
 Mapping[] getMappings()
          Returns the Mappings.
 List getMappingsAsList()
          Returns the Mappings as a List.
 Atom getPreferredAtom()
          Returns the preferred atom of the concept.
 Atom getPreferredAtom(Comparator comparator)
          Returns the preferred atom of the concept.
 Relationship[] getRelationships()
          Returns the Relationships.
 Relationship[] getRelationships(Restrictor restrictor)
          Returns a subset of this Concept's Relationships.
 List getRelationshipsAsList()
          Returns the Relationships as a List.
 SemanticType[] getSemanticTypes()
          Returns the SemanticTypes.
 List getSemanticTypesAsList()
          Returns the SemanticTypes as a List.
 TermAttribute[] getTermAttributes()
          Returns the TermAttributes.
 List getTermAttributesAsList()
          Returns the TermAttributes as a List.
 Term[] getTerms()
          Returns the Terms.
 List getTermsAsList()
          Returns the Terms as a List.
 boolean isEmpty()
          This indicates if the Concept is empty, meaning that either the SemanticType was removed or all of the Atoms were removed.
 void removeAtom(Atom atom)
          Removes the specified Atom.
 void removeAtom(int i)
           
 void removeAttribute(Attribute att)
          Removes the specified Attribute.
 void removeAttribute(int i)
           
 void removeComponentHistory(ComponentHistory map)
          Removes the specified ComponentHistory.
 void removeContext(Context cxt)
          Removes the specified Context.
 void removeContext(int i)
           
 void removeCoocurrence(Coocurrence coc)
          Removes the specified Coocurrence.
 void removeCoocurrence(int i)
           
 void removeDefinition(Definition def)
          Remove the specified Definition.
 void removeLocator(Locator loc)
          Removes the specified Locator.
 void removeMapping(int i)
           
 void removeMapping(Mapping map)
          Removes the specified Mapping.
 void removeRelationship(int i)
           
 void removeRelationship(Relationship rel)
          Removes the specified Relationship.
 void removeSemanticType(SemanticType sty)
          Removes the specified SemanticType.
 void setAtoms(Atom[] atoms)
          Replace any Atoms with the ones in the specified array.
 void setAtoms(List atoms)
          Replace Atoms with the ones in the specified List.
 void setAttributes(Attribute[] atts)
          Replace Attributes with the ones in the specified array.
 void setAttributes(List atts)
          Replace Attributes with the ones in the specified List.
 void setComponentHistories(ComponentHistory[] maps)
          Replace ComponentHistorys with the ones in the specified array.
 void setComponentHistories(List maps)
          Replace ComponentHistorys with the ones in the specified List.
 void setConceptIdentifier(String cui)
          Sets the concept unique identifier (CUI) for the Concept.
 void setContexts(Context[] cxts)
          Replace Contexts with the ones in the specified array.
 void setContexts(List cxts)
          Replace Contexts with the ones in the specified List.
 void setCoocurrences(Coocurrence[] cocs)
          Replace Coocurrences with the ones in the specified array.
 void setCoocurrences(List cocs)
          Replace Coocurrences with the ones in the specified List.
 void setCui(String cui)
          Sets the concept unique identifier (CUI) for the Concept.
 void setDefinitions(Definition[] defs)
          Replace Definitions with the ones in the specified array.
 void setDefinitions(List defs)
          Replace Definitions with the ones in the specified List.
 void setLocators(List locs)
          Replace Locators with the ones in the specified List.
 void setLocators(Locator[] locs)
          Replace Locators with the ones in the specified array.
 void setMappings(List maps)
          Replace Mappings with the ones in the specified List.
 void setMappings(Mapping[] maps)
          Replace Mappings with the ones in the specified array.
 void setRelationships(List rels)
          Replace Relationships of the ones in the specified List.
 void setRelationships(Relationship[] rels)
          Replace Relationships with the ones in the specified array.
 void setSemanticTypes(List stys)
          Replace SemanticTypes with the ones in the specified List.
 void setSemanticTypes(SemanticType[] stys)
          Replace SemanticTypes with the ones in the specified array.
 
Methods inherited from interface java.lang.Comparable
compareTo
 

Method Detail

clear

void clear()
This removes all of the Concept's components.


isEmpty

boolean isEmpty()
This indicates if the Concept is empty, meaning that either the SemanticType was removed or all of the Atoms were removed.

Returns:
boolean if empty

getAtoms

Atom[] getAtoms()
Returns the Atoms.

Returns:
an Atom []

getAtomsAsList

List getAtomsAsList()
Returns the Atoms as a List.

Returns:
the Atoms as a List

addAtom

void addAtom(Atom atom)
Adds the specified Atom.

Parameters:
atom - the Atom to be added

removeAtom

void removeAtom(Atom atom)
Removes the specified Atom.

Parameters:
atom - the Atom to be removed

removeAtom

void removeAtom(int i)

clearAtoms

void clearAtoms()
Remove all Atoms.


setAtoms

void setAtoms(Atom[] atoms)
Replace any Atoms with the ones in the specified array.

Parameters:
atoms - a Atom []

setAtoms

void setAtoms(List atoms)
Replace Atoms with the ones in the specified List.

Parameters:
atoms - a List of Atoms

getPreferredAtom

Atom getPreferredAtom()
Returns the preferred atom of the concept. It has TS=P, STT=PF, and ISPREF=Y.

Returns:
Atom

getPreferredAtom

Atom getPreferredAtom(Comparator comparator)
Returns the preferred atom of the concept. Uses the given Concept.ByCUIComparator to determine the preferred atom.

Parameters:
comparator - Concept.ByCUIComparator
Returns:
Atom

getLocators

Locator[] getLocators()
Returns the Locators.

Returns:
a Locator []

getLocatorsAsList

List getLocatorsAsList()
Returns the Locators as a List.

Returns:
the Locators as a List

addLocator

void addLocator(Locator loc)
Add the specified Locator.

Parameters:
loc - the Locator to be added

removeLocator

void removeLocator(Locator loc)
Removes the specified Locator.

Parameters:
loc - the Locator to be removed

clearLocators

void clearLocators()
Remove all Locators.


setLocators

void setLocators(Locator[] locs)
Replace Locators with the ones in the specified array.

Parameters:
locs - a Locator []

setLocators

void setLocators(List locs)
Replace Locators with the ones in the specified List.

Parameters:
locs - a List of Locators

getAttributes

Attribute[] getAttributes()
Returns the Attributes.

Returns:
a Attribute []

getAttributesAsList

List getAttributesAsList()
Returns the Attributes as a List.

Returns:
the Attributes as a List

addAttribute

void addAttribute(Attribute att)
Adds the specified Attribute.

Parameters:
att - the Attribute to be added

removeAttribute

void removeAttribute(Attribute att)
Removes the specified Attribute.

Parameters:
att - the Attribute to be removed

removeAttribute

void removeAttribute(int i)

clearAttributes

void clearAttributes()
Remove all Attributes.


setAttributes

void setAttributes(Attribute[] atts)
Replace Attributes with the ones in the specified array.

Parameters:
atts - an Attribute []

setAttributes

void setAttributes(List atts)
Replace Attributes with the ones in the specified List.

Parameters:
atts - a List of Attributes

getAttributesForAtom

Attribute[] getAttributesForAtom(Atom atom)
Returns the attributes with aui that matches that of the given Atom.

Parameters:
atom - Atom
Returns:
List of Attributes

getAttributesForAtomAsList

List getAttributesForAtomAsList(Atom atom)
Returns the attributes with aui that matches that of the given Atom in a List.

Parameters:
atom - Atom
Returns:
List of Attributes

getAttributesForRelationship

AtomAttribute[] getAttributesForRelationship(AtomRelationship rel)
Returns the attributes with aui that matches that of the given Relationship.

Parameters:
rel - Relationship
Returns:
List of AtomAttributes

getAttributesForRelationshipAsList

List getAttributesForRelationshipAsList(AtomRelationship rel)
Returns the attributes with aui that matches that of the given Relationship in a List.

Parameters:
rel - Relationship
Returns:
List of Attributes

getContexts

Context[] getContexts()
Return the Contexts.

Returns:
a Context []

getContexts

Context[] getContexts(Restrictor restrictor)
Returns a subset of this Concept's Contexts. Restricts the return based on the given Restrictor.

Parameters:
restrictor - Restrictor
Returns:
Context[]

getContextsAsList

List getContextsAsList()
Returns the Contexts as a List.

Returns:
the Contexts as a List

addContext

void addContext(Context cxt)
Adds the specified Context.

Parameters:
cxt - the Context to be added

removeContext

void removeContext(Context cxt)
Removes the specified Context.

Parameters:
cxt - the Context to be removed

removeContext

void removeContext(int i)

clearContexts

void clearContexts()
Remove all Contexts.


setContexts

void setContexts(Context[] cxts)
Replace Contexts with the ones in the specified array.

Parameters:
cxts - a Context []

setContexts

void setContexts(List cxts)
Replace Contexts with the ones in the specified List.

Parameters:
cxts - a List of Contexts

getCoocurrences

Coocurrence[] getCoocurrences()
Returns the Coocurrences.

Returns:
a Coocurrence []

getCoocurrences

Coocurrence[] getCoocurrences(Restrictor restrictor)
Returns a subset of this Concept's Coocurrences. Restricts the return based on the given Restrictor.

Parameters:
restrictor - Restrictor
Returns:
Coocurrence[]

getCoocurrencesAsList

List getCoocurrencesAsList()
Returns the Coocurrences as a List.

Returns:
the Coocurrences as a List

addCoocurrence

void addCoocurrence(Coocurrence coc)
Adds the specified Coocurrence.

Parameters:
coc - the Coocurrence to be added

removeCoocurrence

void removeCoocurrence(Coocurrence coc)
Removes the specified Coocurrence.

Parameters:
coc - the Coocurrence to be removed

removeCoocurrence

void removeCoocurrence(int i)

clearCoocurrences

void clearCoocurrences()
Remove all Coocurrences.


setCoocurrences

void setCoocurrences(Coocurrence[] cocs)
Replace Coocurrences with the ones in the specified array.

Parameters:
cocs - a Coocurrence []

setCoocurrences

void setCoocurrences(List cocs)
Replace Coocurrences with the ones in the specified List.

Parameters:
cocs - a List of Coocurrences

getDefinitions

Definition[] getDefinitions()
Returns the Definitions.

Returns:
a Definition []

getDefinitions

Definition[] getDefinitions(Restrictor restrictor)
Returns a subset of this Concept's Definitions. Restricts the return based on the given Restrictor.

Parameters:
restrictor - Restrictor
Returns:
Definition[]

getDefinitionsAsList

List getDefinitionsAsList()
Returns the Definitions as a List.

Returns:
the Definitions as a List

addDefinition

void addDefinition(Definition def)
Adds the specified Definition.

Parameters:
def - the Definition to be added

removeDefinition

void removeDefinition(Definition def)
Remove the specified Definition.

Parameters:
def - the Definition to be removed

clearDefinitions

void clearDefinitions()
Remove all Definitions.


setDefinitions

void setDefinitions(Definition[] defs)
Replace Definitions with the ones in the specified array.

Parameters:
defs - a Definition []

setDefinitions

void setDefinitions(List defs)
Replace Definitions with the ones in the specified List.

Parameters:
defs - a List of Definitions

getRelationships

Relationship[] getRelationships()
Returns the Relationships.

Returns:
a Relationship []

getRelationships

Relationship[] getRelationships(Restrictor restrictor)
Returns a subset of this Concept's Relationships. Restricts the return based on the given Restrictor.

Parameters:
restrictor - Restrictor
Returns:
Relationship[]

getRelationshipsAsList

List getRelationshipsAsList()
Returns the Relationships as a List.

Returns:
the Relationships as a List

addRelationship

void addRelationship(Relationship rel)
Adds the specified Relationship.

Parameters:
rel - the Relationship to be added

removeRelationship

void removeRelationship(Relationship rel)
Removes the specified Relationship.

Parameters:
rel - the Relationship to be removed

removeRelationship

void removeRelationship(int i)

clearRelationships

void clearRelationships()
Remove all Relationships.


setRelationships

void setRelationships(Relationship[] rels)
Replace Relationships with the ones in the specified array.

Parameters:
rels - a Relationship []

setRelationships

void setRelationships(List rels)
Replace Relationships of the ones in the specified List.

Parameters:
rels - a List of Relationships

getSemanticTypes

SemanticType[] getSemanticTypes()
Returns the SemanticTypes.

Returns:
a SemanticType []

getSemanticTypesAsList

List getSemanticTypesAsList()
Returns the SemanticTypes as a List.

Returns:
the SemanticTypes as a List

addSemanticType

void addSemanticType(SemanticType sty)
Adds a SemanticType.

Parameters:
sty - the SemanticType to be added

removeSemanticType

void removeSemanticType(SemanticType sty)
Removes the specified SemanticType.

Parameters:
sty - the SemanticType to be removed

clearSemanticTypes

void clearSemanticTypes()
Removes all SemanticTypes.


setSemanticTypes

void setSemanticTypes(SemanticType[] stys)
Replace SemanticTypes with the ones in the specified array.

Parameters:
stys - a SemanticType []

setSemanticTypes

void setSemanticTypes(List stys)
Replace SemanticTypes with the ones in the specified List.

Parameters:
stys - a List of SemanticTypes

getComponentHistories

ComponentHistory[] getComponentHistories()
Returns the ComponentHistorys.

Returns:
a ComponentHistory []

getComponentHistoriesAsList

List getComponentHistoriesAsList()
Returns the ComponentHistorys as a List.

Returns:
the ComponentHistorys as a List

addComponentHistory

void addComponentHistory(ComponentHistory map)
Adds a ComponentHistory.

Parameters:
map - the ComponentHistory to be added

removeComponentHistory

void removeComponentHistory(ComponentHistory map)
Removes the specified ComponentHistory.

Parameters:
map - the ComponentHistory to be removed

clearComponentHistories

void clearComponentHistories()
Removes all ComponentHistorys.


setComponentHistories

void setComponentHistories(ComponentHistory[] maps)
Replace ComponentHistorys with the ones in the specified array.

Parameters:
maps - a ComponentHistory []

setComponentHistories

void setComponentHistories(List maps)
Replace ComponentHistorys with the ones in the specified List.

Parameters:
maps - a List of ComponentHistorys

getMappings

Mapping[] getMappings()
Returns the Mappings.

Returns:
a Mapping []

getMappingsAsList

List getMappingsAsList()
Returns the Mappings as a List.

Returns:
the Mappings as a List

addMapping

void addMapping(Mapping map)
Adds a Mapping.

Parameters:
map - the Mapping to be added

removeMapping

void removeMapping(Mapping map)
Removes the specified Mapping.

Parameters:
map - the Mapping to be removed

removeMapping

void removeMapping(int i)

clearMappings

void clearMappings()
Removes all Mappings.


setMappings

void setMappings(Mapping[] maps)
Replace Mappings with the ones in the specified array.

Parameters:
maps - a Mapping []

setMappings

void setMappings(List maps)
Replace Mappings with the ones in the specified List.

Parameters:
maps - a List of Mappings

getCui

String getCui()
Returns the concept unique identifier (CUI) for the Concept. This is shorthand for getConceptIdentifier().

Returns:
the CUI

setCui

void setCui(String cui)
Sets the concept unique identifier (CUI) for the Concept. This is shorthand for setConceptIdentifier(String).

Parameters:
cui - the CUI

getConceptIdentifier

String getConceptIdentifier()
Returns the concept unique identifier (CUI) for the Concept.

Returns:
the CUI

setConceptIdentifier

void setConceptIdentifier(String cui)
Sets the concept unique identifier (CUI) for the Concept.

Parameters:
cui - the CUI

getKeyFields

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

Returns:
a String composed from key Concept fields

getContextGroups

ContextGroup[] getContextGroups()
Return the ContextGroups.

Returns:
a ContextGroup []

getContextGroupsAsList

List getContextGroupsAsList()
Returns the ContextGroups as a List.

Returns:
the ContextGroups as a List

getCoocurrenceGroups

CoocurrenceGroup[] getCoocurrenceGroups()
Returns the CoocurrenceGroups.

Returns:
a CoocurrenceGroup []

getCoocurrenceGroupsAsList

List getCoocurrenceGroupsAsList()
Returns the CoocurrenceGroups as a List.

Returns:
the CoocurrenceGroups as a List

getTermAttributes

TermAttribute[] getTermAttributes()
Returns the TermAttributes.

Returns:
a TermAttribute []

getTermAttributesAsList

List getTermAttributesAsList()
Returns the TermAttributes as a List.

Returns:
the TermAttributes as a List

getTerms

Term[] getTerms()
Returns the Terms.

Returns:
an Term []

getTermsAsList

List getTermsAsList()
Returns the Terms as a List.

Returns:
the Terms as a List

getAtoms

Atom[] getAtoms(Restrictor restrictor)
Returns a subset of this Concept's Atoms. Restricts the return based on the given Restrictor.

Parameters:
restrictor - Restrictor
Returns:
Atom[]


Copyright ©2005