@GwtCompatible(emulated=true) final class GwtWorkarounds extends java.lang.Object
InputStream
, OutputStream
,
Reader
, and Writer
so that BaseEncoding
can use streaming implementations
while remaining GWT-compatible.Modifier and Type | Class and Description |
---|---|
(package private) static interface |
GwtWorkarounds.ByteInput
A GWT-compatible substitute for an
InputStream . |
(package private) static interface |
GwtWorkarounds.ByteOutput
A GWT-compatible substitute for an
OutputStream . |
(package private) static interface |
GwtWorkarounds.CharInput
A GWT-compatible substitute for a
Reader . |
(package private) static interface |
GwtWorkarounds.CharOutput
A GWT-compatible substitute for a
Writer . |
Modifier | Constructor and Description |
---|---|
private |
GwtWorkarounds() |
Modifier and Type | Method and Description |
---|---|
(package private) static GwtWorkarounds.CharInput |
asCharInput(java.lang.CharSequence chars)
Views a
CharSequence as a CharInput . |
(package private) static GwtWorkarounds.CharInput |
asCharInput(java.io.Reader reader)
Views a
Reader as a CharInput . |
(package private) static GwtWorkarounds.CharOutput |
asCharOutput(java.io.Writer writer)
Views a
Writer as a CharOutput . |
(package private) static java.io.InputStream |
asInputStream(GwtWorkarounds.ByteInput input)
Views a
ByteInput as an InputStream . |
(package private) static java.io.OutputStream |
asOutputStream(GwtWorkarounds.ByteOutput output)
Views a
ByteOutput as an OutputStream . |
(package private) static GwtWorkarounds.CharOutput |
stringBuilderOutput(int initialSize)
Returns a
CharOutput whose toString() method can be used
to get the combined output. |
@GwtIncompatible(value="Reader") static GwtWorkarounds.CharInput asCharInput(java.io.Reader reader)
Reader
as a CharInput
.static GwtWorkarounds.CharInput asCharInput(java.lang.CharSequence chars)
CharSequence
as a CharInput
.@GwtIncompatible(value="InputStream") static java.io.InputStream asInputStream(GwtWorkarounds.ByteInput input)
ByteInput
as an InputStream
.@GwtIncompatible(value="OutputStream") static java.io.OutputStream asOutputStream(GwtWorkarounds.ByteOutput output)
ByteOutput
as an OutputStream
.@GwtIncompatible(value="Writer") static GwtWorkarounds.CharOutput asCharOutput(java.io.Writer writer)
Writer
as a CharOutput
.static GwtWorkarounds.CharOutput stringBuilderOutput(int initialSize)
CharOutput
whose toString()
method can be used
to get the combined output.