Java: Difference between revisions

From Braindump
Jump to navigation Jump to search
No edit summary
 
No edit summary
 
(3 intermediate revisions by the same user not shown)
Line 1: Line 1:
Invented in the '90-ies by SUN Microsystems, intended for interactive television.
=== Java Versions ===
Invented in the '90-ies by SUN Microsystems, intended for interactive television. SUN Microsystems acquired by Oracle, license for large enterprises are now charged per virtual machine or for each virtual core supporting the JVM. This applies to Oracle Java and not to the reference implementation OpenJDK, which is open and free to use following the opensource license.
 
JRE tools including standard libraries and runtime JVM virtual machine
 
JDK compiles into JAVA bytecode.
 
Java versions are weird, Java2 had versions 1 to 8, where 8 is the last version received vulnerability fixes.
 
Then LTS versions are 11, 17, 21, 25 ... bytecode follows internal numbering is like 68. Version sensitive, has to be within range. That makes JAVA difficult to update. Code may not always be forward compatible.  


SE Standard Edition
SE Standard Edition
Line 6: Line 15:


ME Micro Edition / JAVA Applets were discontinued
ME Micro Edition / JAVA Applets were discontinued
SUN Microsystems acquired by Oracle, license for large companies are now charged per virtual machine.
SUN Microsystems acquired by Oracle, license for large companies are now charged per virtual machine.


=== Alternatives ===
OpenJDK builds: Microsoft, IBM, Redhat, SAP, Azul, etc
OpenJDK builds: Microsoft, IBM, Redhat, SAP, Azul, etc


<nowiki>https://docs.microsoft.com/en-us/java/openjdk/download</nowiki>


with a JRE runtime and JDK compiles
Eclipse Adoptium, Temurin-11.0.15+10" JAVA_VERSION="11.0.15" JAVA_VERSION_DATE="2022-04-19"


=== Structure ===
.java is the source code, needs to have the same name as the class it defines and in the directory mentioned in the package
.java is the source code, needs to have the same name as the class it defines and in the directory mentioned in the package


Line 19: Line 30:


.jar is a zip file with classes
.jar is a zip file with classes
JAVA_HOME


JAVA_HOME
JAVA_HOME
Line 26: Line 38:
JDK_HOME
JDK_HOME


Alternatives
=== Derive Languages ===
 
Kotlin, Scala, Groovy, Ruby
google, ibm, microsoft implementations
 
language
vm, memory, bytecode


java
=== Build tools ===
scala
ANT
ruby
groovy


licensing
Maven


object oriented class
Gradle


=== object oriented class ===
  /com/janmg/hello.java
  /com/janmg/hello.java
  package com.janmg
  package com.janmg

Latest revision as of 10:04, 29 January 2026

Java Versions

Invented in the '90-ies by SUN Microsystems, intended for interactive television. SUN Microsystems acquired by Oracle, license for large enterprises are now charged per virtual machine or for each virtual core supporting the JVM. This applies to Oracle Java and not to the reference implementation OpenJDK, which is open and free to use following the opensource license.

JRE tools including standard libraries and runtime JVM virtual machine

JDK compiles into JAVA bytecode.

Java versions are weird, Java2 had versions 1 to 8, where 8 is the last version received vulnerability fixes.

Then LTS versions are 11, 17, 21, 25 ... bytecode follows internal numbering is like 68. Version sensitive, has to be within range. That makes JAVA difficult to update. Code may not always be forward compatible.

SE Standard Edition

EE Enterprise Editions, adds tools and classes

ME Micro Edition / JAVA Applets were discontinued SUN Microsystems acquired by Oracle, license for large companies are now charged per virtual machine.

Alternatives

OpenJDK builds: Microsoft, IBM, Redhat, SAP, Azul, etc

https://docs.microsoft.com/en-us/java/openjdk/download

Eclipse Adoptium, Temurin-11.0.15+10" JAVA_VERSION="11.0.15" JAVA_VERSION_DATE="2022-04-19"

Structure

.java is the source code, needs to have the same name as the class it defines and in the directory mentioned in the package

.class compile java class, this can be run in the runtime.

.jar is a zip file with classes JAVA_HOME

JAVA_HOME

JRE_HOME

JDK_HOME

Derive Languages

Kotlin, Scala, Groovy, Ruby

Build tools

ANT

Maven

Gradle

object oriented class

/com/janmg/hello.java
package com.janmg
static void main(args)
{
   System.out.println("Hello World");
}
javac -cp / /com/janmg/hello.java
java -cp . hello

Maven

LOG4J