mirror of https://github.com/apache/lucene.git
SOLR-9480 followup: remove/abstract deprecated implementations on master
This commit is contained in:
parent
2ce53791d3
commit
0bf1eae92c
|
@ -68,20 +68,9 @@ public abstract class SlotAcc implements Closeable {
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @deprecated This method exists only for backcompatibility, developers of new {@link SlotAcc}
|
* All subclasses must override this method to collect documents. This method is called by the
|
||||||
* implementations should not implement this method, and should instead override
|
* default impl of {@link #collect(DocSet,int,IntFunction)} but it's also neccessary if this accumulator
|
||||||
* {@link #collect(int,int,IntFunction)}
|
* is used for sorting.
|
||||||
*/
|
|
||||||
@Deprecated
|
|
||||||
public void collect(int doc, int slot) throws IOException {
|
|
||||||
throw new UnsupportedOperationException
|
|
||||||
("SlotAcc implementations must implement 'collect(int,int,IntFunction<SlotContext>)' or the (deprecated)"
|
|
||||||
+ "'collect(int,int)'");
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* All subclasses should override this method, for backcompatability the default implementaion
|
|
||||||
* delegates to the (deprecated) {@link #collect(int,int)}
|
|
||||||
*
|
*
|
||||||
* @param doc Single Segment docId (relative to the current {@link LeafReaderContext} to collect
|
* @param doc Single Segment docId (relative to the current {@link LeafReaderContext} to collect
|
||||||
* @param slot The slot number to collect this document in
|
* @param slot The slot number to collect this document in
|
||||||
|
@ -90,10 +79,7 @@ public abstract class SlotAcc implements Closeable {
|
||||||
* the current slot, and the {@link SlotContext} returned is only valid for the duration
|
* the current slot, and the {@link SlotContext} returned is only valid for the duration
|
||||||
* of the <code>collect()</code> call.
|
* of the <code>collect()</code> call.
|
||||||
*/
|
*/
|
||||||
@Deprecated
|
public abstract void collect(int doc, int slot, IntFunction<SlotContext> slotContext) throws IOException;
|
||||||
public void collect(int doc, int slot, IntFunction<SlotContext> slotContext) throws IOException {
|
|
||||||
collect(doc,slot);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Bulk collection of all documents in a slot. The default implementation calls {@link #collect(int,int,IntFunction)}
|
* Bulk collection of all documents in a slot. The default implementation calls {@link #collect(int,int,IntFunction)}
|
||||||
|
|
Loading…
Reference in New Issue