Chapter 12. Java.next

 

This chapter covers

  • Generating objects on the fly with proxy
  • Clojure gen-class and GUI programming
  • Clojure’s relationship to Java arrays
  • Interfaces that all Clojure functions implement
  • Using Clojure data structures in Java APIs
  • Using definterface
  • Exceptions

Regardless of your views on the Java language, it’s difficult to deny that the JVM is a stellar piece of software. The confluence of the just-in-time (JIT) compiler, garbage collection, HotSpot, and the flexible bytecode have created an environment in which many programmers have chosen to grow their alternative programming languages. Additionally, the deluge of library options hosted on the JVM further makes the JVM the language target of choice. From Clojure to Groovy to Scala to Fantom to Frink to Rhino to Jess to JRuby to Jython, there seems to be no lack of options for the enthusiastic polyglot programmer. We may soon see job listings for “JVM programmers.” But where does that leave Java the programming language?

Java the language isn’t dead.

12.1. Generating objects on the fly with proxy

12.2. Clojure gen-class and GUI programming

12.3. Clojure’s relationship to Java arrays

12.4. All Clojure functions implement ...

12.5. Using Clojure data structures in Java APIs

12.6. The definterface macro

12.7. Be wary of exceptions

12.8. Summary