- All Superinterfaces:
Encode
- All Known Implementing Classes:
JavaScriptWriter
,JsonWriter
,LdJsonWriter
,MysqlWriter
,PsqlWriter
,ShWriter
,StyleWriter
,TextWriter
,XhtmlAttributeWriter
,XhtmlWriter
- Author:
- AO Industries, Inc.
-
Field Summary
Modifier and TypeFieldDescriptionstatic final char
The character used for non-breaking space, which is'\\u00A0'
. -
Method Summary
Modifier and TypeMethodDescriptiondefault Text
Encodes the given nested type with proper encoding.default Text
Encodes the given nested type with proper encoding.default Text
Encodes the given nested type with proper encoding.encode
(MediaType contentType, MediaWritable<Ex> content) Encodes the given nested type with proper encoding.encode
(MediaType contentType, IOSupplierE<?, Ex> content) Encodes the given nested type with proper encoding.encode
(MediaType contentType, CharSequence csq) Encodes the given nested type with proper encoding.encode
(MediaType contentType, CharSequence csq, int start, int end) Encodes the given nested type with proper encoding.Encodes the given nested type with proper encoding.default Text
nbsp()
Writes one non-breaking space character.default Text
nbsp
(int count) Writes the given number of non-breaking space characters.default TextWriter
text()
Writes the given text with proper encoding.default Text
text
(char ch) Writes the given text with proper encoding.default Text
text
(char[] cbuf) Writes the given text with proper encoding.default Text
text
(char[] cbuf, int offset, int len) Writes the given text with proper encoding.text
(TextWritable<Ex> text) Writes the given text with proper encoding.text
(IOSupplierE<?, Ex> text) Writes the given text with proper encoding.default Text
text
(CharSequence csq) Writes the given text with proper encoding.default Text
text
(CharSequence csq, int start, int end) Writes the given text with proper encoding.default Text
Writes the given text with proper encoding.
-
Field Details
-
NBSP
static final char NBSPThe character used for non-breaking space, which is'\\u00A0'
.- See Also:
-
-
Method Details
-
encode
Description copied from interface:Encode
Encodes the given nested type with proper encoding.- Specified by:
encode
in interfaceEncode
- Returns:
this
writer- Throws:
IOException
-
encode
Description copied from interface:Encode
Encodes the given nested type with proper encoding.- Specified by:
encode
in interfaceEncode
- Returns:
this
writer- Throws:
IOException
-
encode
Description copied from interface:Encode
Encodes the given nested type with proper encoding.- Specified by:
encode
in interfaceEncode
- Returns:
this
writer- Throws:
IOException
-
encode
Description copied from interface:Encode
Encodes the given nested type with proper encoding.Adds prefixes and suffixes by media type, such as
"…"
.If the string is translated, comments will be added giving the translation lookup id to aid in translation of server-translated values.
- Specified by:
encode
in interfaceEncode
- Returns:
this
writer- Throws:
IOException
-
encode
Description copied from interface:Encode
Encodes the given nested type with proper encoding.Adds prefixes and suffixes by media type, such as
"…"
.If the string is translated, comments will be added giving the translation lookup id to aid in translation of server-translated values.
- Specified by:
encode
in interfaceEncode
- Returns:
this
writer- Throws:
IOException
-
encode
Description copied from interface:Encode
Encodes the given nested type with proper encoding.Adds prefixes and suffixes by media type, such as
"…"
.If the string is translated, comments will be added giving the translation lookup id to aid in translation of server-translated values.
- Specified by:
encode
in interfaceEncode
- Returns:
this
writer- Throws:
IOException
-
encode
default <Ex extends Throwable> Text encode(MediaType contentType, IOSupplierE<?, Ex> content) throws IOException, ExDescription copied from interface:Encode
Encodes the given nested type with proper encoding.Adds prefixes and suffixes by media type, such as
"…"
.If the string is translated, comments will be added giving the translation lookup id to aid in translation of server-translated values.
- Specified by:
encode
in interfaceEncode
- Type Parameters:
Ex
- An arbitrary exception type that may be thrown- Returns:
this
writer- Throws:
IOException
Ex
-
encode
default <Ex extends Throwable> Text encode(MediaType contentType, MediaWritable<Ex> content) throws IOException, Ex Description copied from interface:Encode
Encodes the given nested type with proper encoding.Adds prefixes and suffixes by media type, such as
"…"
.Does not perform any translation markups.
- Specified by:
encode
in interfaceEncode
- Type Parameters:
Ex
- An arbitrary exception type that may be thrown- Returns:
this
writer- Throws:
IOException
Ex
-
nbsp
- Returns:
this
writer- Throws:
IOException
- See Also:
-
nbsp
Writes the given number of non-breaking space characters.- Parameters:
count
- Whencount <= 0
, nothing is written.- Returns:
this
writer- Throws:
IOException
- See Also:
-
text
- Returns:
this
writer- Throws:
IOException
-
text
- Returns:
this
writer- Throws:
IOException
-
text
- Returns:
this
writer- Throws:
IOException
-
text
Writes the given text with proper encoding.Adds prefixes and suffixes by media type, such as
"…"
.If the string is translated, comments will be added giving the translation lookup id to aid in translation of server-translated values.
- Returns:
this
writer- Throws:
IOException
-
text
Writes the given text with proper encoding.Adds prefixes and suffixes by media type, such as
"…"
.If the string is translated, comments will be added giving the translation lookup id to aid in translation of server-translated values.
- Returns:
this
writer- Throws:
IOException
-
text
Writes the given text with proper encoding.Adds prefixes and suffixes by media type, such as
"…"
.If the string is translated, comments will be added giving the translation lookup id to aid in translation of server-translated values.
- Returns:
this
writer- Throws:
IOException
-
text
Writes the given text with proper encoding.Adds prefixes and suffixes by media type, such as
"…"
.If the string is translated, comments will be added giving the translation lookup id to aid in translation of server-translated values.
- Type Parameters:
Ex
- An arbitrary exception type that may be thrown- Returns:
this
writer- Throws:
IOException
Ex
-
text
Writes the given text with proper encoding.Adds prefixes and suffixes by media type, such as
"…"
.Does not perform any translation markups.
- Type Parameters:
Ex
- An arbitrary exception type that may be thrown- Returns:
this
writer- Throws:
IOException
Ex
-
text
Writes the given text with proper encoding. This is well suited for use in a try-with-resources block.Adds prefixes and suffixes by media type, such as
"…"
.Does not perform any translation markups.
- Returns:
- A new writer that may be used for arbitrary text.
This writer must be closed for completed calls to
MediaEncoder.writeSuffixTo(java.lang.Appendable, boolean)
. - Throws:
IOException
-