mirror of https://github.com/apache/lucene.git
lucene-monitor: make static DocumentBatch.of package scope
This commit is contained in:
parent
8698dd85d8
commit
f00a707364
|
@ -41,7 +41,7 @@ abstract class DocumentBatch implements Closeable, Supplier<LeafReader> {
|
||||||
* @param doc the document to add
|
* @param doc the document to add
|
||||||
* @return the batch containing the input document
|
* @return the batch containing the input document
|
||||||
*/
|
*/
|
||||||
public static DocumentBatch of(Analyzer analyzer, Document doc) {
|
static DocumentBatch of(Analyzer analyzer, Document doc) {
|
||||||
return new SingletonDocumentBatch(analyzer, doc);
|
return new SingletonDocumentBatch(analyzer, doc);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -52,7 +52,7 @@ abstract class DocumentBatch implements Closeable, Supplier<LeafReader> {
|
||||||
* collection.
|
* collection.
|
||||||
* @return the batch containing the input documents
|
* @return the batch containing the input documents
|
||||||
*/
|
*/
|
||||||
public static DocumentBatch of(Analyzer analyzer, Document... docs) {
|
static DocumentBatch of(Analyzer analyzer, Document... docs) {
|
||||||
if (docs.length == 0) {
|
if (docs.length == 0) {
|
||||||
throw new IllegalArgumentException("A DocumentBatch must contain at least one document");
|
throw new IllegalArgumentException("A DocumentBatch must contain at least one document");
|
||||||
} else if (docs.length == 1) {
|
} else if (docs.length == 1) {
|
||||||
|
|
Loading…
Reference in New Issue