Add missing documentation: In Lucene 5+, instantiating FSDirectory creates the directory in file system if it does not yet exist

git-svn-id: https://svn.apache.org/repos/asf/lucene/dev/trunk@1657428 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Uwe Schindler 2015-02-04 22:20:31 +00:00
parent 348e1d07e3
commit 7b6c0a0126
5 changed files with 12 additions and 0 deletions

View File

@ -114,6 +114,7 @@ public abstract class FSDirectory extends BaseDirectory {
protected final Path directory; // The underlying filesystem directory
/** Create a new FSDirectory for the named location (ctor for subclasses).
* The directory is created at the named location if it does not yet exist.
* @param path the path of the directory
* @param lockFactory the lock factory to use, or null for the default
* ({@link NativeFSLockFactory});
@ -128,6 +129,7 @@ public abstract class FSDirectory extends BaseDirectory {
/** Creates an FSDirectory instance, trying to pick the
* best implementation given the current environment.
* The directory returned uses the {@link NativeFSLockFactory}.
* The directory is created at the named location if it does not yet exist.
*
* <p>Currently this returns {@link MMapDirectory} for most Solaris
* and Windows 64-bit JREs, {@link NIOFSDirectory} for other

View File

@ -88,6 +88,7 @@ public class MMapDirectory extends FSDirectory {
final int chunkSizePower;
/** Create a new MMapDirectory for the named location.
* The directory is created at the named location if it does not yet exist.
*
* @param path the path of the directory
* @param lockFactory the lock factory to use
@ -98,6 +99,7 @@ public class MMapDirectory extends FSDirectory {
}
/** Create a new MMapDirectory for the named location and {@link FSLockFactory#getDefault()}.
* The directory is created at the named location if it does not yet exist.
*
* @param path the path of the directory
* @throws IOException if there is a low-level I/O error
@ -107,6 +109,7 @@ public class MMapDirectory extends FSDirectory {
}
/** Create a new MMapDirectory for the named location and {@link FSLockFactory#getDefault()}.
* The directory is created at the named location if it does not yet exist.
*
* @param path the path of the directory
* @param maxChunkSize maximum chunk size (default is 1 GiBytes for
@ -120,6 +123,7 @@ public class MMapDirectory extends FSDirectory {
/**
* Create a new MMapDirectory for the named location, specifying the
* maximum chunk size used for memory mapping.
* The directory is created at the named location if it does not yet exist.
*
* @param path the path of the directory
* @param lockFactory the lock factory to use, or null for the default

View File

@ -54,6 +54,7 @@ import java.util.concurrent.Future; // javadoc
public class NIOFSDirectory extends FSDirectory {
/** Create a new NIOFSDirectory for the named location.
* The directory is created at the named location if it does not yet exist.
*
* @param path the path of the directory
* @param lockFactory the lock factory to use
@ -64,6 +65,7 @@ public class NIOFSDirectory extends FSDirectory {
}
/** Create a new NIOFSDirectory for the named location and {@link FSLockFactory#getDefault()}.
* The directory is created at the named location if it does not yet exist.
*
* @param path the path of the directory
* @throws IOException if there is a low-level I/O error

View File

@ -35,6 +35,7 @@ import java.nio.file.StandardOpenOption;
public class SimpleFSDirectory extends FSDirectory {
/** Create a new SimpleFSDirectory for the named location.
* The directory is created at the named location if it does not yet exist.
*
* @param path the path of the directory
* @param lockFactory the lock factory to use
@ -45,6 +46,7 @@ public class SimpleFSDirectory extends FSDirectory {
}
/** Create a new SimpleFSDirectory for the named location and {@link FSLockFactory#getDefault()}.
* The directory is created at the named location if it does not yet exist.
*
* @param path the path of the directory
* @throws IOException if there is a low-level I/O error

View File

@ -38,6 +38,7 @@ import java.nio.file.Path;
public class RAFDirectory extends FSDirectory {
/** Create a new RAFDirectory for the named location.
* The directory is created at the named location if it does not yet exist.
*
* @param path the path of the directory
* @param lockFactory the lock factory to use
@ -49,6 +50,7 @@ public class RAFDirectory extends FSDirectory {
}
/** Create a new SimpleFSDirectory for the named location and {@link FSLockFactory#getDefault()}.
* The directory is created at the named location if it does not yet exist.
*
* @param path the path of the directory
* @throws IOException if there is a low-level I/O error