Class SimpleStringDecoder
java.lang.Object
org.apache.flink.connector.file.sink.compactor.SimpleStringDecoder
- All Implemented Interfaces:
Serializable,DecoderBasedReader.Decoder<String>
@PublicEvolving
public class SimpleStringDecoder
extends Object
implements DecoderBasedReader.Decoder<String>
A sink
DecoderBasedReader.Decoder that reads data encoded by the SimpleStringEncoder only for compaction. The original
input type is missing, but it's enough to read string contents for writing the compacted file.- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.apache.flink.connector.file.sink.compactor.DecoderBasedReader.Decoder
DecoderBasedReader.Decoder.Factory<T> -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidclose()Closes the open resources.voidopen(InputStream input) Prepares to start decoding the input stream.
-
Constructor Details
-
SimpleStringDecoder
public SimpleStringDecoder()
-
-
Method Details
-
open
Description copied from interface:DecoderBasedReader.DecoderPrepares to start decoding the input stream.- Specified by:
openin interfaceDecoderBasedReader.Decoder<String>- Throws:
IOException
-
decodeNext
- Specified by:
decodeNextin interfaceDecoderBasedReader.Decoder<String>- Returns:
- The next record that decoded from the opened input stream, or null if no more available.
- Throws:
IOException
-
close
Description copied from interface:DecoderBasedReader.DecoderCloses the open resources. The decoder is responsible to close the input stream.- Specified by:
closein interfaceDecoderBasedReader.Decoder<String>- Throws:
IOException
-