Archived

This topic is now archived and is closed to further replies.

How dya call Perl from Java?

This topic is 5146 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I want to have my java program execute a perl script. Is there any better way to do it than just issue a command line call something like this: Runtime.getRuntime().exec("perl myScript.pl"); ? (actually, im not even sure if that would work, but I think so) Ive searched a lot for the answer, but all I find is how to execute JAVA from PERL, which is the opposite of what I want.

Share this post


Link to post
Share on other sites

public class Test {
public static void main(String[] args) {
Perl has a C API.
Java can call C.
}
}


It won't compile for some stupid reason.


Just kiddin

But I dont suppose someone knows where I can find a sample of this in action?

[edited by - AndreTheGiant on November 13, 2003 1:18:29 PM]

Share this post


Link to post
Share on other sites
For all Perl questions, see CPAN.
A 10 second search yielded this.
( CPAN->Perl Core Docs->PODS->4th entry )


[ Start Here ! | How To Ask Smart Questions | Recommended C++ Books | C++ FAQ Lite | Function Ptrs | CppTips Archive ]
[ Header Files | File Format Docs | LNK2001 | C++ STL Doc | STLPort | Free C++ IDE | Boost C++ Lib | MSVC6 Lib Fixes ]

Share this post


Link to post
Share on other sites