org.apache.hadoop.contrib.index.lucene
Class FileSystemDirectory
java.lang.Object
   org.apache.lucene.store.Directory
org.apache.lucene.store.Directory
       org.apache.hadoop.contrib.index.lucene.FileSystemDirectory
org.apache.hadoop.contrib.index.lucene.FileSystemDirectory
- public class FileSystemDirectory 
- extends org.apache.lucene.store.Directory
This class implements a Lucene Directory on top of a general FileSystem.
 Currently it does not support locking.
 
| Fields inherited from class org.apache.lucene.store.Directory | 
| lockFactory | 
 
 
 
| Methods inherited from class org.apache.lucene.store.Directory | 
| clearLock, copy, getLockFactory, getLockID, setLockFactory | 
 
 
FileSystemDirectory
public FileSystemDirectory(FileSystem fs,
                           Path directory,
                           boolean create,
                           Configuration conf)
                    throws IOException
- Constructor
 
- Parameters:
- fs-
- directory-
- create-
- conf-
- Throws:
- IOException
 
list
public String[] list()
              throws IOException
- 
- Specified by:
- listin class- org.apache.lucene.store.Directory
 
- 
- Throws:
- IOException
 
fileExists
public boolean fileExists(String name)
                   throws IOException
- 
- Specified by:
- fileExistsin class- org.apache.lucene.store.Directory
 
- 
- Throws:
- IOException
 
fileModified
public long fileModified(String name)
- 
- Specified by:
- fileModifiedin class- org.apache.lucene.store.Directory
 
- 
 
touchFile
public void touchFile(String name)
- 
- Specified by:
- touchFilein class- org.apache.lucene.store.Directory
 
- 
 
fileLength
public long fileLength(String name)
                throws IOException
- 
- Specified by:
- fileLengthin class- org.apache.lucene.store.Directory
 
- 
- Throws:
- IOException
 
deleteFile
public void deleteFile(String name)
                throws IOException
- 
- Specified by:
- deleteFilein class- org.apache.lucene.store.Directory
 
- 
- Throws:
- IOException
 
renameFile
public void renameFile(String from,
                       String to)
                throws IOException
- 
- Specified by:
- renameFilein class- org.apache.lucene.store.Directory
 
- 
- Throws:
- IOException
 
createOutput
public org.apache.lucene.store.IndexOutput createOutput(String name)
                                                 throws IOException
- 
- Specified by:
- createOutputin class- org.apache.lucene.store.Directory
 
- 
- Throws:
- IOException
 
openInput
public org.apache.lucene.store.IndexInput openInput(String name)
                                             throws IOException
- 
- Specified by:
- openInputin class- org.apache.lucene.store.Directory
 
- 
- Throws:
- IOException
 
openInput
public org.apache.lucene.store.IndexInput openInput(String name,
                                                    int bufferSize)
                                             throws IOException
- 
- Overrides:
- openInputin class- org.apache.lucene.store.Directory
 
- 
- Throws:
- IOException
 
makeLock
public org.apache.lucene.store.Lock makeLock(String name)
- 
- Overrides:
- makeLockin class- org.apache.lucene.store.Directory
 
- 
 
close
public void close()
           throws IOException
- 
- Specified by:
- closein class- org.apache.lucene.store.Directory
 
- 
- Throws:
- IOException
 
toString
public String toString()
- 
- Overrides:
- toStringin class- Object
 
- 
 
Copyright © 2009 The Apache Software Foundation