Package redis.clients.jedis.resps
Class ScanResult<T>
- java.lang.Object
-
- redis.clients.jedis.resps.ScanResult<T>
-
public class ScanResult<T> extends java.lang.ObjectScanResult compatibility stub for Valkey GLIDE wrapper.
-
-
Constructor Summary
Constructors Constructor Description ScanResult(byte[] cursor, java.util.List<T> result)Creates a ScanResult with a byte array cursor.ScanResult(java.lang.String cursor, java.util.List<T> result)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.StringgetCursor()byte[]getCursorAsBytes()Returns the cursor as a byte array.java.util.List<T>getResult()booleanisCompleteIteration()Checks if the scan iteration is complete.java.lang.StringtoString()
-
-
-
Constructor Detail
-
ScanResult
public ScanResult(java.lang.String cursor, java.util.List<T> result)
-
ScanResult
public ScanResult(byte[] cursor, java.util.List<T> result)Creates a ScanResult with a byte array cursor.This constructor provides compatibility with original Jedis which supports binary cursors.
- Parameters:
cursor- the cursor as a byte arrayresult- the list of scan results
-
-
Method Detail
-
getCursor
public java.lang.String getCursor()
-
getCursorAsBytes
public byte[] getCursorAsBytes()
Returns the cursor as a byte array.This method provides compatibility with original Jedis which supports binary cursor operations.
- Returns:
- the cursor as bytes
-
getResult
public java.util.List<T> getResult()
-
isCompleteIteration
public boolean isCompleteIteration()
Checks if the scan iteration is complete.A scan iteration is complete when the cursor is "0", indicating that all keys have been scanned and the iteration should stop.
- Returns:
- true if the iteration is complete (cursor is "0"), false otherwise
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
-