[ Skip to the content ]

Institute of Formal and Applied Linguistics Wiki


[ Back to the navigation ]

This is an old revision of the document!


Table of Contents

MapReduce Tutorial : Custom data types

An important feature of the Java API is that custom data and format types can be provided. In this step we implement two custom data types.

BERIntWritable

We want to implement BERIntWritable, which is an int stored in the format of pack “w”, $num. Quoting: The bytes represent an unsigned integer in base 128, most significant digit first, with as few digits as possible. Bit eight (the high bit) is set on each byte except the last.

The new class must implement the Writable interface:

 

PairWritable<A, B>


[ Back to the navigation ] [ Back to the content ]