3 import org.yaz4j.jni.SWIGTYPE_p_ZOOM_scanset_p;
4 import org.yaz4j.jni.SWIGTYPE_p_int;
5 import org.yaz4j.jni.yaz4jlib;
9 private SWIGTYPE_p_ZOOM_scanset_p scanSet = null;
10 private Connection connection;
11 private boolean disposed = false;
13 ScanSet(SWIGTYPE_p_ZOOM_scanset_p scanSet, Connection connection) {
14 this.connection = connection;
15 this.scanSet = scanSet;
18 public void finalize() {
22 public ScanTerm get(long index) {
23 SWIGTYPE_p_int occ = yaz4jlib.new_intp();
24 SWIGTYPE_p_int length = yaz4jlib.new_intp();
25 String term = yaz4jlib.ZOOM_scanset_term(scanSet, (long) index, occ, length);
26 int occurences = yaz4jlib.intp_value(occ);
27 yaz4jlib.delete_intp(occ);
28 yaz4jlib.delete_intp(length);
29 return new ScanTerm(term, occurences);
32 public long getSize() {
33 return yaz4jlib.ZOOM_scanset_size(scanSet);
36 public void Dispose() {
38 yaz4jlib.ZOOM_scanset_destroy(scanSet);