Package net.freeutils.charset
Class PackedGSMCharset.Decoder
java.lang.Object
java.nio.charset.CharsetDecoder
net.freeutils.charset.EscapedByteLookupCharset.Decoder
net.freeutils.charset.PackedGSMCharset.Decoder
- Enclosing class:
PackedGSMCharset
The Decoder inner class handles the decoding of the
Packed GSM default encoding charset.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected CoderResultdecodeLoop(ByteBuffer in, CharBuffer out) Decodes one or more bytes into one or more characters.protected CoderResultimplFlush(CharBuffer out) Flushes this decoder.protected voidResets this decoder, clearing any charset-specific internal state.protected CoderResultunpack(ByteBuffer in, ByteBuffer out) Unpacks the given data into original bytes.Methods inherited from class java.nio.charset.CharsetDecoder
averageCharsPerByte, charset, decode, decode, detectedCharset, flush, implOnMalformedInput, implOnUnmappableCharacter, implReplaceWith, isAutoDetecting, isCharsetDetected, malformedInputAction, maxCharsPerByte, onMalformedInput, onUnmappableCharacter, replacement, replaceWith, reset, unmappableCharacterAction
-
Constructor Details
-
Decoder
Constructs a Decoder.- Parameters:
cs- the charset to which this decoder belongs
-
-
Method Details
-
implReset
protected void implReset()Resets this decoder, clearing any charset-specific internal state.- Overrides:
implResetin classCharsetDecoder
-
implFlush
Flushes this decoder.- Overrides:
implFlushin classCharsetDecoder- Parameters:
out- The output character buffer- Returns:
- A coder-result object, either
CoderResult.UNDERFLOWorCoderResult.OVERFLOW
-
decodeLoop
Decodes one or more bytes into one or more characters.- Overrides:
decodeLoopin classEscapedByteLookupCharset.Decoder- Parameters:
in- the input byte bufferout- the output character buffer- Returns:
- a coder-result object describing the reason for termination
-
unpack
Unpacks the given data into original bytes.- Parameters:
in- the input byte bufferout- the output byte buffer- Returns:
- A coder-result object, either
CoderResult.UNDERFLOWorCoderResult.OVERFLOW
-