public byte[] key() throws NativeDB.DBException { assertAllocated(); long slice_ptr = IteratorJNI.key(self); checkStatus(); try { NativeSlice slice = new NativeSlice(); slice.read(slice_ptr, 0); return slice.toByteArray(); } finally { NativeSlice.SliceJNI.delete(slice_ptr); } }
public Snapshot write(WriteBatch updates, WriteOptions options) throws DBException { if( db==null ) { throw new DBException("Closed"); } try { db.write(convert(options), ((JniWriteBatch) updates).writeBatch()); return null; } catch (NativeDB.DBException e) { throw new DBException(e.getMessage(), e); } }
public byte[] value() throws NativeDB.DBException { assertAllocated(); long slice_ptr = IteratorJNI.value(self); checkStatus(); try { NativeSlice slice = new NativeSlice(); slice.read(slice_ptr, 0); return slice.toByteArray(); } finally { NativeSlice.SliceJNI.delete(slice_ptr); } } }
public void delete(byte[] key) { NativeDB.checkArgNotNull(key, "key"); NativeBuffer keyBuffer = NativeBuffer.create(key); try { delete(keyBuffer); } finally { keyBuffer.delete(); } }
public void write(NativeWriteOptions options, NativeWriteBatch updates) throws DBException { checkArgNotNull(options, "options"); checkArgNotNull(updates, "updates"); checkStatus(DBJNI.Write(self, options, updates.pointer())); }
public void next() throws NativeDB.DBException { assertAllocated(); IteratorJNI.Next(self); checkStatus(); }
public void prev() throws NativeDB.DBException { assertAllocated(); IteratorJNI.Prev(self); checkStatus(); }
private void seek(NativeSlice keySlice) throws NativeDB.DBException { assertAllocated(); IteratorJNI.Seek(self, keySlice); checkStatus(); }
public void delete() { assertAllocated(); StatusJNI.delete(self); self = 0; }
public void delete() { assertAllocated(); DBJNI.delete(self); self = 0; }
public void delete() { if( name_buffer!=null ) { name_buffer.delete(); name_buffer = null; } if( globalRef!=0 ) { NativeDB.DBJNI.DeleteGlobalRef(globalRef); globalRef = 0; } }
public void delete() { assertAllocated(); WriteBatchJNI.delete(self); self = 0; }
public byte[] key() throws NativeDB.DBException { assertAllocated(); long slice_ptr = IteratorJNI.key(self); checkStatus(); try { NativeSlice slice = new NativeSlice(); slice.read(slice_ptr, 0); return slice.toByteArray(); } finally { NativeSlice.SliceJNI.delete(slice_ptr); } }
public void delete(byte[] key) { NativeDB.checkArgNotNull(key, "key"); NativeBuffer keyBuffer = NativeBuffer.create(key); try { delete(keyBuffer); } finally { keyBuffer.delete(); } }
public void next() throws NativeDB.DBException { assertAllocated(); IteratorJNI.Next(self); checkStatus(); }
public void delete() { assertAllocated(); StatusJNI.delete(self); self = 0; }
public void delete() { assertAllocated(); DBJNI.delete(self); self = 0; }
public void delete(byte[] key) { NativeDB.checkArgNotNull(key, "key"); NativeBuffer keyBuffer = NativeBuffer.create(key); try { delete(keyBuffer); } finally { keyBuffer.delete(); } }