X-Git-Url: https://git.mdrn.pl/pylucene.git/blobdiff_plain/a2e61f0c04805cfcb8706176758d1283c7e3a55c..aaeed5504b982cf3545252ab528713250aa33eed:/lucene-java-3.4.0/lucene/contrib/facet/src/java/org/apache/lucene/DocumentBuilder.java diff --git a/lucene-java-3.4.0/lucene/contrib/facet/src/java/org/apache/lucene/DocumentBuilder.java b/lucene-java-3.4.0/lucene/contrib/facet/src/java/org/apache/lucene/DocumentBuilder.java deleted file mode 100644 index 26cee4b..0000000 --- a/lucene-java-3.4.0/lucene/contrib/facet/src/java/org/apache/lucene/DocumentBuilder.java +++ /dev/null @@ -1,77 +0,0 @@ -package org.apache.lucene; - -import org.apache.lucene.document.Document; -import org.apache.lucene.document.Field; - -/** - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. - * The ASF licenses this file to You under the Apache License, Version 2.0 - * (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -/** - * An interface which standardizes the process of building an indexable - * {@link Document}. - *

- * The idea is that implementations implement {@link #build(Document doc)}, - * which adds to the given Document whatever {@link Field}s it wants to add. A - * DocumentBuilder is also allowed to inspect or change existing Fields in the - * Document, if it wishes to. - *

- * Implementations should normally have a constructor with parameters which - * determine what {@link #build(Document)} will add to doc.
- * To allow reuse of the DocumentBuilder object, implementations are also - * encouraged to have a setter method, which remembers its parameters just like - * the constructor. This setter method cannot be described in this interface, - * because it will take different parameters in each implementation. - *

- * The interface defines a builder pattern, which allows applications to invoke - * several document builders in the following way: - * - *

- * builder1.build(builder2.build(builder3.build(new Document())));
- * 
- * - * @lucene.experimental - */ -public interface DocumentBuilder { - - /** An exception thrown from {@link DocumentBuilder}'s build(). */ - public static class DocumentBuilderException extends Exception { - - public DocumentBuilderException() { - super(); - } - - public DocumentBuilderException(String message) { - super(message); - } - - public DocumentBuilderException(String message, Throwable cause) { - super(message, cause); - } - - public DocumentBuilderException(Throwable cause) { - super(cause); - } - - } - - /** - * Adds to the given document whatever {@link Field}s the implementation needs - * to add. Return the docunment instance to allow for chaining calls. - */ - public Document build(Document doc) throws DocumentBuilderException; - -}