Klasse Script
java.lang.Object
org.jdrupes.mdoclet.internal.doclets.formats.html.markup.Script
A builder for HTML script elements.
-
Konstruktorübersicht
Konstruktoren -
Methodenübersicht
Modifizierer und TypMethodeBeschreibungappend(CharSequence code) Appends the given code to the script.Appends the given text as a string constant to the string.appendStringLiteral(CharSequence text, char quoteChar) Appends the given text as a string constant to the string.Returns a “live” view of the script as a Content object.static StringReturns a JavaScript string literal containing a specified string, escaping the characters of that string as needed.static StringstringLiteral(CharSequence s, char quoteChar) Returns a JavaScript string literal containing a specified string, escaping the characters of that string as needed.
-
Konstruktordetails
-
Script
public Script()Creates an empty script. -
Script
Creates a new script containing the specified code.- Parameter:
code- the code
-
-
Methodendetails
-
append
Appends the given code to the script.- Parameter:
code- the code- Gibt zurück:
- this object
-
appendStringLiteral
Appends the given text as a string constant to the string.Characters within the string will be escaped as needed.
- Parameter:
text- the text- Gibt zurück:
- this object
-
appendStringLiteral
Appends the given text as a string constant to the string.Characters within the string will be escaped as needed.
- Parameter:
text- the textquoteChar- the quote character to use- Gibt zurück:
- this object
-
asContent
Returns a “live” view of the script as a Content object.Any later modifications to the script will be reflected in the object that is returned.
- Gibt zurück:
- the script
-
stringLiteral
Returns a JavaScript string literal containing a specified string, escaping the characters of that string as needed.- Parameter:
s- the string- Gibt zurück:
- a string literal containing the string
-
stringLiteral
Returns a JavaScript string literal containing a specified string, escaping the characters of that string as needed.- Parameter:
s- the stringquoteChar- the quote character to use for the literal- Gibt zurück:
- a string literal containing the string
-