Save This Page
Home » hibernate-entity-src-20081106 » org.hibernate.tool.hbm2x » [javadoc | source]
org.hibernate.tool.hbm2x
public class: TemplateHelper [javadoc | source]
java.lang.Object
   org.hibernate.tool.hbm2x.TemplateHelper
Helper and wrapper for a Template engine (currently only FreeMarker). Exposes only the essential functions to avoid too much coupling else where.
Nested Class Summary:
public class  TemplateHelper.Templates   
Field Summary
static final  Log log     
protected  Configuration freeMarkerEngine     
protected  SimpleHash context     
Constructor:
 public TemplateHelper() 
Method from org.hibernate.tool.hbm2x.TemplateHelper Summary:
ensureExistence,   getContext,   getOutputDirectory,   getTemplatePrefix,   init,   internalPutInContext,   internalRemoveFromContext,   processString,   processTemplate,   putInContext,   removeFromContext,   setupContext,   templateExists
Methods from java.lang.Object:
equals,   getClass,   hashCode,   notify,   notifyAll,   toString,   wait,   wait,   wait
Method from org.hibernate.tool.hbm2x.TemplateHelper Detail:
 public  void ensureExistence(File destination) 
 protected SimpleHash getContext() 
 public File getOutputDirectory() 
 protected String getTemplatePrefix() 
 public  void init(File outputDirectory,
    String[] templatePaths) 
 protected Object internalPutInContext(String key,
    Object value) 
 protected Object internalRemoveFromContext(String key) 
 public  void processString(String template,
    Writer output) 
 public  void processTemplate(String templateName,
    Writer output) 
    look up the template named templateName via the paths and print the content to the output
 public  void putInContext(String key,
    Object value) 
 public  void removeFromContext(String key,
    Object expected) 
 public  void setupContext() 
 public boolean templateExists(String templateName) 
    Check if the template exists. Tries to search with the templatePrefix first and then secondly without the template prefix.