com.hazelcast.mapreduce.impl.notification
Class LastChunkNotification<KeyOut,Value>

java.lang.Object
  extended by com.hazelcast.mapreduce.impl.notification.MapReduceNotification
      extended by com.hazelcast.mapreduce.impl.notification.MemberAwareMapReduceNotification
          extended by com.hazelcast.mapreduce.impl.notification.LastChunkNotification<KeyOut,Value>
Type Parameters:
KeyOut - type of the key
Value - type of the value
All Implemented Interfaces:
DataSerializable, IdentifiedDataSerializable

public class LastChunkNotification<KeyOut,Value>
extends MemberAwareMapReduceNotification

This notification is used to notify the reducer that this chunk is the last chunk of the defined partitionId.


Constructor Summary
LastChunkNotification()
           
LastChunkNotification(Address address, String name, String jobId, Address sender, int partitionId, Map<KeyOut,Value> chunk)
           
 
Method Summary
 Map<KeyOut,Value> getChunk()
           
 int getFactoryId()
          Returns DataSerializableFactory factory id for this class.
 int getId()
          Returns type identifier for this class.
 int getPartitionId()
           
 Address getSender()
           
 void readData(ObjectDataInput in)
          Reads fields from the input stream
 String toString()
           
 void writeData(ObjectDataOutput out)
          Writes object fields to output stream
 
Methods inherited from class com.hazelcast.mapreduce.impl.notification.MemberAwareMapReduceNotification
getAddress
 
Methods inherited from class com.hazelcast.mapreduce.impl.notification.MapReduceNotification
getJobId, getName
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

LastChunkNotification

public LastChunkNotification()

LastChunkNotification

public LastChunkNotification(Address address,
                             String name,
                             String jobId,
                             Address sender,
                             int partitionId,
                             Map<KeyOut,Value> chunk)
Method Detail

getChunk

public Map<KeyOut,Value> getChunk()

getPartitionId

public int getPartitionId()

getSender

public Address getSender()

writeData

public void writeData(ObjectDataOutput out)
               throws IOException
Description copied from interface: DataSerializable
Writes object fields to output stream

Specified by:
writeData in interface DataSerializable
Overrides:
writeData in class MemberAwareMapReduceNotification
Parameters:
out - output
Throws:
IOException

readData

public void readData(ObjectDataInput in)
              throws IOException
Description copied from interface: DataSerializable
Reads fields from the input stream

Specified by:
readData in interface DataSerializable
Overrides:
readData in class MemberAwareMapReduceNotification
Parameters:
in - input
Throws:
IOException

getFactoryId

public int getFactoryId()
Description copied from interface: IdentifiedDataSerializable
Returns DataSerializableFactory factory id for this class.

Returns:
factory id

getId

public int getId()
Description copied from interface: IdentifiedDataSerializable
Returns type identifier for this class. Id should be unique per DataSerializableFactory.

Returns:
type id

toString

public String toString()
Overrides:
toString in class MemberAwareMapReduceNotification


Copyright © 2015 Hazelcast, Inc.. All Rights Reserved.