maedhroz commented on code in PR #2498:
URL: https://github.com/apache/cassandra/pull/2498#discussion_r1270133292
##########
src/java/org/apache/cassandra/index/sai/disk/v1/LongArray.java:
##########
@@ -37,6 +37,13 @@ public interface LongArray extends Closeable
*/
long length();
+ /**
+ * Using the given token returns the first row ID corresponding to the
token.
+ * @param targetToken Token to lookup and it must not be smaller than
previous value
+ * @return The row ID of the given token or negative value if target token
is greater than all tokens
+ */
+ long findTokenRowID(long targetToken);
Review Comment:
It also would make `PostingsReader.LongArrayReader` less odd I guess.
##########
src/java/org/apache/cassandra/index/sai/disk/v1/LongArray.java:
##########
@@ -37,6 +37,13 @@ public interface LongArray extends Closeable
*/
long length();
+ /**
+ * Using the given token returns the first row ID corresponding to the
token.
+ * @param targetToken Token to lookup and it must not be smaller than
previous value
+ * @return The row ID of the given token or negative value if target token
is greater than all tokens
+ */
+ long findTokenRowID(long targetToken);
Review Comment:
It also would make `PostingsReader.LongArrayReader` less awkward I guess.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]