org.cloudgraph.rocksdb.client.RocksDBResultScanner Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of cloudgraph-rocksdb Show documentation
Show all versions of cloudgraph-rocksdb Show documentation
CloudGraph(tm) is a suite of Service Data Object (SDO) 2.1 services designed for relational and big-table style "cloud" databases, such as HBase and others.
The newest version!
package org.cloudgraph.rocksdb.client;
import java.io.IOException;
import java.util.ArrayList;
import java.util.Collections;
import java.util.Iterator;
import java.util.List;
import org.cloudgraph.core.client.Result;
import org.cloudgraph.core.client.ResultScanner;
public class RocksDBResultScanner implements ResultScanner {
List results = Collections.EMPTY_LIST;
public RocksDBResultScanner(RocksDBResult[] result) {
results = new ArrayList(result.length);
for (RocksDBResult r : result)
results.add(r);
}
@Override
public Iterator iterator() {
return new Iterator() {
final Iterator iter = results.iterator();
@Override
public boolean hasNext() {
return iter.hasNext();
}
@Override
public Result next() {
return iter.next();
}
};
}
@Override
public void close() {
this.results = null;
}
@Override
public Result next() throws IOException {
throw new IllegalStateException("not implemented");
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy