public class LuceneSegmentInputSplit
extends org.apache.hadoop.mapreduce.InputSplit
implements org.apache.hadoop.io.Writable
InputSplit implementation that represents a Lucene segment.| Constructor and Description |
|---|
LuceneSegmentInputSplit() |
LuceneSegmentInputSplit(org.apache.hadoop.fs.Path indexPath,
String segmentInfoName,
long length) |
| Modifier and Type | Method and Description |
|---|---|
org.apache.hadoop.fs.Path |
getIndexPath() |
long |
getLength() |
String[] |
getLocations() |
org.apache.lucene.index.SegmentInfoPerCommit |
getSegment(org.apache.hadoop.conf.Configuration configuration)
Get the
SegmentInfo of this InputSplit via the given Configuration |
String |
getSegmentInfoName() |
void |
readFields(DataInput in) |
void |
write(DataOutput out) |
public LuceneSegmentInputSplit()
public LuceneSegmentInputSplit(org.apache.hadoop.fs.Path indexPath,
String segmentInfoName,
long length)
public long getLength()
throws IOException,
InterruptedException
getLength in class org.apache.hadoop.mapreduce.InputSplitIOExceptionInterruptedExceptionpublic String[] getLocations() throws IOException, InterruptedException
getLocations in class org.apache.hadoop.mapreduce.InputSplitIOExceptionInterruptedExceptionpublic String getSegmentInfoName()
public org.apache.hadoop.fs.Path getIndexPath()
public void write(DataOutput out) throws IOException
write in interface org.apache.hadoop.io.WritableIOExceptionpublic void readFields(DataInput in) throws IOException
readFields in interface org.apache.hadoop.io.WritableIOExceptionpublic org.apache.lucene.index.SegmentInfoPerCommit getSegment(org.apache.hadoop.conf.Configuration configuration)
throws IOException
SegmentInfo of this InputSplit via the given Configurationconfiguration - the configuration used to locate the indexIOException - if an error occurs when accessing the directoryCopyright © 2008–2013 The Apache Software Foundation. All rights reserved.