extends HiveContextAwareRecordReader<K, V> {
public CombineHiveRecordReader(InputSplit split, Configuration conf,
Reporter reporter, Integer partition) throws IOException {
super((JobConf)conf);
CombineHiveInputSplit hsplit = new CombineHiveInputSplit(jobConf,
(InputSplitShim) split);
String inputFormatClassName = hsplit.inputFormatClassName();
Class inputFormatClass = null;
try {
inputFormatClass = Class.forName(inputFormatClassName);
} catch (ClassNotFoundException e) {
throw new IOException("CombineHiveRecordReader: class not found "
+ inputFormatClassName);
}
InputFormat inputFormat = HiveInputFormat.getInputFormatFromCache(
inputFormatClass, jobConf);
// create a split for the given partition
FileSplit fsplit = new FileSplit(hsplit.getPaths()[partition], hsplit
.getStartOffsets()[partition], hsplit.getLengths()[partition], hsplit
.getLocations());
this.setRecordReader(inputFormat.getRecordReader(fsplit, jobConf, reporter));
this.initIOContext(fsplit, jobConf, inputFormatClass, this.recordReader);