This class is used for controlling all template
operations. This class uses a parser created
by JavaCC to create an AST that is subsequently
traversed by a Visitor.
// set up and initialize Velocity before this code block
Template template = Velocity.getTemplate("test.wm");
Context context = new VelocityContext();
context.put("foo", "bar");
context.put("customer", new Customer());
template.merge(context, writer);
// set up and initialize Velocity before this code block Template template = Velocity.getTemplate("test.wm"); Context context = new VelocityContext(); context.put("foo", "bar"); context.put("customer", new Customer()); template.merge(context, writer);