[Bioperl-l] RE: [Open-bio-l] seq namespace method

Matthew Pocock matthew_pocock@yahoo.co.uk
Fri, 19 Jul 2002 00:47:22 +0100


Great Michael,

LifeScienceIdentifier looks good. I'd prefer Identifiable to drop all 
methods except getPreferredIdentifier() and getIdentifiers(). I think 
the other methods duplicate already available information (e.g. 
getAuthority etc can be found by calling 
getPreferredIdentifier().getAuthority() ). Putting functionality/api in 
exactly one place is generaly a good idea. What are your thoughts?

What package would you like to put these classes/interfaces into? An 
existing package, or org.biojava.bio.lsid or org.biojava.bio.program.lsid?

Matthew

Michael L. Heuer wrote:
> Having spent too much time in meetings lately, I felt the need to
> actually code something, and whipped up a java implementation of LSIDs
> based on the discussion here.  Being that this has been a moving target, I
> may not have nailed it exactly right -- I went with containment and the
> idea of a "preferred identifier", eg.
> 
> interface LifeScienceIdentifier extends Immutable {
>   public String getAuthority();
>   public String getNamespace();
>   public Object getObjectId();
>   public Object getVersion();
> 
>   public String asIdentifier();  // authority:namespace:object_id
>   public String asCommonName();  //  namespace:object_id.version
> }
> 
> interface Identifiable {
>   // delegate to preferred
>   public String getAuthority();
>   public String getNamespace();
>   public Object getObjectId();
>   public Object getVersion();
> 
>   public LifeScienceIdentifier getPreferredIdentifier();
>   public boolean hasMultipleIdentifiers();
>   public List getIdentifiers();
> }
> 
> A tarball with implementations, factories, junit tests, etc. is available
> 
> 
>>http://shore.net/~heuermh/lsid-PROPOSAL.tar.gz
> 
> 
>    michael
> 
>