@Override public LockResult findGe(byte[] key) throws IOException { return mSource.findLe(key); }
@Override public LockResult findGe(byte[] key) throws IOException { return mSource.findLe(key); }
/** * {@inheritDoc} */ @Override public LockResult findLe(byte[] key) throws IOException { return source.findLe(key); }
/** * {@inheritDoc} */ @Override public LockResult findLe(byte[] key) throws IOException { return source.findLe(key); }
@Override public LockResult findGe(byte[] key) throws IOException { return mSource.findLe(key); }
/** * {@inheritDoc} */ @Override public LockResult findLe(byte[] key) throws IOException { return source.findLe(key); }
@Override public LockResult findLe(byte[] key) throws IOException { mKey = null; return mSource.findLe(mView.applyPrefix(key)); }
@Override public LockResult findLe(byte[] key) throws IOException { mKey = null; return mSource.findLe(mView.applyPrefix(key)); }
@Override public LockResult findLe(byte[] key) throws IOException { mKey = null; return mSource.findLe(mView.applyPrefix(key)); }
private LockResult toLast() throws IOException { BoundedView view = mView; byte[] end = view.mEnd; Cursor source = mSource; if (end == null) { return mSource.last(); } else if ((view.mMode & END_EXCLUSIVE) == 0) { return source.findLe(end); } else { return source.findLt(end); } }
private LockResult toLast() throws IOException { BoundedView view = mView; byte[] end = view.mEnd; Cursor source = mSource; if (end == null) { return mSource.last(); } else if ((view.mMode & END_EXCLUSIVE) == 0) { return source.findLe(end); } else { return source.findLt(end); } }
private LockResult toLast() throws IOException { LockResult result; BoundedView view = mView; byte[] end = view.mEnd; Cursor source = mSource; if (end == null) { result = mSource.last(); } else if ((view.mMode & END_EXCLUSIVE) == 0) { result = source.findLe(end); } else { result = source.findLt(end); } mOutOfBounds = false; return result; }
@Override public LockResult findLe(final byte[] tkey) throws IOException { byte[] key = inverseTransformKey(tkey); if (key == null) { key = mTransformer.inverseTransformKeyLt(tkey); if (key == null) { reset(); return LockResult.UNOWNED; } } LockResult result; try { result = mSource.findLe(key); } catch (LockFailureException e) { throw transformCurrent(e); } result = transformCurrent(result); return result == null ? previous() : result; }
@Override public LockResult findLe(final byte[] tkey) throws IOException { byte[] key = inverseTransformKey(tkey); if (key == null) { key = mTransformer.inverseTransformKeyLt(tkey); if (key == null) { reset(); return LockResult.UNOWNED; } } LockResult result; try { result = mSource.findLe(key); } catch (LockFailureException e) { throw transformCurrent(e); } result = transformCurrent(result); return result == null ? previous() : result; }
@Override public LockResult findLe(byte[] key) throws IOException { BoundedView view = mView; if (view.endRangeCompare(key) > 0) { return last(); } final Cursor source = mSource; if (view.mStart == null) { return source.findLe(key); } final Transaction txn = source.link(Transaction.BOGUS); final boolean autoload = source.autoload(false); try { source.findLe(key); key = source.key(); if (key == null) { return LockResult.UNOWNED; } if (view.startRangeCompare(key) < 0) { source.reset(); return LockResult.UNOWNED; } } finally { autoload(autoload); link(txn); } // This performs any required lock acquisition. return source.load(); }
@Override public LockResult findLe(byte[] key) throws IOException { BoundedView view = mView; if (view.endRangeCompare(key) > 0) { return last(); } final Cursor source = mSource; if (view.mStart == null) { return source.findLe(key); } final Transaction txn = source.link(Transaction.BOGUS); final boolean autoload = source.autoload(false); try { source.findLe(key); key = source.key(); if (key == null) { return LockResult.UNOWNED; } if (view.startRangeCompare(key) < 0) { source.reset(); return LockResult.UNOWNED; } } finally { autoload(autoload); link(txn); } // This performs any required lock acquisition. return source.load(); }
@Override public LockResult findLe(final byte[] tkey) throws IOException { byte[] key = inverseTransformKey(tkey); if (key == null) { key = mTransformer.inverseTransformKeyLt(tkey); if (key == null) { reset(); return LockResult.UNOWNED; } } LockResult result; try { result = mSource.findLe(key); } catch (LockFailureException e) { throw transformCurrent(e); } result = transformCurrent(result); return result == null ? previous() : result; }
@Override public LockResult findLt(final byte[] tkey) throws IOException { final Cursor c = mSource; LockResult result; try { byte[] key = inverseTransformKey(tkey); if (key == null) { key = mTransformer.inverseTransformKeyLt(tkey); if (key == null) { reset(); return LockResult.UNOWNED; } result = c.findLe(key); } else { result = c.findLt(key); } } catch (LockFailureException e) { throw transformCurrent(e); } result = transformCurrent(result); return result == null ? previous() : result; }
@Override public LockResult findLt(final byte[] tkey) throws IOException { final Cursor c = mSource; LockResult result; try { byte[] key = inverseTransformKey(tkey); if (key == null) { key = mTransformer.inverseTransformKeyLt(tkey); if (key == null) { reset(); return LockResult.UNOWNED; } result = c.findLe(key); } else { result = c.findLt(key); } } catch (LockFailureException e) { throw transformCurrent(e); } result = transformCurrent(result); return result == null ? previous() : result; }
@Override public LockResult findLt(final byte[] tkey) throws IOException { final Cursor c = mSource; LockResult result; try { byte[] key = inverseTransformKey(tkey); if (key == null) { key = mTransformer.inverseTransformKeyLt(tkey); if (key == null) { reset(); return LockResult.UNOWNED; } result = c.findLe(key); } else { result = c.findLt(key); } } catch (LockFailureException e) { throw transformCurrent(e); } result = transformCurrent(result); return result == null ? previous() : result; }