Package com.microstrategy.utils
Class BasicHTMLEncoder
- java.lang.Object
-
- com.microstrategy.utils.BasicHTMLEncoder
-
- All Implemented Interfaces:
ContentEncoder
- Direct Known Subclasses:
HTMLEncoder
public class BasicHTMLEncoder extends java.lang.Object implements ContentEncoder
Class for performing an HTML encoding on the data.- Since:
- MicroStrategy Web 9.3.2
-
-
Constructor Summary
Constructors Constructor Description BasicHTMLEncoder()
BasicHTMLEncoder(boolean encodeSpaces)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.String
decode(java.lang.String data)
java.lang.CharSequence
encode(java.lang.String data)
This method should return the original String if there is no replacement.java.lang.StringBuilder
encode(java.lang.StringBuilder data)
Encode the value in the StringBuilder.java.lang.CharSequence
encode(java.lang.String data, boolean encodeSpaces)
java.lang.String
encodeForAllowHtmlOnMetrics(java.lang.String data)
java.lang.String
encodeForAllowHtmlOnSelector(java.lang.String data)
java.lang.String
encodeForAttributeValueTooltip(java.lang.StringBuilder data)
boolean
getPreventDoubleEncoding()
static boolean
isEncoded(java.lang.CharSequence chars, java.lang.Boolean encodeSpace)
boolean
isEncodeSpacesAsNonBreaking()
void
setEncodeSpacesAsNonBreaking(boolean encodeSpacesAsNonBreaking)
void
setPreventDoubleEncoding(java.lang.Boolean value)
-
-
-
Method Detail
-
encode
public java.lang.CharSequence encode(java.lang.String data)
Description copied from interface:ContentEncoder
This method should return the original String if there is no replacement.- Specified by:
encode
in interfaceContentEncoder
- Parameters:
data
- - value to be encoded- Returns:
- encoded value
-
encode
public java.lang.CharSequence encode(java.lang.String data, boolean encodeSpaces)
-
encode
public java.lang.StringBuilder encode(java.lang.StringBuilder data)
Description copied from interface:ContentEncoder
Encode the value in the StringBuilder.- Specified by:
encode
in interfaceContentEncoder
- Parameters:
data
- - value to be encoded- Returns:
- encoded value
-
encodeForAllowHtmlOnMetrics
public java.lang.String encodeForAllowHtmlOnMetrics(java.lang.String data)
-
encodeForAllowHtmlOnSelector
public java.lang.String encodeForAllowHtmlOnSelector(java.lang.String data)
-
encodeForAttributeValueTooltip
public java.lang.String encodeForAttributeValueTooltip(java.lang.StringBuilder data)
-
decode
public java.lang.String decode(java.lang.String data)
-
isEncodeSpacesAsNonBreaking
public boolean isEncodeSpacesAsNonBreaking()
-
setEncodeSpacesAsNonBreaking
public void setEncodeSpacesAsNonBreaking(boolean encodeSpacesAsNonBreaking)
-
isEncoded
public static boolean isEncoded(java.lang.CharSequence chars, java.lang.Boolean encodeSpace)
-
getPreventDoubleEncoding
public boolean getPreventDoubleEncoding()
-
setPreventDoubleEncoding
public void setPreventDoubleEncoding(java.lang.Boolean value)
-
-