improve javadocs

git-svn-id: https://svn.apache.org/repos/asf/lucene/dev/trunk@1601342 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Michael McCandless 2014-06-09 11:11:22 +00:00
parent 07aeef7a71
commit f205a8bc19
1 changed files with 13 additions and 3 deletions

View File

@ -32,9 +32,19 @@ import java.util.WeakHashMap;
import java.util.concurrent.atomic.AtomicInteger;
// javadocs
/** IndexReader is an abstract class, providing an interface for accessing an
index. Search of an index is done entirely through this abstract interface,
so that any subclass which implements it is searchable.
/**
IndexReader is an abstract class, providing an interface for accessing a
point-in-time view of an index. Any changes made to the index
via {@link IndexWriter} will not be visible until a new
{@code IndexReader} is opened. It's best to use {@link
DirectoryReader#open(IndexWriter,boolean)} to obtain an
{@code IndexReader}, if your {@link IndexWriter} is
in-process. When you need to re-open to see changes to the
index, it's best to use {@link DirectoryReader#openIfChanged(DirectoryReader)}
since the new reader will share resources with the previous
one when possible. Search of an index is done entirely
through this abstract interface, so that any subclass which
implements it is searchable.
<p>There are two different types of IndexReaders:
<ul>