Interface HamletSpec.HeadMisc

All Superinterfaces:
HamletSpec._Object, HamletSpec._Script
All Known Subinterfaces:
HamletSpec._Head, HamletSpec._Html, HamletSpec.HEAD, HamletSpec.HTML
All Known Implementing Classes:
Hamlet, Hamlet.HEAD, Hamlet.HTML, HtmlBlock.Block, HtmlPage.Page
Enclosing class:
HamletSpec

public static interface HamletSpec.HeadMisc extends HamletSpec._Script, HamletSpec._Object
%head.misc
  • Method Details

    • style

      Add a style element.
      Returns:
      a style element builder
    • style

      HamletSpec.HeadMisc style(Object... lines)
      Add a css style element.
      Parameters:
      lines - content of the style sheet
      Returns:
      the current element builder
    • meta

      Add a meta element.
      Returns:
      a meta element builder
    • meta

      HamletSpec.HeadMisc meta(String name, String content)
      Add a meta element. Shortcut of meta().$name(name).$content(content).__();
      Parameters:
      name - of the meta element
      content - of the meta element
      Returns:
      the current element builder
    • meta_http

      HamletSpec.HeadMisc meta_http(String header, String content)
      Add a meta element with http-equiv attribute. Shortcut of
      meta().$http_equiv(header).$content(content).__();
      Parameters:
      header - for the http-equiv attribute
      content - of the header
      Returns:
      the current element builder
    • link

      Add a link element.
      Returns:
      a link element builder
    • link

      Add a link element. Implementation should try to figure out type by the suffix of href. So link("style.css"); is a shortcut of link().$rel("stylesheet").$type("text/css").$href("style.css").__();
      Parameters:
      href - of the link
      Returns:
      the current element builder