otis 2003/10/22 09:24:25
Modified: src/java/org/apache/lucene/store RAMDirectory.java
Log:
- Commented out left-over debugging/print statements
- Nuked trailing spaces
Revision Changes Path
1.10 +13 -11
jakarta-lucene/src/java/org/apache/lucene/store/RAMDirectory.java
Index: RAMDirectory.java
===================================================================
RCS file:
/home/cvs/jakarta-lucene/src/java/org/apache/lucene/store/RAMDirectory.java,v
retrieving revision 1.9
retrieving revision 1.10
diff -u -r1.9 -r1.10
--- RAMDirectory.java 25 Sep 2003 21:45:58 -0000 1.9
+++ RAMDirectory.java 22 Oct 2003 16:24:25 -0000 1.10
@@ -146,23 +146,25 @@
/** Set the modified time of an existing file to now. */
public void touchFile(String name) throws IOException {
- final boolean MONITOR = false;
+// final boolean MONITOR = false;
int count = 0;
-
+
RAMFile file = (RAMFile)files.get(name);
long ts2, ts1 = System.currentTimeMillis();
do {
- try {
- Thread.sleep(0, 1);
- } catch (InterruptedException e) {}
- ts2 = System.currentTimeMillis();
- if (MONITOR) count ++;
+ try {
+ Thread.sleep(0, 1);
+ } catch (InterruptedException e) {}
+ ts2 = System.currentTimeMillis();
+// if (MONITOR) {
+// count++;
+// }
} while(ts1 == ts2);
-
+
file.lastModified = ts2;
- if (MONITOR)
- System.out.println("SLEEP COUNT: " + count);
+// if (MONITOR)
+// System.out.println("SLEEP COUNT: " + count);
}
/** Returns the length in bytes of a file in the directory. */
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]