net.sf.eos.hadoop.mapred.index
Class FsDirectory
java.lang.Object
org.apache.lucene.store.Directory
net.sf.eos.hadoop.mapred.index.FsDirectory
public class FsDirectory
- extends org.apache.lucene.store.Directory
Reads a Lucene index stored in Hadoops DFS.
Copied from Nutch source code.
- Author:
- Nutch Team
- See Also:
org.apache.nutch.indexer.FsDirectory
Fields inherited from class org.apache.lucene.store.Directory |
lockFactory |
Methods inherited from class org.apache.lucene.store.Directory |
clearLock, copy, getLockFactory, getLockID, openInput, setLockFactory |
FsDirectory
public FsDirectory(FileSystem fs,
Path directory,
boolean create,
Configuration conf)
throws IOException
- Throws:
IOException
list
public String[] list()
throws IOException
- Specified by:
list
in class org.apache.lucene.store.Directory
- Throws:
IOException
fileExists
public boolean fileExists(String name)
throws IOException
- Specified by:
fileExists
in class org.apache.lucene.store.Directory
- Throws:
IOException
fileModified
public long fileModified(String name)
- Specified by:
fileModified
in class org.apache.lucene.store.Directory
touchFile
public void touchFile(String name)
- Specified by:
touchFile
in class org.apache.lucene.store.Directory
fileLength
public long fileLength(String name)
throws IOException
- Specified by:
fileLength
in class org.apache.lucene.store.Directory
- Throws:
IOException
deleteFile
public void deleteFile(String name)
throws IOException
- Specified by:
deleteFile
in class org.apache.lucene.store.Directory
- Throws:
IOException
renameFile
public void renameFile(String from,
String to)
throws IOException
- Specified by:
renameFile
in class org.apache.lucene.store.Directory
- Throws:
IOException
createOutput
public org.apache.lucene.store.IndexOutput createOutput(String name)
throws IOException
- Specified by:
createOutput
in class org.apache.lucene.store.Directory
- Throws:
IOException
openInput
public org.apache.lucene.store.IndexInput openInput(String name)
throws IOException
- Specified by:
openInput
in class org.apache.lucene.store.Directory
- Throws:
IOException
makeLock
public org.apache.lucene.store.Lock makeLock(String name)
-
- Overrides:
makeLock
in class org.apache.lucene.store.Directory
close
public void close()
throws IOException
- Specified by:
close
in class org.apache.lucene.store.Directory
- Throws:
IOException
toString
public String toString()
- Overrides:
toString
in class Object
Copyright © 2008. All Rights Reserved.