Perl + Java

Discussion in 'Perl Misc' started by corrieknor@hotmail.com, Jan 18, 2007.

  1. Guest

    Is it possible to call a java program from within my perl code and use
    the return value from the java program in my perl program?

    Thanks in advance
    Corrie
     
    , Jan 18, 2007
    #1
    1. Advertising

  2. Guest

    Also: The Perl script should parse a paramter to the Java application
     
    , Jan 18, 2007
    #2
    1. Advertising

  3. Paul Lalli Guest

    wrote:
    > Is it possible to call a java program from within my perl code and use
    > the return value from the java program in my perl program?


    Yes.

    perldoc -f system

    Paul Lalli
     
    Paul Lalli, Jan 18, 2007
    #3
  4. Guest

    "Paul Lalli" <> wrote:
    > wrote:
    > > Is it possible to call a java program from within my perl code and use
    > > the return value from the java program in my perl program?

    >
    > Yes.
    >
    > perldoc -f system


    Or Inline::Java

    Xho

    --
    -------------------- http://NewsReader.Com/ --------------------
    Usenet Newsgroup Service $9.95/Month 30GB
     
    , Jan 18, 2007
    #4
  5. Guest

    On Jan 18, 10:08 am, Michele Dondi <> wrote:
    > On 18 Jan 2007 05:06:04 -0800, wrote:
    >
    > >Is it possible to call a java program from within my perl code and use
    > >the return value from the java program in my perl program?Yes. More precisely you can use system() to run a program regardless

    > of the language it is written in, and inspect its return value to find
    > the exit status - remember that you will have to shift it right by
    > eight for the actual one.
    >
    > Michele


    Isnt system somewhat of an expensive call?
     
    , Jan 18, 2007
    #5
  6. J. Gleixner Guest

    wrote:
    >
    > On Jan 18, 10:08 am, Michele Dondi <> wrote:
    >> On 18 Jan 2007 05:06:04 -0800, wrote:
    >>
    >>> Is it possible to call a java program from within my perl code and use
    >>> the return value from the java program in my perl program?Yes. More precisely you can use system() to run a program regardless

    >> of the language it is written in, and inspect its return value to find
    >> the exit status - remember that you will have to shift it right by
    >> eight for the actual one.
    >>
    >> Michele

    >
    > Isnt system somewhat of an expensive call?
    >

    It's on sale this week and this week only. :)
     
    J. Gleixner, Jan 19, 2007
    #6
  7. >>>>> "k" == krakle <> writes:

    k> Isnt system somewhat of an expensive call?

    It's probably a safe bet that someone invoking Java from Perl is not
    likely to be terribly concerned with the overhead of system().

    Charlton


    --
    Charlton Wilbur
     
    Charlton Wilbur, Jan 19, 2007
    #7
  8. Guest

    Michele Dondi wrote:
    > On 18 Jan 2007 06:26:40 -0800, wrote:
    >
    > >Also: The Perl script should parse a paramter to the Java application

    >
    > What does this mean?
    >
    >
    > Michele
    > --

    The perl script should call the java appl. with a parameter. This
    parameter is used in the Java appl. to look something up and return
    this to the perl scripy
     
    , Jan 19, 2007
    #8
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. dpackwood
    Replies:
    3
    Views:
    1,861
  2. /usr/ceo
    Replies:
    32
    Views:
    1,956
    Mark Space
    Sep 15, 2008
  3. PerlFAQ Server

    FAQ 1.4 What are Perl 4, Perl 5, or Perl 6?

    PerlFAQ Server, Jan 23, 2011, in forum: Perl Misc
    Replies:
    0
    Views:
    331
    PerlFAQ Server
    Jan 23, 2011
  4. PerlFAQ Server
    Replies:
    0
    Views:
    724
    PerlFAQ Server
    Feb 3, 2011
  5. PerlFAQ Server

    FAQ 1.4 What are Perl 4, Perl 5, or Perl 6?

    PerlFAQ Server, Feb 27, 2011, in forum: Perl Misc
    Replies:
    0
    Views:
    322
    PerlFAQ Server
    Feb 27, 2011
Loading...

Share This Page