context.put(FILENAME, templateFileName);
DomVisit.visit(element, new TemplateDomVisitor(templateFileName));
}
public Object getResult(URL template, String key) {
final Context context = contextMap.get(template);
if (context == null) {
throw new IllegalArgumentException("no context found for template " + template);
}
return context.get(key);
}