|
From: <php...@li...> - 2008-07-17 13:19:06
|
Hi I wondered if somebody could help me out here. I have a java class that has a constructor that takes 2 strings as arguments when I use the class I get the below exception from within my php page. Fatal error: Uncaught [[o:Exception]:"java.lang.Exception: CreateInstance failed: new PDFGenerator([o:PhpParserString], [o:PhpParserString]). Cause: java.lang.InstantiationException: No matching constructor found. Candidates: [public PDFGenerator()] VM: 1.6.0_06@http://java.sun.com/" at: #-5 php.java.bridge.JavaBridge.CreateObject(JavaBridge.java:465) #-4 php.java.bridge.Request.handleRequest(Request.java:447) #-3 php.java.bridge.Request.handleRequests(Request.java:485) #0 /home/barry/workspace/Ditype/Java.inc(265): java_ThrowExceptionProxyFactory->getProxy(1, '@V', false) #1 /home/barry/workspace/Ditype/Java.inc(417): java_Arg->getResult(false) #2 /home/barry/workspace/Ditype/Java.inc(420): java_Client->getWrappedResult(false) #3 /home/barry/workspace/Ditype/Java.inc(602): java_Client->getInternalResult() #4 /home/barry/workspace/Ditype/Java.inc(1956): java_Client->createObject('PDFGenerator', Array) #5 /home/barry/workspace/Ditype/ditype.php(61): Java->Java('PDFGenerator', '/home/barry/wor...', '/home/barry/wor...') #6 in /home/barry/workspace/Ditype/Java.inc on line 228 The constructor is: public void PDFGenerator(String fileName, String pdfFileName){ this.fileName = fileName; this.pdfFileName = pdfFileName; generatePDF(); } And my php calling object is: $pdfGenerator = new Java("PDFGenerator", $foName, $pdfName); I know the class works as it I take the parameters out of the constructor and recompile with a string to print out everything works fine. Thanks for any help. Barry |
|
From: <php...@li...> - 2008-07-17 17:18:31
|
Hi,
> And my php calling object is:
> $pdfGenerator = new Java("PDFGenerator", $foName,
> $pdfName);
what does
echo java_inspect (java("PDFGenerator"));
display?
It it shows only one zero-arg constructor, then you're probably using an old version of your class.
Regards,
Jost Boekemeier
__________________________________________________________
Gesendet von Yahoo! Mail.
Dem pfiffigeren Posteingang.
http://de.overview.mail.yahoo.com
|
|
From: <php...@li...> - 2008-07-18 08:04:49
|
Hi Jost
Thanks for getting back to me.
After a lot of looking into the problem I found that the jvm must have
been caching the old class. I found this by shutting my server down and
then restarting it which didnt fix the problem so I then deleted my
classes and called the php script again. This still didnt fix the
problem so I restarted the server again and found that the class no
longer exsisted so I then proceeded to recompile my classes and then ran
the script again and everything worked fine.
Now I just need to find a way to stop the caching from happening. :)
Thanks
Barry
On Thu, 2008-07-17 at 17:18 +0000,
php...@li... wrote:
> Hi,
>
>
> > And my php calling object is:
> > $pdfGenerator = new Java("PDFGenerator", $foName,
> > $pdfName);
>
>
> what does
>
> echo java_inspect (java("PDFGenerator"));
>
> display?
>
> It it shows only one zero-arg constructor, then you're probably using an old version of your class.
>
>
> Regards,
> Jost Boekemeier
>
>
>
> __________________________________________________________
> Gesendet von Yahoo! Mail.
> Dem pfiffigeren Posteingang.
> http://de.overview.mail.yahoo.com
>
> -------------------------------------------------------------------------
> This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
> Build the coolest Linux based applications with Moblin SDK & win great prizes
> Grand prize is a trip for two to an Open Source event anywhere in the world
> http://moblin-contest.org/redirect.php?banner_id=100&url=/
> _______________________________________________
> php-java-bridge-users mailing list
> php...@li...
> https://lists.sourceforge.net/lists/listinfo/php-java-bridge-users
|
|
From: <php...@li...> - 2008-07-18 11:06:18
|
Hi,
as long as you keep your libraries within the J2EE .war archive, the J2EE server automatically reloads them when you deploy a new version of your software.
Unfortunately this is not possible for all libraries. log4j.jar for example shouldn't be deployed this way, see the section "Web application reloading and static fields in shared libraries" from the tomcat release notes.
Regards,
Jost Boekemeier
__________________________________________________________
Gesendet von Yahoo! Mail.
Dem pfiffigeren Posteingang.
http://de.overview.mail.yahoo.com
|
|
From: <php...@li...> - 2008-07-18 15:06:27
|
Hi We are not using tomcat just plain apache with php. Thanks Barry On Fri, 2008-07-18 at 11:06 +0000, php...@li... wrote: > Hi, > > as long as you keep your libraries within the J2EE .war archive, the J2EE server automatically reloads them when you deploy a new version of your software. > > Unfortunately this is not possible for all libraries. log4j.jar for example shouldn't be deployed this way, see the section "Web application reloading and static fields in shared libraries" from the tomcat release notes. > > > Regards, > Jost Boekemeier > > > > __________________________________________________________ > Gesendet von Yahoo! Mail. > Dem pfiffigeren Posteingang. > http://de.overview.mail.yahoo.com > > ------------------------------------------------------------------------- > This SF.Net email is sponsored by the Moblin Your Move Developer's challenge > Build the coolest Linux based applications with Moblin SDK & win great prizes > Grand prize is a trip for two to an Open Source event anywhere in the world > http://moblin-contest.org/redirect.php?banner_id=100&url=/ > _______________________________________________ > php-java-bridge-users mailing list > php...@li... > https://lists.sourceforge.net/lists/listinfo/php-java-bridge-users |
|
From: <php...@li...> - 2008-07-19 10:12:07
|
Dear plz, solution my coding to handle the error message : java stack trace: java.lang.Exception: Invoke failed: [c(JasperCompileManager)]->compileReport((String)o(String)). Cause: java.lang.ClassNotFoundException: Unresolved external reference: java.lang.NoClassDefFoundError: org/apache/commons/digester/Digester. -- Unable to call the method, see the README section "Java platform issues" for details. Responsible VM: 1.5.0_10@http://java.sun.com/ at php.java.bridge.JavaBridge.getUnresolvedExternalReferenceException(JavaBridge.java:510) at php.java.bridge.JavaBridge.Invoke(JavaBridge.java:1146) at php.java.bridge.Request.handleRequest(Request.java:536) at php.java.bridge.Request.handleRequests(Request.java:582) at php.java.bridge.JavaBridge.run(JavaBridge.java:201) at php.java.bridge.BaseThreadPool$Delegate.run(BaseThreadPool.java:66) Caused by: java.lang.ClassNotFoundException: Unresolved external reference: java.lang.NoClassDefFoundError: org/apache/commons/digester/Digester. -- Unable to call the method, see the README section "Java platform issues" for details. ... 6 more Caused by: java.lang.NoClassDefFoundError: org/apache/commons/digester/Digester at net.sf.jasperreports.engine.JasperCompileManager.compileReport(JasperCompileManager.java:150) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:585) at php.java.bridge.JavaBridge.Invoke(JavaBridge.java:1135) ... 4 more Tq Ism --- On Fri, 7/18/08, php...@li... <php...@li...> wrote: > From: php...@li... <php...@li...> > Subject: Re: [Php-java-bridge-users] Passing phpString Argument > To: php...@li... > Date: Friday, July 18, 2008, 4:05 PM > Hi > > We are not using tomcat just plain apache with php. > > Thanks > > Barry > > On Fri, 2008-07-18 at 11:06 +0000, > php...@li... wrote: > > > Hi, > > > > as long as you keep your libraries within the J2EE > .war archive, the J2EE server automatically reloads them > when you deploy a new version of your software. > > > > Unfortunately this is not possible for all libraries. > log4j.jar for example shouldn't be deployed this way, > see the section "Web application reloading and static > fields in shared libraries" from the tomcat release > notes. > > > > > > Regards, > > Jost Boekemeier > > > > > > > > > __________________________________________________________ > > Gesendet von Yahoo! Mail. > > Dem pfiffigeren Posteingang. > > http://de.overview.mail.yahoo.com > > > > > ------------------------------------------------------------------------- > > This SF.Net email is sponsored by the Moblin Your Move > Developer's challenge > > Build the coolest Linux based applications with Moblin > SDK & win great prizes > > Grand prize is a trip for two to an Open Source event > anywhere in the world > > > http://moblin-contest.org/redirect.php?banner_id=100&url=/ > > _______________________________________________ > > php-java-bridge-users mailing list > > php...@li... > > > https://lists.sourceforge.net/lists/listinfo/php-java-bridge-users > ------------------------------------------------------------------------- > This SF.Net email is sponsored by the Moblin Your Move > Developer's challenge > Build the coolest Linux based applications with Moblin SDK > & win great prizes > Grand prize is a trip for two to an Open Source event > anywhere in the world > http://moblin-contest.org/redirect.php?banner_id=100&url=/ > _______________________________________________ > php-java-bridge-users mailing list > php...@li... > https://lists.sourceforge.net/lists/listinfo/php-java-bridge-users |
|
From: <php...@li...> - 2008-07-21 08:17:54
|
Hi, > reference: java.lang.NoClassDefFoundError: > org/apache/commons/digester/Digester. -- Unable to call the > method, see the README section "Java platform > issues" for details. Responsible VM: > 1.5.0_10@http://java.sun.com/ at the error message above means that there's an open reference from Digester. Which means that you have compiled against a different library version than the one you've deployed (or the external library is simply missing). Please use a standard J2EE server and the standard J2EE deployment tools and please re-read the README section Java platform issues for details. Regards, Jost Boekemeier __________________________________________________________ Gesendet von Yahoo! Mail. Dem pfiffigeren Posteingang. http://de.overview.mail.yahoo.com |
|
From: <php...@li...> - 2008-07-24 02:00:26
|
Dear, I 've been suceessfuly combined PHP+APACHE+IREPORT as I refer to sample from http://charly-clairmont.developpez.com/tutoriels/php-jasper-reports/ which only can produce report in PDF file. I just want to know, is it possible the result report to view in viewer report as in Crystal Report?, may someone help me to solve this problem? Tq Ismail Siregar |
|
From: <php...@li...> - 2008-07-24 15:19:13
|
Hi,
CrystalReports X and above have a Java API, and you should be able to invoke reports through that API.
However, the PHP/Java Bridge has been developed 5 years ago for a pure Java reporting engine; search for "i-net CrystalClear" on the internet.
Regards,
Jost Boekemeier
__________________________________________________________
Gesendet von Yahoo! Mail.
Dem pfiffigeren Posteingang.
http://de.overview.mail.yahoo.com
|