Login  Register

Re: UnsupportedClassVersionError

Posted by ctrueden on Feb 27, 2009; 6:21pm
URL: http://imagej.273.s1.nabble.com/UnsupportedClassVersionError-tp3693514p3693522.html

Hi Bill,

Couldn't Joris also just update his ImageJ to the newest version with the
> newest version of Java?
>

Yep, but if he wants to distribute his plugin bundle to other people, who
may not have the latest Java with their ImageJ, some of them will inevitably
complain to him that they are receiving a cryptic error about
UnsupportedClassVersionError. :-)

-Curtis


On Fri, Feb 27, 2009 at 11:57 AM, Bill Mohler <[hidden email]>wrote:

> Couldn't Joris also just update his ImageJ to the newest version with the
> newest version of Java?
>
> Bill
>
>
>
> At 11:39 AM -0600 2/27/09, Curtis Rueden wrote:
>
>> Hi Joris,
>>
>> The UnsupportedClassVersionError means that ImageJ is using an older
>> version
>> of Java than the one used to compile the
>> plugin. Can you recompile all of your plugins in Eclipse setting the
>> target
>> Java version to 1.4? Or if you do not have the original source, you could
>> try applying Retroweaver to your classes to make them 1.4-compatible:
>> http://retroweaver.sourceforge.net/
>>
>> -Curtis
>>
>> On Fri, Feb 27, 2009 at 11:34 AM, joris meys <[hidden email]> wrote:
>>
>>   Dear all,
>>>
>>>  I have a plugin that worked fine until I added another class to the jar
>>>  file. That other class is actually another plugin that has to be bundled
>>>  with mine, but nothing from that class is used in the rest of the code.
>>>  Actually, I didn't change a thing in the code of my plugin.
>>>
>>>  Yet, this new bundle runs fine within ImageJ in Eclipse, but not anymore
>>>  with the other ImageJ I have on my computer. And when I run it on
>>> another
>>>  computer, it throws an UnsupportedClassVersionError.
>>>
>>>  As I didn't change anything in the original code, I'm a bit puzzled
>>> about
>>>  how this came about. Anybody has a clue?
>>>
>>>  Kind regards
>>>  Joris
>>>
>>>