[sip-comm-dev] RE: java.lang.IllegalAccessError


#1

Hi,
I hope you can help me out here. I'm a student hoping to add a video on
demand service to the sip communicator but I've battled to solve the
following exception. The code works well standalone and uses java-gstreamer.
I get the following exception at runtime:

13:13:32.358 SEVERE: util.UtilActivator.
uncaughtException().76 An uncaught exception occurred in
thread=Thread[AWT-EventQueue-0,6,main] and message was: class
sun.reflect.GeneratedConstructorAccessor3 cannot access its superclass
sun.reflect.ConstructorAccessorImpl

java.lang.IllegalAccessError: class
sun.reflect.GeneratedConstructorAccessor3 cannot access its superclass
sun.reflect.ConstructorAccessorImpl
        at sun.misc.Unsafe.defineClass(Native Method)
        at sun.reflect.ClassDefiner.defineClass(ClassDefiner.java:45)
        at
sun.reflect.MethodAccessorGenerator$1.run(MethodAccessorGenerator.java:381)
        at java.security.AccessController.doPrivileged(Native Method)
        at
sun.reflect.MethodAccessorGenerator.generate(MethodAccessorGenerator.java:377)
        at
sun.reflect.MethodAccessorGenerator.generateConstructor(MethodAccessorGenerator.java:76)
        at
sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:30)
        at
sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
        at java.lang.reflect.Constructor.newInstance(Constructor.java:513)
        at java.lang.reflect.Proxy.newProxyInstance(Proxy.java:588)
        at org.gstreamer.lowlevel.GNative.loadNativeLibrary(GNative.java:65)
        at org.gstreamer.lowlevel.GNative.loadLibrary(GNative.java:45)
        at org.gstreamer.lowlevel.GstNative.load(GstNative.java:42)
        at org.gstreamer.lowlevel.GstNative.load(GstNative.java:39)
        at org.gstreamer.MessageType.<init>(MessageType.java:130)
        at org.gstreamer.MessageType.<clinit>(MessageType.java:65)
        at java.lang.Class.forName0(Native Method)
        at java.lang.Class.forName(Class.java:169)
        at org.gstreamer.$Proxy13.<clinit>(Unknown Source)
        at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native
Method)
        at
sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
        at
sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
        at java.lang.reflect.Constructor.newInstance(Constructor.java:513)
        at java.lang.reflect.Proxy.newProxyInstance(Proxy.java:588)
        at com.sun.jna.Native.loadLibrary(Native.java:263)
        at org.gstreamer.lowlevel.GNative.loadNativeLibrary(GNative.java:48)
        at org.gstreamer.lowlevel.GNative.loadLibrary(GNative.java:45)
        at org.gstreamer.lowlevel.GstNative.load(GstNative.java:42)
        at org.gstreamer.lowlevel.GstNative.load(GstNative.java:39)
        at org.gstreamer.Message.<clinit>(Message.java:54)
        at java.lang.Class.forName0(Native Method)
        at java.lang.Class.forName(Class.java:169)
        at $Proxy3.<clinit>(Unknown Source)
        at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native
Method)
        at
sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
        at
sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
        at java.lang.reflect.Constructor.newInstance(Constructor.java:513)
        at java.lang.reflect.Proxy.newProxyInstance(Proxy.java:588)
        at com.sun.jna.Native.loadLibrary(Native.java:263)
        at org.gstreamer.lowlevel.GNative.loadNativeLibrary(GNative.java:48)
        at org.gstreamer.lowlevel.GNative.loadLibrary(GNative.java:45)
        at org.gstreamer.lowlevel.GstNative.load(GstNative.java:42)
        at org.gstreamer.lowlevel.GstNative.load(GstNative.java:39)
        at org.gstreamer.Element.<clinit>(Element.java:70)
        at
org.gstreamer.swing.VideoComponent.<init>(VideoComponent.java:121)
        at org.gstreamer.swing.VideoPlayer.<init>(VideoPlayer.java:68)
        at
net.java.sip.communicator.impl.vodClient.vodClientImpl$9.actionPerformed(vodClientImpl.java:343)
        at
javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:1995)
        at
javax.swing.AbstractButton$Handler.actionPerformed(AbstractButton.java:2318)
        at
javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:387)
        at
javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:242)
        at
javax.swing.plaf.basic.BasicButtonListener.mouseReleased(BasicButtonListener.java:236)
        at java.awt.Component.processMouseEvent(Component.java:6263)
        at javax.swing.JComponent.processMouseEvent(JComponent.java:3267)
        at java.awt.Component.processEvent(Component.java:6028)
        at java.awt.Container.processEvent(Container.java:2041)
        at java.awt.Component.dispatchEventImpl(Component.java:4630)
        at java.awt.Container.dispatchEventImpl(Container.java:2099)
        at java.awt.Component.dispatchEvent(Component.java:4460)
        at
java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4574)
        at
java.awt.LightweightDispatcher.processMouseEvent(Container.java:4238)
        at java.awt.LightweightDispatcher.dispatchEvent(Container.java:4168)
        at java.awt.Container.dispatchEventImpl(Container.java:2085)
        at java.awt.Window.dispatchEventImpl(Window.java:2475)
        at java.awt.Component.dispatchEvent(Component.java:4460)
        at java.awt.EventQueue.dispatchEvent(EventQueue.java:599)
        at
java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:269)
        at
java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:184)
        at
java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:174)
        at
java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:169)
        at
java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:161)
        at java.awt.EventDispatchThread.run(EventDispatchThread.java:122)

The entry to the build xml file I created for the project is as follows.

<target name="bundle-vodClient">
        <jar compress="false" destfile="${bundles.dest}/vodClient.jar"

manifest="${src}/net/java/sip/communicator/impl/vodClient/vodClient.manifest.mf">
           <zipfileset
dir="${dest}/net/java/sip/communicator/service/vodClient"
                prefix="net/java/sip/communicator/service/vodClient"/>
           <zipfileset
dir="${dest}/net/java/sip/communicator/impl/vodClient"
                prefix="net/java/sip/communicator/impl/vodClient"/>
            <zipfileset src="${lib.noinst}/jna.jar" prefix=""/>
            <zipfileset src="lib/rt.jar" prefix=""/>
            <zipfileset src="${lib.noinst}/gstreamer-java-1.3.jar"
prefix=""/>
            </jar>
    </target>

The error occours when I run the following line of code:

player = new org.gstreamer.swing.VideoPlayer(mediaPlayer); in the
vodClientImpl class. Can you help?

···

--
Success is the gradual realisation of worthwhile, personal goals.