Difference between Java and Javaw

Key difference: Java is a programming language, which has been influenced by the C language. Java and Javaw are commands used in the Java programming language. The commands are almost identical to each other, with just one difference. Both the commands are mainly used to start Java Runtime Environment. They then load a specified class and hence, start a Java application. The only difference between the two is that java.exe pops up a console window, while javaw.exe does not.

Java is a programming language, which has been influenced by the C language. It derives much of its syntax from C and C++, however it has fewer low-level facilities than either. Java is a general-purpose programming language that is designed to have fewer implementation dependencies as compared to previous languages. It is concurrent, class-based, and an object-oriented language.

Java was developed by James Gosling at Sun Microsystems and was released in 1995. It was originally released as a core component of Sun Microsystems' Java platform.

Java is designed to allow the same code to run on various platforms. i.e., developers are allowed to “write once, run anywhere” (WORA). Hence, Java applications are typically compiled to bytecode. A class file which contains a Java bytecode can then be run on any Java Virtual Machine (JVM). This would be regardless of computer architecture.

Java and Javaw are commands used in the Java programming language. The commands are almost identical to each other, with just one difference. Both the commands are mainly used to start Java Runtime Environment. They then load a specified class and hence, start a Java application.

The only difference between the two is that java.exe pops up a console window, while javaw.exe does not. When the java.exe command is run, a 'Command Prompt' window is opened automatically. Furthermore, Standard Output and Standard Error streams are directed to the console window by default.

The javaw.exe command, on the other hand, does not open a 'Command Prompt' window. Hence, the Standard Output and Standard Error streams are not visible while the program is running. However, if the program launch fails for some reason, then the javaw launcher will display a dialog box with error information. Additionally, when the program is running, the Standard Output and Standard Error streams can be directed to a file by using the methods System.setOut(…) and System.setErr(…).

Image Courtesy: livehacking.com

Most Searched in Society and Culture Most Searched in Games and Recreation
Most Searched in Entertainment and Music Most Searched in Education and References
Samsung Galaxy Note 8.0 vs Samsung Galaxy Note 10.1
Fort vs Fortress
Equations vs Functions
Power Steering vs Electronic Power Steering

Add new comment

Plain text

CAPTCHA
This question is for testing whether or not you are a human visitor and to prevent automated spam submissions.