edu.mssm.crover.webapps.dimlib.datamodel
Class ExternalReferencesImpl

java.lang.Object
  |
  +--edu.mssm.crover.webapps.dimlib.datamodel.ExternalReferencesImpl
All Implemented Interfaces:
ExternalReferences

public class ExternalReferencesImpl
extends java.lang.Object
implements ExternalReferences

Keeps references to external databases. If an ims instance describes an object i which is also described swissprot, a call such as i.setReference(Databases.SWISSPROT,"P08100") will record the link.

Author:
Fabien Campagne, luce

Constructor Summary
ExternalReferencesImpl()
           
 
Method Summary
 java.lang.String getAccessionCode(java.lang.String database)
          Returns the first accession code associated with this database.
 java.lang.String getAccessionCodes(java.lang.String database)
          Returns an accession code in the database.
 java.lang.String[] getDatabases()
          Returns the list of databases to which this er links.
 void removeReference(java.lang.String database, java.lang.String ac)
          Removes a reference to an external database.
 void setAccessionCode(java.lang.String database, java.lang.String ac)
          Sets the accession code for a database.
 void setReference(java.lang.String database, java.lang.String ac)
          Creates a reference to an entity in an external database.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ExternalReferencesImpl

public ExternalReferencesImpl()
Method Detail

setAccessionCode

public void setAccessionCode(java.lang.String database,
                             java.lang.String ac)
Sets the accession code for a database.


getAccessionCodes

public java.lang.String getAccessionCodes(java.lang.String database)
Returns an accession code in the database.

Specified by:
getAccessionCodes in interface ExternalReferences

getAccessionCode

public java.lang.String getAccessionCode(java.lang.String database)
Returns the first accession code associated with this database.

Specified by:
getAccessionCode in interface ExternalReferences

getDatabases

public java.lang.String[] getDatabases()
Returns the list of databases to which this er links.

Specified by:
getDatabases in interface ExternalReferences

setReference

public void setReference(java.lang.String database,
                         java.lang.String ac)
Description copied from interface: ExternalReferences
Creates a reference to an entity in an external database.

Specified by:
setReference in interface ExternalReferences
Parameters:
database - The name of the external database (e.g. sw).

removeReference

public void removeReference(java.lang.String database,
                            java.lang.String ac)
Description copied from interface: ExternalReferences
Removes a reference to an external database. This method should only be used in exceptional cases.

Specified by:
removeReference in interface ExternalReferences


Copyright @ 2003 Mount Sinai School of Medicine. All Rights Reserved.