public static class IndexedStorage.IndexedStorageInputFormat.IndexedStorageRecordReader
extends org.apache.hadoop.mapreduce.RecordReader<org.apache.hadoop.io.LongWritable,org.apache.hadoop.io.Text>
Modifier and Type | Class and Description |
---|---|
static class |
IndexedStorage.IndexedStorageInputFormat.IndexedStorageRecordReader.IndexedStorageLineReader |
static class |
IndexedStorage.IndexedStorageInputFormat.IndexedStorageRecordReader.IndexedStorageRecordReaderComparator
Class to compare record readers using underlying indexes
|
Constructor and Description |
---|
IndexedStorage.IndexedStorageInputFormat.IndexedStorageRecordReader(IndexedStorage.IndexManager im) |
Modifier and Type | Method and Description |
---|---|
void |
close() |
org.apache.hadoop.io.LongWritable |
getCurrentKey() |
org.apache.hadoop.io.Text |
getCurrentValue() |
float |
getProgress() |
void |
initialize(org.apache.hadoop.mapreduce.InputSplit genericSplit,
org.apache.hadoop.mapreduce.TaskAttemptContext context) |
boolean |
nextKeyValue() |
void |
seek(long offset) |
boolean |
seekNear(Tuple keys)
Scan the index for given key and seek to appropriate offset in the data
|
String |
toString() |
public IndexedStorage.IndexedStorageInputFormat.IndexedStorageRecordReader(IndexedStorage.IndexManager im)
public void initialize(org.apache.hadoop.mapreduce.InputSplit genericSplit, org.apache.hadoop.mapreduce.TaskAttemptContext context) throws IOException, InterruptedException
initialize
in class org.apache.hadoop.mapreduce.RecordReader<org.apache.hadoop.io.LongWritable,org.apache.hadoop.io.Text>
IOException
InterruptedException
public void seek(long offset) throws IOException
IOException
public boolean seekNear(Tuple keys) throws IOException
keys
- to look forIOException
public boolean nextKeyValue() throws IOException, InterruptedException
nextKeyValue
in class org.apache.hadoop.mapreduce.RecordReader<org.apache.hadoop.io.LongWritable,org.apache.hadoop.io.Text>
IOException
InterruptedException
public org.apache.hadoop.io.LongWritable getCurrentKey() throws IOException, InterruptedException
getCurrentKey
in class org.apache.hadoop.mapreduce.RecordReader<org.apache.hadoop.io.LongWritable,org.apache.hadoop.io.Text>
IOException
InterruptedException
public org.apache.hadoop.io.Text getCurrentValue() throws IOException, InterruptedException
getCurrentValue
in class org.apache.hadoop.mapreduce.RecordReader<org.apache.hadoop.io.LongWritable,org.apache.hadoop.io.Text>
IOException
InterruptedException
public float getProgress() throws IOException, InterruptedException
getProgress
in class org.apache.hadoop.mapreduce.RecordReader<org.apache.hadoop.io.LongWritable,org.apache.hadoop.io.Text>
IOException
InterruptedException
public void close() throws IOException
close
in interface Closeable
close
in interface AutoCloseable
close
in class org.apache.hadoop.mapreduce.RecordReader<org.apache.hadoop.io.LongWritable,org.apache.hadoop.io.Text>
IOException
Copyright © 2007-2012 The Apache Software Foundation