io.vertx.reactivex.ext.web.templ

## Class TemplateEngine

- java.lang.Object
- - io.vertx.reactivex.ext.web.common.template.TemplateEngine
  - - io.vertx.reactivex.ext.web.templ.TemplateEngine

-     public class TemplateEngine
      extends TemplateEngine

  A template engine uses a specific template and the data in a routing context to render a resource into a buffer.

  Concrete implementations exist for several well-known template engines.

  NOTE: This class has been automatically generated from the `original` non RX-ified interface using Vert.x codegen.

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `static io.vertx.lang.rx.TypeArg<TemplateEngine>` | `__TYPE_ARG`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `TemplateEngine(Object delegate)`
    `TemplateEngine(TemplateEngine delegate)`

  - ### Method Summary

    All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods
    Modifier and Type | Method and Description
    --- | ---
    `boolean` | `equals(Object o)`
    `TemplateEngine` | `getDelegate()`
    `int` | `hashCode()`
    `boolean` | `isCachingEnabled()` Returns true if the template engine caches template files.
    `static TemplateEngine` | `newInstance(TemplateEngine arg)`
    `void` | `render(RoutingContext context, String templateFileName, Handler<AsyncResult<Buffer>> handler)` Deprecated.
    `void` | `render(RoutingContext context, String templateDirectory, String templateFileName, Handler<AsyncResult<Buffer>> handler)` Deprecated.
    `Single<Buffer>` | `rxRender(RoutingContext context, String templateFileName)` Deprecated.
    `Single<Buffer>` | `rxRender(RoutingContext context, String templateDirectory, String templateFileName)` Deprecated.
    `String` | `toString()`

    - ### Methods inherited from class io.vertx.reactivex.ext.web.common.template.TemplateEngine

      `render, render, rxRender, rxRender`

    - ### Methods inherited from class java.lang.Object

      `clone, finalize, getClass, notify, notifyAll, wait, wait, wait`

- - ### Field Detail

    - #### __TYPE_ARG

          public static final io.vertx.lang.rx.TypeArg<TemplateEngine> __TYPE_ARG

  - ### Constructor Detail

    - #### TemplateEngine

          public TemplateEngine(TemplateEngine delegate)

    - #### TemplateEngine

          public TemplateEngine(Object delegate)

  - ### Method Detail

    - #### toString

          public String toString()

      Overrides:
        `toString` in class `TemplateEngine`

    - #### equals

          public boolean equals(Object o)

      Overrides:
        `equals` in class `TemplateEngine`

    - #### hashCode

          public int hashCode()

      Overrides:
        `hashCode` in class `TemplateEngine`

    - #### getDelegate

          public TemplateEngine getDelegate()

      Overrides:
        `getDelegate` in class `TemplateEngine`

    - #### render

          @Deprecated
          public void render(RoutingContext context,
                                         String templateFileName,
                                         Handler<AsyncResult<Buffer>> handler)

      Deprecated.
      Render the template
      Parameters:
        `context` - the routing context
        `templateFileName` - the template file name to use
        `handler` - the handler that will be called with a result containing the buffer or a failure.

    - #### rxRender

          @Deprecated
          public Single<Buffer> rxRender(RoutingContext context,
                                                     String templateFileName)

      Deprecated.
      Render the template
      Parameters:
        `context` - the routing context
        `templateFileName` - the template file name to use
      Returns:

    - #### render

          @Deprecated
          public void render(RoutingContext context,
                                         String templateDirectory,
                                         String templateFileName,
                                         Handler<AsyncResult<Buffer>> handler)

      Deprecated.
      Render the template

      NOTE if you call method directly (i.e. not using `TemplateHandler`) make sure that templateFileName is sanitized via

      Parameters:
        `context` - the routing context
        `templateDirectory` - the template directory to use
        `templateFileName` - the relative template file name to use
        `handler` - the handler that will be called with a result containing the buffer or a failure.

    - #### rxRender

          @Deprecated
          public Single<Buffer> rxRender(RoutingContext context,
                                                     String templateDirectory,
                                                     String templateFileName)

      Deprecated.
      Render the template

      NOTE if you call method directly (i.e. not using `TemplateHandler`) make sure that templateFileName is sanitized via

      Parameters:
        `context` - the routing context
        `templateDirectory` - the template directory to use
        `templateFileName` - the relative template file name to use
      Returns:

    - #### isCachingEnabled

          public boolean isCachingEnabled()

      Returns true if the template engine caches template files. If false, then template files are freshly loaded each time they are used.
      Overrides:
        `isCachingEnabled` in class `TemplateEngine`
      Returns:
        True if template files are cached; otherwise, false.

    - #### newInstance

          public static TemplateEngine newInstance(TemplateEngine arg)

Copyright © 2021 Eclipse. All rights reserved.