Have Your Cake and Eat It Too: Meta-Programming Techniques for Java

*
Accepted Session
Short Form
Scheduled: Thursday, June 23, 2011 from 3:45 – 4:30pm in B304

Excerpt

You’ll learn about the techniques needed to transform classes at runtime, adding new behaviors and addressing cross-cutting concerns. The presentation will discuss a new framework for this specific purpose, but also draw examples from the Apache Tapestry web framework, which itself is rich in meta-programming constructs.

Description

Ever been envious of how easily Python, Ruby and even JavaScript can “meta-program”? Meta-programming provides new ways of writing your code that goes beyond traditional object-oriented composition or inheritance. It’s like magic: seemingly simple or innocuous code takes over big responsibilities; new methods appear out of thin air. Your code, your primary code, stays simple and easy to follow.

Now, we know you can do that for scripting languages, but what do we do about Java? With the proper context, it is possible to emulate many of those same capabilities, by applying a simple set of code transformations at runtime. In this session you’ll learn about meta-programming and how it can apply to traditional Java. You’ll learn about the techniques needed to transform classes at runtime, adding new behaviors and addressing cross-cutting concerns. The presentation will discuss a new framework for this specific purpose, but also draw examples from the Apache Tapestry web framework, which itself is rich in meta-programming constructs.

Speaking experience

Speaker

  • Howard basement hands folded square

    Biography

    Howard Lewis Ship cut his teeth writing customer support software in
    PL/1. He made the jump to Object Oriented programming via NeXTSTEP
    and Objective-C before transitioning to Java. He created the initial version of
    Tapestry in early 2000, and is currently working on Apache Tapestry 5.2.

    Howard is respected in the Java community as an expert on web application development, dependency injection, Java meta-programming, and developer productivity. He is a frequent speaker at JavaOne, NoFluffJustStuff, ApacheCon and other conferences, and the author of “Tapestry in Action” for Manning (covering Tapestry 3.0).

    Howard was elected a Java Champion in February 2010.

    Howard is an independent consultant, specializing in Tapestry and Clojure training, mentoring and project work. He lives in Portland, Oregon with his wife Suzanne, a novelist, and his son Jacob.

    Sessions