Package: io.vertx.groovy.ext.web.handler

## [Groovy] Class TemplateHandler

- io.vertx.groovy.ext.web.handler.TemplateHandler

- All Implemented Interfaces and Traits:
    Handler

      @CompileStatic
      class TemplateHandler

  A handler which renders responses using a template engine and where the template name is selected from the URI path.

- - ### Constructor Summary

    Constructors
    Constructor and description
    `TemplateHandler (Object delegate)`

  - ### Methods Summary

    Methods
    Type | Name and description
    --- | ---
    `static TemplateHandler` | `create(TemplateEngine engine)` Create a handler
    `static TemplateHandler` | `create(TemplateEngine engine, String templateDirectory, String contentType)` Create a handler
    `Object` | `getDelegate()`
    `void` | `handle(RoutingContext arg0)`

  - ### Inherited Methods Summary

    Inherited Methods
    Methods inherited from class | Name
    --- | ---
    `class Object` | `wait, wait, wait, equals, toString, hashCode, getClass, notify, notifyAll`

- - ### Constructor Detail

    - #### TemplateHandler(Object delegate)

  - ### Method Detail

    - #### static TemplateHandler create(TemplateEngine engine)

      Create a handler

      Returns:
        the handler
      Parameters:
        `engine` - the template engine

    - #### static TemplateHandler create(TemplateEngine engine, String templateDirectory, String contentType)

      Create a handler

      Returns:
        the handler
      Parameters:
        `engine` - the template engine
        `templateDirectory` - the template directory where templates will be looked for
        `contentType` - the content type header to be used in the response

    - #### Object getDelegate()

    - #### void handle(RoutingContext arg0)