[Biojava-dev] Annotation conversions

Len Trigg len at reeltwo.com
Mon Dec 15 17:59:32 EST 2003


Hi folks,

I'd like to add support for BioSQL's comment table to our binding, and
am wondering about the best way to do it. It is obvious that the
comments should just be annotations, my question is more about what key I
should associate the comments with (and should look for when storing
sequences in the database). 

It seems that I could use either "CC" or "COMMENT" and the right thing
would happen most of the time. However, it seems a bit silly to have
to check for both types when persisting comments to the
database. Should there be a "canonical" key that is used for
comments. Then different I/O formats could just check for this one
key, rather than having to do do things like this:

GenbankFileFormer.java:322
        else if (key.equals("CC") || key.equals("COMMENT")) {
            ccb = new StringBuffer(sequenceBufferCreator("COMMENT    ", value));
        }
 

The same also applies to any of the annotations that are shared
between multiple output formats...

Suggestions?


Cheers,
Len.


More information about the biojava-dev mailing list