Java templating