mirror of
https://github.com/XRPLF/rippled.git
synced 2025-12-06 17:27:55 +00:00
Add more iterator functions
This commit is contained in:
@@ -22,6 +22,21 @@ public class Iterator {
|
||||
seekToFirst0(nativeHandle_);
|
||||
}
|
||||
|
||||
public void seekToLast() {
|
||||
assert(isInitialized());
|
||||
seekToLast0(nativeHandle_);
|
||||
}
|
||||
|
||||
public void next() {
|
||||
assert(isInitialized());
|
||||
next0(nativeHandle_);
|
||||
}
|
||||
|
||||
public void prev() {
|
||||
assert(isInitialized());
|
||||
prev0(nativeHandle_);
|
||||
}
|
||||
|
||||
public synchronized void close() {
|
||||
if(nativeHandle_ != 0) {
|
||||
close0(nativeHandle_);
|
||||
@@ -39,4 +54,7 @@ public class Iterator {
|
||||
private native boolean isValid0(long handle);
|
||||
private native void close0(long handle);
|
||||
private native void seekToFirst0(long handle);
|
||||
private native void seekToLast0(long handle);
|
||||
private native void next0(long handle);
|
||||
private native void prev0(long handle);
|
||||
}
|
||||
Reference in New Issue
Block a user