Java is one of the most popular programming languages and the problem comes exactly from this statement.
The problem is that Java is not just a programming language although people have been relating to it as just a language.
Java was never just a language and that’s the reason why I decided to write this tiny article: To wake up the sleepers and remember the forgetters.
The JVM
The Java Virtual Machine is the target machine for every Java application. There are JVM implementations for Windows, Linux, Mac, which means you can run the same Java program on any of the previously referenced operating systems. This is the bright of the JVM: compile-once and run everywhere. This is the fundament of the statement I made on this article’s title.
The heart of Java have always been the JVM. That’s what makes Java not just a programming language, but a giant platform.
The Java language is decoupled from the JVM. The JVM is not bound to the Java language syntax because it doesn’t even understand none of that. The JVM only understands bytecode. It doesn’t even care about the compiler you are using as long as it gets bytecode to execute. Clearly the bytecode evolves as the Java language evolves.
The decoupling of the Java language from the JVM brings the possibility of creating new programming languages. This possibility is already being explored and probably a new JVM language is being created as I type (joke).
JVM languages are coming up, many of them as protests to the slow Java language evolution and its heavy verbosity.
Jetbrains for example is investing on a new JVM language named “Kotlin“. The bigger JVM languages names currently are: Scala and Groovy, Kotlin is on its way.
The point of this article is to make it clear that “programming for Java is not exactly programming in Java“. You can program for Java in Scala, Groovy, Kotlyn or any other JVM language including the Java language. Programming for Java means programming for the Java platform: the JVM, while programming in Java means to use exclusively the Java programming language to program for JAVA.
If you can code in Groovy then you can consider yourself a Java coder cause you can write code that runs on Java.
Have you heard of.Net? If so, then, the same rules apply. If you can code in VB.net or C# then you are a .Net developer. But .net is not about bytecode and is out of this article’s scope.
Thank you for reading, please share the article.
It’s always a pleasure.







Comentários Recentes