/** * {@inheritDoc} */ @Override public LockResult find(byte[] key) throws IOException { return source.find(key); }
/** * {@inheritDoc} */ @Override public LockResult find(byte[] key) throws IOException { return source.find(key); }
@Override public LockResult find(byte[] key) throws IOException { return mSource.find(key); }
@Override public LockResult find(byte[] key) throws IOException { return mSource.find(key); }
/** * {@inheritDoc} */ @Override public LockResult find(byte[] key) throws IOException { return source.find(key); }
@Override public LockResult find(byte[] key) throws IOException { return mSource.find(key); }
@Override public LockResult find(byte[] key) throws IOException { mKey = null; return mSource.find(mView.applyPrefix(key)); }
@Override public LockResult find(byte[] key) throws IOException { mKey = null; return mSource.find(mView.applyPrefix(key)); }
@Override public LockResult find(byte[] key) throws IOException { mKey = null; return mSource.find(mView.applyPrefix(key)); }
@Override public LockResult find(byte[] key) throws IOException { if (mView.inRange(key)) { return mSource.find(key); } reset(); return LockResult.UNOWNED; }
@Override public LockResult find(byte[] key) throws IOException { if (mView.inRange(key)) { LockResult result = mSource.find(key); mOutOfBounds = false; return result; } else { mOutOfBounds = true; ViewUtils.findNoLock(mSource, key); return LockResult.UNOWNED; } }
@Override public LockResult find(byte[] key) throws IOException { if (mView.inRange(key)) { return mSource.find(key); } reset(); return LockResult.UNOWNED; }
@Override public LockResult find(final byte[] tkey) throws IOException { final byte[] key = inverseTransformKey(tkey); if (key == null) { reset(); return LockResult.UNOWNED; } mKey = tkey; mValue = NOT_LOADED; return transformCurrent(mSource.find(key), key, tkey); }
@Override public LockResult find(final byte[] tkey) throws IOException { final byte[] key = inverseTransformKey(tkey); if (key == null) { reset(); return LockResult.UNOWNED; } mKey = tkey; mValue = NOT_LOADED; return transformCurrent(mSource.find(key), key, tkey); }
@Override public LockResult find(final byte[] tkey) throws IOException { mKey = tkey; final byte[] key = inverseTransformKey(tkey); if (key == null) { mValue = null; mSource.reset(); return LockResult.UNOWNED; } mValue = NOT_LOADED; return transformCurrent(mSource.find(key), tkey); }
static void findNoLock(Cursor c, byte[] key) throws IOException { final boolean auto = c.autoload(false); final Transaction txn = c.link(Transaction.BOGUS); try { c.find(key); } finally { c.link(txn); c.autoload(auto); } }
static void findNoLock(Cursor c, byte[] key) throws IOException { final boolean auto = c.autoload(false); final Transaction txn = c.link(Transaction.BOGUS); try { c.find(key); } finally { c.link(txn); c.autoload(auto); } }
static void findNoLock(Cursor c, byte[] key) throws IOException { final boolean auto = c.autoload(false); final Transaction txn = c.link(Transaction.BOGUS); try { c.find(key); } finally { c.link(txn); c.autoload(auto); } }
@Override public byte[] load(Transaction txn, byte[] key) throws IOException { Cursor c = mSource.newCursor(txn); try { c.autoload(false); c.find(key); return valueScrub(c.value()); } finally { c.reset(); } }
@Override public byte[] exchange(Transaction txn, byte[] key, byte[] value) throws IOException { valueCheck(value); Cursor c = mSource.newCursor(txn); try { c.autoload(false); c.find(key); byte[] old = valueScrub(c.value()); c.store(value); return old; } finally { c.reset(); } }