|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectgroovy.text.TemplateEngine
org.codehaus.groovy.grails.support.ResourceAwareTemplateEngine
public abstract class ResourceAwareTemplateEngine
An abstract TemplateEngine that extends the default Groovy TemplateEngine (@see groovy.text.TemplateEngine) and provides the ability to create templates from the Spring Resource API
| Constructor Summary | |
|---|---|
ResourceAwareTemplateEngine()
|
|
| Method Summary | |
|---|---|
groovy.text.Template |
createTemplate(File file)
|
abstract groovy.text.Template |
createTemplate(InputStream inputStream)
Unlike groovy.text.TemplateEngine, implementors need to provide an implementation that operates with an InputStream |
groovy.text.Template |
createTemplate(Reader reader)
|
groovy.text.Template |
createTemplate(Resource resource)
Creates the specified Template using the given Spring Resource |
abstract groovy.text.Template |
createTemplate(Resource resource,
boolean cacheable)
Creates the specified Template using the given Spring Resource |
groovy.text.Template |
createTemplate(String templateText)
|
groovy.text.Template |
createTemplate(URL url)
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public ResourceAwareTemplateEngine()
| Method Detail |
|---|
public groovy.text.Template createTemplate(Resource resource)
throws IOException,
ClassNotFoundException
resource - The Spring Resource to create the template for
IOException - Thrown when there was an error reading the Template
ClassNotFoundException - Thrown when there was a problem loading the Template into a class
public abstract groovy.text.Template createTemplate(Resource resource,
boolean cacheable)
resource - The Spring Resource to create the template forcacheable - Whether the resource can be cached
IOException - Thrown when there was an error reading the Template
ClassNotFoundException - Thrown when there was a problem loading the Template into a class
public final groovy.text.Template createTemplate(Reader reader)
throws IOException
createTemplate in class groovy.text.TemplateEngineIOException
public abstract groovy.text.Template createTemplate(InputStream inputStream)
throws IOException
inputStream - The InputStream
IOException - Thrown when an IO error occurs reading the stream
public groovy.text.Template createTemplate(String templateText)
throws org.codehaus.groovy.control.CompilationFailedException,
ClassNotFoundException,
IOException
createTemplate in class groovy.text.TemplateEngineorg.codehaus.groovy.control.CompilationFailedException
ClassNotFoundException
IOException
public groovy.text.Template createTemplate(File file)
throws org.codehaus.groovy.control.CompilationFailedException,
ClassNotFoundException,
IOException
createTemplate in class groovy.text.TemplateEngineorg.codehaus.groovy.control.CompilationFailedException
ClassNotFoundException
IOException
public groovy.text.Template createTemplate(URL url)
throws org.codehaus.groovy.control.CompilationFailedException,
ClassNotFoundException,
IOException
createTemplate in class groovy.text.TemplateEngineorg.codehaus.groovy.control.CompilationFailedException
ClassNotFoundException
IOException
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||