public final class ResultPartitionWriter extends Object implements EventListener<TaskEvent>
The ResultPartitionWriter
is the runtime API for producing results. It
supports two kinds of data to be sent: buffers and events.
Constructor and Description |
---|
ResultPartitionWriter(ResultPartition partition) |
Modifier and Type | Method and Description |
---|---|
BufferProvider |
getBufferProvider() |
int |
getNumberOfOutputChannels() |
ResultPartitionID |
getPartitionId() |
void |
onEvent(TaskEvent event) |
void |
subscribeToEvent(EventListener<TaskEvent> eventListener,
Class<? extends TaskEvent> eventType) |
void |
writeBuffer(Buffer buffer,
int targetChannel) |
void |
writeEndOfSuperstep() |
void |
writeEvent(AbstractEvent event,
int targetChannel) |
void |
writeEventToAllChannels(AbstractEvent event) |
public ResultPartitionWriter(ResultPartition partition)
public ResultPartitionID getPartitionId()
public BufferProvider getBufferProvider()
public int getNumberOfOutputChannels()
public void writeBuffer(Buffer buffer, int targetChannel) throws IOException
IOException
public void writeEvent(AbstractEvent event, int targetChannel) throws IOException
IOException
public void writeEventToAllChannels(AbstractEvent event) throws IOException
IOException
public void writeEndOfSuperstep() throws IOException
IOException
public void subscribeToEvent(EventListener<TaskEvent> eventListener, Class<? extends TaskEvent> eventType)
public void onEvent(TaskEvent event)
onEvent
in interface EventListener<TaskEvent>
Copyright © 2014–2017 The Apache Software Foundation. All rights reserved.