You could do this (although it is likely to be impractical): avoid writing java code altogether.
Use a language with better abstraction features like Scala or Clojure. Those two compile
to JVM bytecode so you could still use them in your java project.