Interface....

Can java interface be built for a perl program?Can an applet  be used as front end of a perl program?If it can be used, how?
I would appreciate if someone can answer this question
apaazueAsked:
Who is Participating?
 
jyu_88Commented:
just an user interface to take in user input then use those input as arguments to a perl program, and eventually return the result to the user via the Java interface/applet?
Sounds like html/CGI would be better.

supposedly you should be able to do system call with JDK2.

Lastly, since Java can interface with C or alike (as far as I know), you can at least compile your perl program into a C program...
0
 
apaazueAuthor Commented:
But how to do system callas from java program??
0
Cloud Class® Course: Ruby Fundamentals

This course will introduce you to Ruby, as well as teach you about classes, methods, variables, data structures, loops, enumerable methods, and finishing touches.

 
clockwatcherCommented:
If you're talking about system calls in the normal sense, you can use the java.lang.Runtime class available since JDK 1.0.

E.g.,

public class SampleSystemCall {

  static void main(String args[]) throws java.io.IOException {
     
     Runtime.getRuntime().exec("notepad.exe");

  }
}

But as far as this question goes, to actually answer it with any kind of sense, we really need a better idea of what it is you're trying to do.
0
 
apaazueAuthor Commented:
Am talking about UNIX environment where we get 'a.out'  files which we have to run on commandline. Will the above program work if we give the command
Runtime.getRuntime().exec("perl test.pl");
does the perl program test.pl get executed.  I tried it but it didn't work. I would appreciate if someone can help.
Thank u
0
 
christopher sagayamCommented:
To make things very simple ( but not efficient)

Make a perl script like whatever.pl and DO all system calls using the PERL script

suppose the URL the PERL script is

http://www.some.com/whatever.pl


Just GET the page using JAVA interface PROCESS the output from the page and then proceed to do whatever you want


0
 
apaazueAuthor Commented:
Well! its not a web based application.  Just a program that uses perl due to its power in text manipulation. The issue is the input to the program should come from an interface preferably java.The perl scripts work fine when input is given directly to them but to make the interaction with the tool simple , i need an inetrface. Ihope it makes things much clear//
0
 
clockwatcherCommented:
0
 
apaazueAuthor Commented:
Thanks a lot clockwatcher, i really appreciate it.  I think its the perfect source for me to look into for what ever doubts i will get in this subject.
ThankU
/apaazue
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.