Hi Val,

I'm not sure I understand what you mean.
If you mean returning data to Perl from Java methods, you can do that.

Here is an example:

use Inline Java => <<'END',
    class myclass {
        String data = "my class data" ;

        public myclass(){
        }

        public String get_data(){
            return data ;
        }
    }
END

my $o = new myclass() ;
my $data = $o->get_data() ;


You can also return objects that you have compiled yourself in Inline::Java,
and they will be fully interactive.
You can also return other types, for example java.util.ArrayList or
java.util.HashMap, but then Perl doesn't know about these objects

So they can exist in Perl, but about the only thing you can do with them is
send them back to another Java method. In the future, Inline::Java will be
able to study other classes and learn about them, allowing you
to use all of the native Java classes, or even other classes you might have
written outside Inline::Java.

Cheers,

Patrick

----- Original Message -----
From: "bykovski, val" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Cc: <[EMAIL PROTECTED]>
Sent: Wednesday, March 14, 2001 12:58 PM
Subject: perl/java: 2-way or only 1-way comm


Hi Brian/Patrick/All:

i enjoy playing around with Inline-Java.
(NT 4.0 sp5). Great stuff.  Quick question, though.
Can i pass a data/par from a Java method
back to Perl sript.  I couldn't do this...

Any pointer/advice?

Thanx!

Val Bykovski
800-445-2588 ext. 22202
[EMAIL PROTECTED]
EMC²
Where Information Lives




Reply via email to