@InterfaceAudience.Private public class NativeBatchProcessor extends Object implements INativeHandler
| Modifier | Constructor and Description |
|---|---|
protected |
NativeBatchProcessor(String nativeHandlerName,
InputBuffer input,
OutputBuffer output) |
| Modifier and Type | Method and Description |
|---|---|
ReadWriteBuffer |
call(Command command,
ReadWriteBuffer parameter)
call command to downstream
|
void |
close()
close the native handler
|
static INativeHandler |
create(String nativeHandlerName,
org.apache.hadoop.conf.Configuration conf,
DataChannel channel) |
protected void |
finishOutput() |
void |
finishSendData()
Sends a signal that there is no more data
|
InputBuffer |
getInputBuffer()
get input buffer
|
long |
getNativeHandler() |
OutputBuffer |
getOutputBuffer()
Gets the output buffer.
|
void |
init(org.apache.hadoop.conf.Configuration conf)
init the native handler
|
void |
loadData()
load data from upstream
|
String |
name() |
void |
sendData()
Sends a signal to indicate that the data has been stored in output buffer
|
void |
setCommandDispatcher(CommandDispatcher handler) |
void |
setDataReceiver(DataReceiver handler)
set listener.
|
protected NativeBatchProcessor(String nativeHandlerName, InputBuffer input, OutputBuffer output) throws IOException
IOExceptionpublic static INativeHandler create(String nativeHandlerName, org.apache.hadoop.conf.Configuration conf, DataChannel channel) throws IOException
IOExceptionpublic void setCommandDispatcher(CommandDispatcher handler)
setCommandDispatcher in interface INativeHandlerpublic void init(org.apache.hadoop.conf.Configuration conf)
throws IOException
INativeHandlerinit in interface INativeHandlerIOExceptionpublic void close()
throws IOException
INativeHandlerclose in interface INativeHandlerIOExceptionpublic long getNativeHandler()
getNativeHandler in interface INativeHandlerpublic ReadWriteBuffer call(Command command, ReadWriteBuffer parameter) throws IOException
INativeHandlercall in interface INativeHandlerIOExceptionpublic void sendData()
throws IOException
NativeDataTargetsendData in interface NativeDataTargetIOExceptionpublic void finishSendData()
throws IOException
NativeDataTargetfinishSendData in interface NativeDataTargetIOExceptionprotected void finishOutput()
public InputBuffer getInputBuffer()
NativeDataSourcegetInputBuffer in interface NativeDataSourcepublic OutputBuffer getOutputBuffer()
NativeDataTargetgetOutputBuffer in interface NativeDataTargetpublic void loadData()
throws IOException
NativeDataSourceloadData in interface NativeDataSourceIOExceptionpublic void setDataReceiver(DataReceiver handler)
NativeDataSourcesetDataReceiver in interface NativeDataSourcepublic String name()
name in interface INativeHandlerCopyright © 2008–2022 Apache Software Foundation. All rights reserved.