I am using a custom API in my plugin and put that .jar file in the lib directory.
but, when i am calling one of the method from that api(library), it is showing “Package does not exist”.
I have also tested by putting the .jars in the plugins directory as well.
But, not working.
I have placed all the lib files in the plugins directory, still it is showing the error that “Package doesn’t exist”, while if i am running a sample java application by using the same libs, it is working fine.
According to the error, it says that it is not getting the Packages in it’s classpath. But i have placed all those libs in the Plugins directory as well in the Lib directory of Servoy root.
Somehow we need a bit more information. What sounds strange is “Package does not exist”. If a class from a jar that is used in a plugin is not found, you should get a Class not found error.
So what have you done in Java and what do you do in Servoy? Where do you see that error etc. Please provide more precise information.
patrick:
What sounds strange is “Package does not exist”. If a class from a jar that is used in a plugin is not found, you should get a Class not found error.
Hi patrick,
It is really sounds interesting. It should show Class not found Error.
patrick:
So what have you done in Java and what do you do in Servoy? Where do you see that error etc. Please provide more precise information.
I have a method called compileObject() in the testPluginProvider class. The compileObject() method uses one library function(from the External JAR) to generate one serialized object and to store in some path, the output path is hard coded for testing purpose.
When I am running the same code by a standalone java application, it is creating the serialized object in the same path. But when I am calling the method from a Plugin, It is showing the Error - “Package doesn’t exit”.
While the JAR is in the Plugins directory of Servoy root.
When you say “it is showing the error” you mean you get an error dialog in Servoy developer? In the console you should see the whole error. Maybe you can post that here and we can help you figure out where it goes wrong.
The question is asked because such a plugin exists, as far as I know . But of course you can go to university, study Java, dig into Jasper reports and do your own.