On Monday, October 20, 2003, at 06:54 PM, Patrick LeBoutillier wrote:
Ken,
This probably means that some code you are using can't find a specific
class. Try putting eval around you script like this see what's going on:
use Inline::Java qw(caught) ;
eval { # ... } ; if ($@){ if (caught("java.lang.Exception")){ # Java exception... my $msg = [EMAIL PROTECTED]>getMessage() ; print($msg . "\n") ; } else{ # It wasn't a Java exception after all... die $@ ; } }
I don't think that works, because this is an Error instead of an Exception. Or something. In any case, I tried to use a $SIG{__DIE__} to get a stack trace, and it didn't work. I presumed the error wasn't trappable.
I'll try it again tomorrow when I'm at work, where the code is.
Let me just make it clear how very awesome Inline::Java is, by the way - it means I can do my research using my colleagues' Java libraries and I still get to use Perl. =) I'm finding the J/P interface extremely well-designed so far, kudos.
-Ken
