[ImageJ-devel] [fiji-devel] ImageJ 2.0.0-beta5 released

Johannes Schindelin Johannes.Schindelin at gmx.de
Thu Oct 25 00:36:24 CDT 2012


Hi,

On Wed, 24 Oct 2012, Albert Cardona wrote:

> 2012/10/24 Johannes Schindelin <Johannes.Schindelin at gmx.de>:
> >
> > On Wed, 24 Oct 2012, Albert Cardona wrote:
> >
> >> 2012/10/23 Barry DeZonia <bdezonia at gmail.com>:
> >
> > Note that "IJ" in ImageJ2 scripting refers to the current ImageJ
> > context, i.e. an instance of imagej.ImageJ. It does *not* refer to the
> > static class ij.IJ -- which would not make too much sense anyway,
> > because we are most likely not able to support too many of that class'
> > functions.
>
> the ij.jar is a jar and is included in ImageJ2. I understand it may be
> desirable to intercept some of its functionality such as IJ.log and
> redirect it, but other than that, being a jar, one would except
> beanshell and other scripting languages to load and use jars in the
> classpath as usual.

As in plain Java, if you have a local variable of the same name as a class
you imported, the local variable takes precedence. You can always access
the class by the full class name: ij.IJ.log("Hello, Albert");

I am open to suggestions what might be a better name for the current
ImageJ context (I considered "context", "this", "ImageJ", which all clash
with existing entities even worse than "IJ"). It is still early enough to
change things without much of a hassle.

Ciao,
Johannes



More information about the ImageJ-devel mailing list