lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Shane <>
Subject Determining if index exists Lucene 2.1
Date Fri, 23 Feb 2007 18:53:18 GMT

Prior to Lucene 2.1, I was using FSDirectory.getDirectory(String path, 
boolean create)|| inside of a try block to determine whether or not a 
directory existed.

With the deprecation of the above class call in Lucene 2.1,  I need a 
new method for determining the existence of an index.  I can just check 
to see if either of the files INDEX_PATH/segments or 
INDEX_PATH/segments.gen exist, but that doesn't seem like the best route.

Is there a function call to determine whether or not an index already 



To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message