Search code examples
javaperlcall

Call a java class from perl


I would like to call a java class from perl. I usually use the java class from command line to do some processing like:

java com.something.some

Now, I need to call it from inside a perl script.

Could you let me know how I can do it?


Solution

  • This is simple enough - you just use the system command to execute an arbitrary command line, e.g.

    system("java com.something.Some")