Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Is it possible to automatically convert java code to PHP?

Is there are tools for converting java code to php? I have source code of java library and I need it to convert to php.

like image 983
yura Avatar asked May 19 '11 10:05

yura


People also ask

Can we convert Java code to PHP?

Java and PHP are two of the most used programming languages today. Although both technologies offer advanced functionality and dynamic portability, converting one to the other is not quite possible yet.

Can we convert Java code to HTML?

Find and select the JAVA files on your computer and click Open to bring them into Doxillion to convert them to the HTML file format. You can also drag and drop your JAVA files directly into the program to convert them as well.

Can Java be converted to JavaScript?

Designed, developed, and open-sourced by Google, J2CL is a source-to-source compiler that converts Java to Javascript. J2CL developers say the compiler "enables seamless use of Java in your JavaScript applications."


1 Answers

It is possible to automatically convert it. This is called a source to source compiler. Normally when you compile software, the parser will build an abstract syntax tree and convert this into the target machine language code. But it is just as possible to have a compiler convert this into another high level (compilable) language.

Java is a strongly typed language, and PHP is not, so source to source compilers are rare and the code conversion process is incomplete. However this said, there is a reasonably good one with a free demo at: http://javatophp.com

like image 85
Anon Avatar answered Oct 13 '22 00:10

Anon