public abstract class

HtmlEscapingAwareTag

extends RequestContextAwareTag
java.lang.Object
   ↳ TagSupport
     ↳ org.springframework.web.servlet.tags.RequestContextAwareTag
       ↳ org.springframework.web.servlet.tags.HtmlEscapingAwareTag
Known Direct Subclasses
Known Indirect Subclasses

Class Overview

Superclass for tags that output content that might get HTML-escaped.

Provides a "htmlEscape" property for explicitly specifying whether to apply HTML escaping. If not set, a page-level default (e.g. from the HtmlEscapeTag) or an application-wide default (the "defaultHtmlEscape" context-param in web.xml) is used.

Summary

[Expand]
Inherited Constants
From class org.springframework.web.servlet.tags.RequestContextAwareTag
[Expand]
Inherited Fields
From class org.springframework.web.servlet.tags.RequestContextAwareTag
Public Constructors
HtmlEscapingAwareTag()
Public Methods
void setHtmlEscape(String htmlEscape)
Set HTML escaping for this tag, as boolean value.
Protected Methods
boolean isDefaultHtmlEscape()
Return the applicable default HTML escape setting for this tag.
boolean isHtmlEscape()
Return the HTML escaping setting for this tag, or the default setting if not overridden.
[Expand]
Inherited Methods
From class org.springframework.web.servlet.tags.RequestContextAwareTag
From class java.lang.Object

Public Constructors

public HtmlEscapingAwareTag ()

Public Methods

public void setHtmlEscape (String htmlEscape)

Set HTML escaping for this tag, as boolean value. Overrides the default HTML escaping setting for the current page.

Throws
JspException

Protected Methods

protected boolean isDefaultHtmlEscape ()

Return the applicable default HTML escape setting for this tag.

The default implementation checks the RequestContext's setting, falling back to false in case of no explicit default given.

protected boolean isHtmlEscape ()

Return the HTML escaping setting for this tag, or the default setting if not overridden.