public final class TextOf extends Object implements Text
There is no thread-safety guarantee.
Text.NoNulls
Constructor and Description |
---|
TextOf(byte... bytes)
Ctor.
|
TextOf(Bytes bytes)
Ctor.
|
TextOf(Bytes bytes,
Charset cset)
Ctor.
|
TextOf(Bytes bytes,
String cset)
Ctor.
|
TextOf(char... chars)
Ctor.
|
TextOf(char[] chars,
Charset cset)
Ctor.
|
TextOf(CharSequence builder)
Ctor.
|
TextOf(CharSequence builder,
Charset cset)
Ctor.
|
TextOf(File file)
Ctor.
|
TextOf(Input input)
Ctor.
|
TextOf(Input input,
Charset cset)
Ctor.
|
TextOf(Input input,
int max)
Ctor.
|
TextOf(Input input,
int max,
Charset cset)
Ctor.
|
TextOf(InputStream input)
Ctor.
|
TextOf(Input input,
String cset)
Ctor.
|
TextOf(Iterable<?> iterable)
Ctor.
|
TextOf(Path path)
Ctor.
|
TextOf(Reader rdr)
Ctor.
|
TextOf(Reader rdr,
Charset cset)
Ctor.
|
TextOf(Reader rdr,
Charset cset,
int max)
Ctor.
|
TextOf(StackTraceElement... strace)
Ctor.
|
TextOf(StackTraceElement[] strace,
CharSequence charset)
Ctor.
|
TextOf(StackTraceElement[] strace,
Charset charset)
Ctor.
|
TextOf(String input)
Ctor.
|
TextOf(String input,
Charset cset)
Ctor.
|
TextOf(Throwable error)
Ctor.
|
TextOf(Throwable error,
CharSequence charset)
Ctor.
|
TextOf(Throwable error,
Charset charset)
Ctor.
|
TextOf(URI uri)
Ctor.
|
TextOf(URL url)
Ctor.
|
public TextOf(Input input)
input
- The Inputpublic TextOf(URL url)
url
- The URLpublic TextOf(URI uri)
uri
- The URIpublic TextOf(Path path)
path
- The Inputpublic TextOf(File file)
file
- The Inputpublic TextOf(Input input, int max)
input
- The inputmax
- Max length of the buffer for readingpublic TextOf(Input input, Charset cset)
input
- The Inputcset
- The Charsetpublic TextOf(Input input, String cset)
input
- The Inputcset
- The Charsetpublic TextOf(Input input, int max, Charset cset)
input
- The inputmax
- Max length of the buffer for readingcset
- The Charsetpublic TextOf(Reader rdr)
rdr
- Readerpublic TextOf(Reader rdr, Charset cset, int max)
rdr
- Readercset
- Charsetmax
- Buffer sizepublic TextOf(CharSequence builder)
builder
- The String builderpublic TextOf(CharSequence builder, Charset cset)
builder
- The String buildercset
- The Charsetpublic TextOf(char... chars)
chars
- The charspublic TextOf(char[] chars, Charset cset)
chars
- The charscset
- The charsetpublic TextOf(Throwable error)
error
- The exception to serializepublic TextOf(Throwable error, Charset charset)
error
- The exception to serializecharset
- Charsetpublic TextOf(Throwable error, CharSequence charset)
error
- The exception to serializecharset
- Charsetpublic TextOf(StackTraceElement... strace)
strace
- The stacktrace to serializepublic TextOf(StackTraceElement[] strace, Charset charset)
strace
- The stacktrace to serializecharset
- Charsetpublic TextOf(StackTraceElement[] strace, CharSequence charset)
strace
- The stacktrace to serializecharset
- Charsetpublic TextOf(byte... bytes)
bytes
- The array of bytespublic TextOf(Bytes bytes)
bytes
- The Bytespublic TextOf(Bytes bytes, Charset cset)
bytes
- The Bytescset
- The Charsetpublic TextOf(Bytes bytes, String cset)
bytes
- The Bytescset
- The Charsetpublic TextOf(String input)
input
- The Stringpublic TextOf(String input, Charset cset)
input
- The Stringcset
- The Charsetpublic TextOf(Iterable<?> iterable)
iterable
- The iterable to convert to stringpublic TextOf(InputStream input)
input
- The InputStream where the text is read frompublic String asString() throws IOException
Text
asString
in interface Text
IOException
- If failsCopyright © 2017–2018 Cactoos. All rights reserved.