com.gilt.handlebars

HandlebarsImpl

class HandlebarsImpl extends Handlebars with PartialHelper

Linear Supertypes
Ordering
  1. Alphabetic
  2. By inheritance
Inherited
  1. HandlebarsImpl
  2. PartialHelper
  3. ProgramHelper
  4. Handlebars
  5. AnyRef
  6. Any
  1. Hide All
  2. Show all
Learn more about member selection
Visibility
  1. Public
  2. All

Instance Constructors

  1. new HandlebarsImpl(program: Program, partials: Map[String, Handlebars], helpers: Map[String, Helper])

Value Members

  1. final def !=(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  2. final def !=(arg0: Any): Boolean

    Definition Classes
    Any
  3. final def ##(): Int

    Definition Classes
    AnyRef → Any
  4. final def ==(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  5. final def ==(arg0: Any): Boolean

    Definition Classes
    Any
  6. def apply[T](context: T, data: Map[String, Any] = Map.empty, providedPartials: Map[String, Handlebars] = Map.empty, providedHelpers: Map[String, Helper] = Map.empty): String

    Definition Classes
    HandlebarsImplHandlebars
  7. final def asInstanceOf[T0]: T0

    Definition Classes
    Any
  8. def clone(): AnyRef

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  9. final def eq(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  10. def equals(arg0: Any): Boolean

    Definition Classes
    AnyRef → Any
  11. def filterPartials(node: Node): List[Partial]

    Filters a node and returns all of the Partial nodes contained within it.

    Filters a node and returns all of the Partial nodes contained within it. This method will filter as-is, so if a reference to a partial exists more than once duplicates will appear in the result.

    If a unique list is desired, use toSet on the resulting List.

    node

    usually a Program node result of HandlebarsGrammar

    returns

    List of Partial nodes within node

    Definition Classes
    PartialHelper
  12. def finalize(): Unit

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  13. def findAllPartials(file: File, touchedFiles: List[String] = List.empty): Map[String, File]

    Finds all partials referenced in a file and nested partial includes from THOSE partials.

    Finds all partials referenced in a file and nested partial includes from THOSE partials. Traverses the tree of handlebars partial includes recursively and aggregates the Partials found.

    Maintains a list of files traversed to avoid infinite loops from the recursion.

    TODO: probably should not throw an error, but a warning when a template is not found. A missing template could mean that it may be defined on the frontend.

    file

    file to scan for partials

    touchedFiles

    running list of files that were scanned

    returns

    Map of partialName -> java.io.File

    Definition Classes
    PartialHelper
  14. final def getClass(): Class[_]

    Definition Classes
    AnyRef → Any
  15. def getTemplates(file: File): Map[String, Handlebars]

    Definition Classes
    PartialHelper
  16. def hashCode(): Int

    Definition Classes
    AnyRef → Any
  17. val helpers: Map[String, Helper]

    Definition Classes
    HandlebarsImplHandlebars
  18. final def isInstanceOf[T0]: Boolean

    Definition Classes
    Any
  19. final def ne(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  20. def normalizePartialNames(partials: Map[String, Handlebars]): Map[String, Handlebars]

    Definition Classes
    PartialHelper
  21. final def notify(): Unit

    Definition Classes
    AnyRef
  22. final def notifyAll(): Unit

    Definition Classes
    AnyRef
  23. val partials: Map[String, Handlebars]

    Definition Classes
    HandlebarsImplHandlebars
  24. val program: Program

    Definition Classes
    HandlebarsImplHandlebars
  25. def programFromFile(file: File): Program

    Definition Classes
    ProgramHelper
  26. def programFromString(template: String): Program

    Definition Classes
    ProgramHelper
  27. final def synchronized[T0](arg0: ⇒ T0): T0

    Definition Classes
    AnyRef
  28. def toString(): String

    Definition Classes
    AnyRef → Any
  29. final def wait(): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  30. final def wait(arg0: Long, arg1: Int): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  31. final def wait(arg0: Long): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )

Inherited from PartialHelper

Inherited from ProgramHelper

Inherited from Handlebars

Inherited from AnyRef

Inherited from Any

Ungrouped