otis 2004/03/18 11:51:24 Modified: src/java/org/apache/lucene/index IndexWriter.java src/java/org/apache/lucene/store FSDirectory.java Log: - Changed some properties from private to public and added Javadocs Revision Changes Path 1.25 +36 -6 jakarta-lucene/src/java/org/apache/lucene/index/IndexWriter.java Index: IndexWriter.java =================================================================== RCS file: /home/cvs/jakarta-lucene/src/java/org/apache/lucene/index/IndexWriter.java,v retrieving revision 1.24 retrieving revision 1.25 diff -u -r1.24 -r1.25 --- IndexWriter.java 18 Mar 2004 19:05:18 -0000 1.24 +++ IndexWriter.java 18 Mar 2004 19:51:24 -0000 1.25 @@ -49,9 +49,19 @@ */ public class IndexWriter { + + /** + * Default value is 1000. Use <code>org.apache.lucene.writeLockTimeout</code> + * system property to override. + */ public static long WRITE_LOCK_TIMEOUT = Integer.parseInt(System.getProperty("org.apache.lucene.writeLockTimeout", "1000")); + + /** + * Default value is 10000. Use <code>org.apache.lucene.commitLockTimeout</code> + * system property to override. + */ public static long COMMIT_LOCK_TIMEOUT = Integer.parseInt(System.getProperty("org.apache.lucene.commitLockTimeout", "10000")); @@ -59,18 +69,38 @@ public static final String WRITE_LOCK_NAME = "write.lock"; public static final String COMMIT_LOCK_NAME = "commit.lock"; - private static final int DEFAULT_MERGE_FACTOR = + /** + * Default value is 10. Use <code>org.apache.lucene.mergeFactor</code> + * system property to override. + */ + public static final int DEFAULT_MERGE_FACTOR = Integer.parseInt(System.getProperty("org.apache.lucene.mergeFactor", "10")); - private static final int DEFAULT_MIN_MERGE_DOCS = + + /** + * Default value is 10. Use <code>org.apache.lucene.minMergeDocs</code> + * system property to override. + */ + public static final int DEFAULT_MIN_MERGE_DOCS = Integer.parseInt(System.getProperty("org.apache.lucene.minMergeDocs", "10")); - private static final int DEFAULT_MAX_FIELD_LENGTH = - Integer.parseInt(System.getProperty("org.apache.lucene.maxFieldLength", - "10000")); - private static final int DEFAULT_MAX_MERGE_DOCS = + + /** + * Default value is [EMAIL PROTECTED] Integer#MAX_VALUE}. + * Use <code>org.apache.lucene.maxMergeDocs</code> system property to override. + */ + public static final int DEFAULT_MAX_MERGE_DOCS = Integer.parseInt(System.getProperty("org.apache.lucene.maxMergeDocs", String.valueOf(Integer.MAX_VALUE))); + + /** + * Default value is 10000. Use <code>org.apache.lucene.maxFieldLength</code> + * system property to override. + */ + public static final int DEFAULT_MAX_FIELD_LENGTH = + Integer.parseInt(System.getProperty("org.apache.lucene.maxFieldLength", + "10000")); + private Directory directory; // where this index resides private Analyzer analyzer; // how to analyze text 1.25 +7 -3 jakarta-lucene/src/java/org/apache/lucene/store/FSDirectory.java Index: FSDirectory.java =================================================================== RCS file: /home/cvs/jakarta-lucene/src/java/org/apache/lucene/store/FSDirectory.java,v retrieving revision 1.24 retrieving revision 1.25 diff -u -r1.24 -r1.25 --- FSDirectory.java 18 Mar 2004 19:44:45 -0000 1.24 +++ FSDirectory.java 18 Mar 2004 19:51:24 -0000 1.25 @@ -86,9 +86,13 @@ private static final boolean DISABLE_LOCKS = Boolean.getBoolean("disableLuceneLocks") || Constants.JAVA_1_1; - private static final String LOCK_DIR = - System.getProperty("org.apache.lucene.lockdir", - System.getProperty("java.io.tmpdir")); + /** + * Directory specified by <code>org.apache.lucene.lockdir</code> + * or <code>java.io.tmpdir</code> system property + */ + public static final String LOCK_DIR = + System.getProperty("org.apache.lucene.lockdir", + System.getProperty("java.io.tmpdir")); private static MessageDigest DIGESTER;
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]