Class LineSplitterBlock
- java.lang.Object
-
- org.apache.ignite.internal.processors.bulkload.pipeline.PipelineBlock<char[],String>
-
- org.apache.ignite.internal.processors.bulkload.pipeline.LineSplitterBlock
-
public class LineSplitterBlock extends PipelineBlock<char[],String>
APipelineBlock, which splits input stream of char[] into lines using the specifiedPatternas line separator. Next blockPipelineBlock.accept(Object, boolean)is invoked for each line. Leftover characters are remembered and used during processing the next input batch, unless isLastPortion flag is specified.
-
-
Constructor Summary
Constructors Constructor Description LineSplitterBlock(Pattern delim)Creates line splitter block.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaccept(char[] chars, boolean isLastPortion)Accepts a portion of input.-
Methods inherited from class org.apache.ignite.internal.processors.bulkload.pipeline.PipelineBlock
append
-
-
-
-
Constructor Detail
-
LineSplitterBlock
public LineSplitterBlock(Pattern delim)
Creates line splitter block.- Parameters:
delim- The line separator pattern.
-
-
Method Detail
-
accept
public void accept(char[] chars, boolean isLastPortion) throws IgniteCheckedExceptionAccepts a portion of input.isLastPortionparameter should be set if this is a last portion of the input. The method must not be called after the end of input: the call withisLastPortion == trueis the last one.- Specified by:
acceptin classPipelineBlock<char[],String>- Parameters:
chars- Portion of input.isLastPortion- Is this the last portion.- Throws:
IgniteCheckedException- On error.
-
-