Class HTMLUtils
java.lang.Object
com.webmethods.caf.faces.render.util.HTMLUtils
HTML-rendering utility functions.
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic ResponseWriter
createHTMLResponseWriter
(FacesContext context, Writer out) static String
decodeClientId
(String id) Decodes id encoded withencodeClientId(java.lang.String)
.static String
encodeClientId
(String id) Encodes id to be legal SGML id string.static boolean
isValidName
(String name) Returns true if the specified element/attribute name is a legal html element/attribute name.static String
Escapes HTML.static String
Escapes HTML.
-
Field Details
-
RE_HTML_NAME
(html 4.01 6.2) ID and NAME tokens must begin with a letter ([A-Za-z]) and may be followed by any number of letters, digits ([0-9]), hyphens ("-"), underscores ("_"), colons (":"), and periods ("."). -
RE_CLIENT_ID_ESCAPES
-
-
Constructor Details
-
HTMLUtils
public HTMLUtils()
-
-
Method Details
-
quote
Escapes HTML.- Returns:
- Escaped string. Never null.
-
quote
Escapes HTML.- Parameters:
elementContent
- True if escaping element content (in which case ' [single-quote] and " [double-quote] don't need to be escaped).- Returns:
- Escaped string. Never null.
-
isValidName
Returns true if the specified element/attribute name is a legal html element/attribute name. -
encodeClientId
Encodes id to be legal SGML id string. -
decodeClientId
Decodes id encoded withencodeClientId(java.lang.String)
. -
createHTMLResponseWriter
-