org.fusesource.scalate

DefaultRenderContext

class DefaultRenderContext extends RenderContext

Default implementation of RenderContext

Linear Supertypes
RenderContext, AnyRef, Any
Known Subclasses
Ordering
  1. Alphabetic
  2. By inheritance
Inherited
  1. Hide All
  2. Show all
  1. DefaultRenderContext
  2. RenderContext
  3. AnyRef
  4. Any
Visibility
  1. Public
  2. All

Instance Constructors

  1. new DefaultRenderContext (_requestUri: String, engine: TemplateEngine, out: PrintWriter)

Type Members

  1. case class Unescaped (text: String) extends Product with Serializable

    Used to represent some text which does not need escaping

Value Members

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

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

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

    Attributes
    final
    Definition Classes
    AnyRef → Any
  4. def << (v: Any): Unit

    Renders the provided value and inserts it into the final rendered document without sanitizing the value.

    Renders the provided value and inserts it into the final rendered document without sanitizing the value.

    Definition Classes
    DefaultRenderContextRenderContext
  5. def <<< (v: Any): Unit

    Renders the provided value, sanitizes any XML special characters and inserts it into the final rendered document.

    Renders the provided value, sanitizes any XML special characters and inserts it into the final rendered document.

    Definition Classes
    DefaultRenderContextRenderContext
  6. def == (arg0: AnyRef): Boolean

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

    Attributes
    final
    Definition Classes
    Any
  8. def asInstanceOf [T0] : T0

    Attributes
    final
    Definition Classes
    Any
  9. def attribute [T] (name: String): T

    Returns the attribute of the given type or a org.fussesource.scalate.NoValueSetException exception is thrown

    Returns the attribute of the given type or a org.fussesource.scalate.NoValueSetException exception is thrown

    Definition Classes
    RenderContext
  10. def attributeKeys : List[String]

    Sorted list of attribute keys

    Sorted list of attribute keys

    Definition Classes
    RenderContext
  11. def attributeOrElse [T] (name: String, defaultValue: ⇒ T): T

    Returns the attribute of the given name and type or the default value if it is not available

    Returns the attribute of the given name and type or the default value if it is not available

    Definition Classes
    RenderContext
  12. val attributes : AttributeMap

    Access the attributes available in this context

    Access the attributes available in this context

    Definition Classes
    DefaultRenderContextRenderContext
  13. def blankString : String

    Attributes
    protected
    Definition Classes
    RenderContext
  14. def capture (template: Template): String

    Evaluates the template capturing any output written to this page context during the body evaluation

    Evaluates the template capturing any output written to this page context during the body evaluation

    Definition Classes
    DefaultRenderContextRenderContext
  15. def capture (body: ⇒ Unit): String

    Evaluates the body capturing any output written to this page context during the body evaluation

    Evaluates the body capturing any output written to this page context during the body evaluation

    Definition Classes
    DefaultRenderContextRenderContext
  16. def captureAttribute (name: String)(body: ⇒ Unit): Unit

    Captured the body of the function call then sets it to the given attribute value

    Captured the body of the function call then sets it to the given attribute value

    Definition Classes
    RenderContext
  17. def captureAttributeAppend (name: String)(body: ⇒ Unit): Unit

    Captured the body of the function call then append it to the given attribute value

    Captured the body of the function call then append it to the given attribute value

    Definition Classes
    RenderContext
  18. def captureNodeSeq (template: Template): NodeSeq

    Captures the text of the template rendering and then parses it as markup

    Captures the text of the template rendering and then parses it as markup

    Definition Classes
    RenderContext
  19. def captureNodeSeq (body: ⇒ Unit): NodeSeq

    Captures the text of the body and then parses it as markup

    Captures the text of the body and then parses it as markup

    Definition Classes
    RenderContext
  20. def clone (): AnyRef

    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws()
  21. def collection (objects: Traversable[AnyRef], viewName: String = "index", separator: ⇒ Any = blankString): Unit

    Renders a collection of model objects with an optional separator

    Renders a collection of model objects with an optional separator

    Definition Classes
    RenderContext
  22. var currentTemplate : String

    Definition Classes
    RenderContext
  23. def dateFormat : DateFormat

    Definition Classes
    RenderContext
  24. def dateFormat_= (value: DateFormat): Unit

    Definition Classes
    RenderContext
  25. val engine : TemplateEngine

    Definition Classes
    DefaultRenderContextRenderContext
  26. def eq (arg0: AnyRef): Boolean

    Attributes
    final
    Definition Classes
    AnyRef
  27. def equals (arg0: Any): Boolean

    Definition Classes
    AnyRef → Any
  28. def escape (v: Any): Unit

    Ensures that the string value of the parameter is always markup escaped

    Ensures that the string value of the parameter is always markup escaped

    Definition Classes
    RenderContext
  29. var escapeMarkup : Boolean

    Whether or not markup sensitive characters for HTML/XML elements like & > < are escaped or not

    Whether or not markup sensitive characters for HTML/XML elements like & > < are escaped or not

    Definition Classes
    RenderContext
  30. def filter (name: String, content: String): String

    Definition Classes
    RenderContext
  31. def finalize (): Unit

    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws()
  32. def flush : Unit

  33. def format (pattern: String, args: AnyRef*): String

    Returns the formatted string using the locale of the users request or the default locale if not available

    Returns the formatted string using the locale of the users request or the default locale if not available

    Definition Classes
    RenderContext
  34. def getClass (): java.lang.Class[_]

    Attributes
    final
    Definition Classes
    AnyRef → Any
  35. def hashCode (): Int

    Definition Classes
    AnyRef → Any
  36. def include (path: String, layout: Boolean, extraBindings: Traversable[Binding]): Unit

    Includes the given template path

    Includes the given template path

    layout

    if true then applying the layout the included template

    Definition Classes
    RenderContext
  37. def include (path: String, layout: Boolean): Unit

    Definition Classes
    RenderContext
  38. def include (path: String): Unit

    Definition Classes
    RenderContext
  39. def inject [T] (implicit manifest: Manifest[T]): T

    Creates an instance of the given given type using dependency injection to inject the necessary values into the object

    Creates an instance of the given given type using dependency injection to inject the necessary values into the object

    Definition Classes
    RenderContext
  40. def introspect (aType: Class[_]): org.fusesource.scalate.introspector.Introspector[_]

    Definition Classes
    RenderContext
  41. def isInstanceOf [T0] : Boolean

    Attributes
    final
    Definition Classes
    Any
  42. def layout (path: String, attrMap: Map[String, Any] = Map())(body: ⇒ Unit): Unit

    Renders the given template with optional attributes passing the body block as the *body* attribute so that it can be layered out using the template.

    Renders the given template with optional attributes passing the body block as the *body* attribute so that it can be layered out using the template.

    Definition Classes
    RenderContext
  43. def load (uri: String): String

    Loads the given template or file as a String for inclusion into the current page.

    Loads the given template or file as a String for inclusion into the current page.

    Useful if you want to include some client side template, particularly with a .jade extension

    Definition Classes
    RenderContext
  44. def locale : Locale

    Definition Classes
    RenderContext
  45. def ne (arg0: AnyRef): Boolean

    Attributes
    final
    Definition Classes
    AnyRef
  46. var noneString : String

    Default string used to output None values

    Default string used to output None values

    Definition Classes
    RenderContext
  47. def notify (): Unit

    Attributes
    final
    Definition Classes
    AnyRef
  48. def notifyAll (): Unit

    Attributes
    final
    Definition Classes
    AnyRef
  49. var nullString : String

    Default string used to output null values

    Default string used to output null values

    Definition Classes
    RenderContext
  50. def numberFormat : NumberFormat

    Definition Classes
    RenderContext
  51. def numberFormat_= (value: NumberFormat): Unit

    Definition Classes
    RenderContext
  52. var out : PrintWriter

  53. def percent (number: Number): String

    Definition Classes
    RenderContext
  54. def percentFormat : NumberFormat

    Definition Classes
    RenderContext
  55. def percentFormat_= (value: NumberFormat): Unit

    Definition Classes
    RenderContext
  56. def removeOldAttributes : Boolean

    Should we remove attributes from the context after we've rendered a child request?

    Should we remove attributes from the context after we've rendered a child request?

    Attributes
    protected
    Definition Classes
    RenderContext
  57. def render (path: String, attributeMap: Map[String, Any] = Map()): Unit

    Renders the given template with optional attributes

    Renders the given template with optional attributes

    Definition Classes
    RenderContext
  58. def requestFile : Option[File]

    Returns the file for the given request resource

    Returns the file for the given request resource

    Definition Classes
    DefaultRenderContextRenderContext
  59. def requestResource : Option[Resource]

    Returns the Resource of the request

    Returns the Resource of the request

    Definition Classes
    DefaultRenderContextRenderContext
  60. def requestUri : String

    Returns the request URI

    Returns the request URI

    Definition Classes
    DefaultRenderContextRenderContext
  61. def resolveUri (path: String): String

    Attributes
    protected
    Definition Classes
    RenderContext
  62. def resource [T] : T

    Returns the JAXRS resource bean of the given type or a NoValueSetException exception is thrown

    Returns the JAXRS resource bean of the given type or a NoValueSetException exception is thrown

    Definition Classes
    RenderContext
  63. def resourceOrElse [T] (defaultValue: T): T

    Returns the JAXRS resource bean of the given type or the default value if it is not available

    Returns the JAXRS resource bean of the given type or the default value if it is not available

    Definition Classes
    RenderContext
  64. def setAttribute (name: String, value: Option[Any]): Unit

    Definition Classes
    RenderContext
  65. def synchronized [T0] (arg0: ⇒ T0): T0

    Attributes
    final
    Definition Classes
    AnyRef
  66. def toString (): String

    Definition Classes
    AnyRef → Any
  67. implicit def toStringPair (entry: (Symbol, Any)): (String, Any)

    Allows a symbol to be used with arguments to the { @link render } or { @link layout } method such as render("foo.ssp", 'foo -> 123, 'bar -> 456) {...} render("foo.ssp", 'foo -> 123, 'bar -> 456) {...}

    Allows a symbol to be used with arguments to the { @link render } or { @link layout } method such as render("foo.ssp", 'foo -> 123, 'bar -> 456) {...}

    Attributes
    implicit
    Definition Classes
    RenderContext
  68. def unescape (v: Any): Unit

    Ensures that the string value of the parameter is not markup escaped

    Ensures that the string value of the parameter is not markup escaped

    Definition Classes
    RenderContext
  69. def uri (u: String): String

    Allows conversion of an absolute URL starting with "/" to be converted using the prefix of a web application

    Allows conversion of an absolute URL starting with "/" to be converted using the prefix of a web application

    Definition Classes
    RenderContext
  70. def uri (file: File): Option[String]

    Returns a local link to the given file which should be within the [sourceDirectories]

    Returns a local link to the given file which should be within the [sourceDirectories]

    Definition Classes
    RenderContext
  71. def using [T] (model: AnyRef)(op: ⇒ T): T

    Attributes
    protected
    Definition Classes
    RenderContext
  72. def value (any: Any, shouldSanitize: Boolean = escapeMarkup): Any

    Definition Classes
    RenderContext
  73. def valueEscaped (any: Any): Any

    Definition Classes
    RenderContext
  74. def valueUnescaped (any: Any): Any

    Definition Classes
    RenderContext
  75. def view (model: AnyRef, viewName: String = "index"): Unit

    Renders the view of the given model object, looking for the view in packageName/className.

    Renders the view of the given model object, looking for the view in packageName/className.viewName.ext

    Definition Classes
    RenderContext
  76. var viewPostfixes : List[String]

    Definition Classes
    RenderContext
  77. var viewPrefixes : List[String]

    Definition Classes
    RenderContext
  78. def wait (): Unit

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

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

    Attributes
    final
    Definition Classes
    AnyRef
    Annotations
    @throws()
  81. def withAttributes [T] (attrMap: Map[String, Any])(block: ⇒ T): T

    Uses the new sets of attributes for the given block, then replace them all (and remove any newly defined attributes)

    Uses the new sets of attributes for the given block, then replace them all (and remove any newly defined attributes)

    Definition Classes
    RenderContext
  82. def withUri [T] (uri: String)(block: ⇒ T): T

    Definition Classes
    RenderContext
  83. var wrapCssInCData : Boolean

    Whether we should escape CSS in CDATA sections when using the CSS filter

    Whether we should escape CSS in CDATA sections when using the CSS filter

    Definition Classes
    RenderContext

Inherited from RenderContext

Inherited from AnyRef

Inherited from Any