[Biojava-l] Bytecode generation

Thomas Down td2@sanger.ac.uk
Tue, 10 Oct 2000 12:39:47 +0100

I've just added a Java bytecode generation library to the
biojava-live CVS module.  We couldn't find a complete
bytecode library under LGPL (or compatible), so I've written
a new one -- hopefully it will be useful to non-BioJava projects
as well.

For most purposes, you'll just be able to use the binary
bytecode.jar file, which is in the main CVS module.  If
you want to see the source code, or have a hack around,
the library lives in its own CVS module (`bytecode') in the
Biojava repository.  It's licenced under the same terms
as BioJava.  I'll sort out a proper release in a week or
two, but at the moment the API is a little rough around
the edges.

What's the point of all this?

Right now, the only direct use of this code is to generate
lightweight proxy classes for the Feature system.  These
are used when features are projected from one coordinate
system to another, and previously had to be hand-coded.  The
code for this is in org.biojava.bio.seq.ProjectedFeatureHolder.

In the slightly longer term, we'll also be generating optimized
bytecode for dynamic programming algorithms.  Matthew has had
a prototype of this running, and it seems good.

Potentially there may be other applications in the future --
especially where it's useful to produce lightweight glue
code on the fly.

Happy hacking,

One of the advantages of being disorderly is that one is
constantly making exciting discoveries.
                                       -- A. A. Milne