|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.codehaus.stax2.ri.typed.StringBase64Decoder
public final class StringBase64Decoder
Base64 decoder that can be used to decode base64 encoded content that is passed as a Single string.
Constructor Summary | |
---|---|
StringBase64Decoder()
|
Method Summary | |
---|---|
int |
decode(byte[] resultBuffer,
int resultOffset,
int maxLength)
Method that does actual decoding |
byte[] |
decodeCompletely()
Method that can be called to completely decode content that this decoder has been initialized with. |
int |
endOfContent()
Method called to indicate that we have no more encoded content to process, and decoding is to finish. |
Stax2Util.ByteAggregator |
getByteAggregator()
|
boolean |
hasData()
Method that can be called to check if this decoder is in has unflushed data ready to be returned. |
void |
init(Base64Variant variant,
boolean firstChunk,
String segment)
|
protected IllegalArgumentException |
reportInvalidChar(char ch,
int bindex)
|
protected IllegalArgumentException |
reportInvalidChar(char ch,
int bindex,
String msg)
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public StringBase64Decoder()
Method Detail |
---|
public void init(Base64Variant variant, boolean firstChunk, String segment)
public int decode(byte[] resultBuffer, int resultOffset, int maxLength) throws IllegalArgumentException
resultBuffer
- Buffer in which decoded bytes are returnedresultOffset
- Offset that points to position to put the
first decoded byte in maxLength Maximum number of bytes that can be returned
in given buffer
IllegalArgumentException
public final boolean hasData()
public final int endOfContent()
public byte[] decodeCompletely()
public Stax2Util.ByteAggregator getByteAggregator()
protected IllegalArgumentException reportInvalidChar(char ch, int bindex) throws IllegalArgumentException
IllegalArgumentException
protected IllegalArgumentException reportInvalidChar(char ch, int bindex, String msg) throws IllegalArgumentException
bindex
- Relative index within base64 character unit; between 0
and 3 (as unit has exactly 4 characters)
IllegalArgumentException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |