[ https://issues.apache.org/jira/browse/LUCENE-10161?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Ignacio Vera resolved LUCENE-10161. ----------------------------------- Assignee: Ignacio Vera Resolution: Invalid There is no need to add yet another abstraction. Closing as invalid. > Points implementation should distinguish between indexed and not indexed > PointValues > ------------------------------------------------------------------------------------ > > Key: LUCENE-10161 > URL: https://issues.apache.org/jira/browse/LUCENE-10161 > Project: Lucene - Core > Issue Type: Improvement > Reporter: Ignacio Vera > Assignee: Ignacio Vera > Priority: Major > Time Spent: 2h > Remaining Estimate: 0h > > While working in L|UCENE-9820, where we are trying to add a cursor like API > to PointValues API, I had a lot of friction with MutablePointValues. The > issue is that this interface is representing non-indexed points but it is > extending PointValues that describes indexed points. > Therefore here is proposed to extract a minimal interface from PointValues > that represents not-indexed points. There idea would be something like: > > {code:java} > /** > * Access to numeric values. > * > * @lucene.experimental > */ > public interface PointValuesReader { > /** > * Provides access to the points in this reader. > * > * @lucene.experimental > */ > @FunctionalInterface > interface DocValueVisitor { > /** > * Called for all documents in the reader when called in {@link > * #visitDocValues(DocValueVisitor)}. > */ > void visit(int docID, byte[] packedValue) throws IOException; > } > /** Visit all doc and values in this reader */ > void visitDocValues(DocValueVisitor visitor) throws IOException; > /** Returns the total number of points in this reader. */ > long size(); > } {code} > > This interface should be implemented by MutablePointValues and PointValues > and should simplify the current implementation. -- This message was sent by Atlassian Jira (v8.20.1#820001) --------------------------------------------------------------------- To unsubscribe, e-mail: issues-unsubscr...@lucene.apache.org For additional commands, e-mail: issues-h...@lucene.apache.org