UF 06: JAVA¶

Architecture and tools¶

Alta Formazione Professionale - ITT Marconi

January 2021

Why Java¶

widely adopted

platform independent

web server, analytics, mobile (Android)

Java: many versions¶

java-versions.png

Source: Wikipedia

Usage by version¶

java-usage-by-version.png

Source: New Relic - State of Java

Vendors¶

java-vendors.png

Source: New Relic - State of Java

Which one?¶

at work

  • tried-and-tested LTS versions (8, 11)
  • vendor: somebody to call when you have problems

in these classes

  • latest-and-greatest (v15 as of Jan 2021)
  • vendor: AdoptOpenJDK

Selecting the right Java version / vendor is very important

Please read Java Versions and Features by Marco Behler

Java language¶

object oriented

strongly typed

write once, run anywhere (WORA)

designed for writing large programs

  • lately also supports scripting ($\geq$ Java 9)

imperative paradigm

  • lately also functional ($\geq$ Java 8)

verbose

  • lately more concise, i.e. streams ($\geq$ Java 8), records ($\geq$ Java 14), ...

Architecture¶

Java is multiplatform

source code .java

bytecode .class

java archive .jar (optional)

Java Runtime Environment (JRE) / Java Development Kit (JDK)

  • virtual machine (JVM)

  • JIT / AOT compilation

CPU code

Tools¶

Netbeans

  • Desktop IDE
  • I installed the 12.2 version, supports latest Java 15 features
  • Maven build system natively supported

repl.it

  • online IDE
  • collaborative
  • supports Java 11 (as of Jan 2021)

pythontutor.com/java.html

  • online
  • visual debugger
  • supports Java 8 (as of Jan 2021)

other desktop IDEs:¶

  • Eclipse
  • IntelliJ
  • AndroidStudio (based on IntelliJ)

build systems¶

Ant

Maven

Gradle

Bazel

...

Each IDE has its own and can optionally use others

Users and Groups - JAVA¶

Write your REPL user here:

Link¶