Top Description Constructors Methods
org.springframework.web.util

public abstract Class JavaScriptUtils

extends Object
Class Inheritance

Utility class for JavaScript escaping. Escapes based on the JavaScript 1.5 recommendation.

Reference: JavaScript Guide on Mozilla Developer Network.

Authors
Juergen Hoeller, Rob Harrop, Rossen Stoyanchev
Since
1.1.1

Constructor Summary

AccessConstructor and Description
public

Method Summary

Modifier and TypeMethod and Description
public static String

Returns:

the string with escaped characters
javaScriptEscape
(String
the input string
input
)

Turn JavaScript special characters into escaped characters.

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Constructor Detail

JavaScriptUtilsback to summary
public JavaScriptUtils()

Method Detail

javaScriptEscapeback to summary
public static String javaScriptEscape(String input)

Turn JavaScript special characters into escaped characters.

Parameters
input:String

the input string

Returns:String

the string with escaped characters