java.nio.charset

Class CharsetDecoder

public abstract class CharsetDecoder extends Object

Since: 1.4

Constructor Summary
protected CharsetDecoder(Charset cs, float averageCharsPerByte, float maxCharsPerByte)
Method Summary
floataverageCharsPerByte()
Charsetcharset()
CharBufferdecode(ByteBuffer in)
CoderResultdecode(ByteBuffer in, CharBuffer out, boolean endOfInput)
protected abstract CoderResultdecodeLoop(ByteBuffer in, CharBuffer out)
CharsetdetectedCharset()
CoderResultflush(CharBuffer out)
protected CoderResultimplFlush(CharBuffer out)
protected voidimplOnMalformedInput(CodingErrorAction newAction)
protected voidimplOnUnmappableCharacter(CodingErrorAction newAction)
protected voidimplReplaceWith(String newReplacement)
protected voidimplReset()
booleanisAutoDetecting()
booleanisCharsetDetected()
CodingErrorActionmalformedInputAction()
floatmaxCharsPerByte()
CharsetDecoderonMalformedInput(CodingErrorAction newAction)
CharsetDecoderonUnmappableCharacter(CodingErrorAction newAction)
Stringreplacement()
CharsetDecoderreplaceWith(String newReplacement)
CharsetDecoderreset()
CodingErrorActionunmappableCharacterAction()

Constructor Detail

CharsetDecoder

protected CharsetDecoder(Charset cs, float averageCharsPerByte, float maxCharsPerByte)

Method Detail

averageCharsPerByte

public final float averageCharsPerByte()

charset

public final Charset charset()

decode

public final CharBuffer decode(ByteBuffer in)

decode

public final CoderResult decode(ByteBuffer in, CharBuffer out, boolean endOfInput)

decodeLoop

protected abstract CoderResult decodeLoop(ByteBuffer in, CharBuffer out)

detectedCharset

public Charset detectedCharset()

flush

public final CoderResult flush(CharBuffer out)

implFlush

protected CoderResult implFlush(CharBuffer out)

implOnMalformedInput

protected void implOnMalformedInput(CodingErrorAction newAction)

implOnUnmappableCharacter

protected void implOnUnmappableCharacter(CodingErrorAction newAction)

implReplaceWith

protected void implReplaceWith(String newReplacement)

implReset

protected void implReset()

isAutoDetecting

public boolean isAutoDetecting()

isCharsetDetected

public boolean isCharsetDetected()

malformedInputAction

public CodingErrorAction malformedInputAction()

maxCharsPerByte

public final float maxCharsPerByte()

onMalformedInput

public final CharsetDecoder onMalformedInput(CodingErrorAction newAction)

onUnmappableCharacter

public final CharsetDecoder onUnmappableCharacter(CodingErrorAction newAction)

replacement

public final String replacement()

replaceWith

public final CharsetDecoder replaceWith(String newReplacement)

reset

public final CharsetDecoder reset()

unmappableCharacterAction

public CodingErrorAction unmappableCharacterAction()