hiliujunyi / jav8

java wrap v8(javascript)
0 stars 0 forks source link

Exception in thread "main" java.lang.UnsupportedClassVersionError: lu/flier/script/V8ScriptEngineFactory : Unsupported major.minor version 51.0 #23

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
Hi,

I've installed the jav8 as a maven dependency and tried the exemple.

I get the following error. I suppose that I do not have the gooed V8 version, 
but what is the supported version.

Best.

Exception in thread "main" java.lang.UnsupportedClassVersionError: 
lu/flier/script/V8ScriptEngineFactory : Unsupported major.minor version 51.0
    at java.lang.ClassLoader.defineClass1(Native Method)
    at java.lang.ClassLoader.defineClassCond(ClassLoader.java:631)
    at java.lang.ClassLoader.defineClass(ClassLoader.java:615)
    at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:141)
    at java.net.URLClassLoader.defineClass(URLClassLoader.java:283)
    at java.net.URLClassLoader.access$000(URLClassLoader.java:58)
    at java.net.URLClassLoader$1.run(URLClassLoader.java:197)
    at java.security.AccessController.doPrivileged(Native Method)
    at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
    at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
    at java.lang.Class.forName0(Native Method)
    at java.lang.Class.forName(Class.java:247)
    at sun.misc.Service$LazyIterator.next(Service.java:271)
    at javax.script.ScriptEngineManager.initEngines(ScriptEngineManager.java:109)
    at javax.script.ScriptEngineManager.access$000(ScriptEngineManager.java:37)
    at javax.script.ScriptEngineManager$1.run(ScriptEngineManager.java:80)
    at java.security.AccessController.doPrivileged(Native Method)
    at javax.script.ScriptEngineManager.init(ScriptEngineManager.java:78)
    at javax.script.ScriptEngineManager.<init>(ScriptEngineManager.java:51)
    at jab8Test.Main.main(Main.java:9)

Original issue reported on code.google.com by thimw...@gmail.com on 4 Aug 2013 at 10:07

GoogleCodeExporter commented 9 years ago
Me too. Could you pls tell me how can overcome this?

Original comment by detucha...@gmail.com on 12 Nov 2013 at 7:46

GoogleCodeExporter commented 9 years ago
It seems you are using Java 6 or lower version, the jar package was build with 
Java 7 (version 51), I will provide Java 6 package later

J2SE 8 = 52,
J2SE 7 = 51,
J2SE 6.0 = 50,
J2SE 5.0 = 49,
JDK 1.4 = 48,
JDK 1.3 = 47,
JDK 1.2 = 46,
JDK 1.1 = 45

Original comment by flier...@gmail.com on 23 Dec 2013 at 11:23