Difference between Java and Javax
Key difference: Java is a programming language, which has been influenced by the C language. Java and Javax are essentially packages that are used with the context of the Java programming language. Practically there is no difference between Java and Javax. It is just the name that differs.
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 Javax are essentially packages that are used with the context of the Java programming language. The command to bring up a java package is import java, while the command to bring up a javax package is import javax. For example: import java.util.*; or import javax.util.*;
Originally, everything that was part of the standard API was part of the java package, whereas everything that was not part of the standard API was released under the package name javax. Hence, packages essential to the API was java, while javax contained the extensions to the API. It can even be said that javax, is just java with an x, which stands for extension.
Over time the extensions that were released as javax, become integral to the Java API. However, moving the extension from the javax package to the java package would be too cumbersome and would end up breaking a bunch of existing code. Hence, eventually it was decided that the javax packages would become part of the standard API.
So, practically there is no difference between Java and Javax. It is all in a name.
Image Courtesy: livehacking.com