@Override @SuppressWarnings("unchecked") public V get(Object key) { return (V) get(root, key); }
Page p = root.copy(v); Object result; if (alwaysAdd || get(key) == null) { if (p.getMemory() > store.getPageSplitSize() && p.getKeyCount() > 3) {
Page p = root.copy(v); Object result; if (alwaysAdd || get(key) == null) { if (p.getMemory() > store.getPageSplitSize() && p.getKeyCount() > 3) {
/** * Get the object for the given key. An exact match is required. * * @param p the page * @param key the key * @return the value, or null if not found */ protected Object get(Page p, Object key) { if (!p.isLeaf()) { for (int i = 0; i < p.getKeyCount(); i++) { if (contains(p, i, key)) { Object o = get(p.getChildPage(i), key); if (o != null) { return o; } } } } else { for (int i = 0; i < p.getKeyCount(); i++) { if (keyType.equals(p.getKey(i), key)) { return p.getValue(i); } } } return null; }
Page p = root.copy(v); Object result; if (alwaysAdd || get(key) == null) { if (p.getMemory() > store.getPageSplitSize() && p.getKeyCount() > 3) {
if (contains(p, i, key)) { Page c = p.getChildPage(i); if (get(c, key) != null) { c = c.copy(writeVersion); Object result = set(c, writeVersion, key, value);
Page p = root.copy(v); Object result; if (alwaysAdd || get(key) == null) { if (p.getMemory() > store.getPageSplitSize() && p.getKeyCount() > 3) {
@Override @SuppressWarnings("unchecked") public V get(Object key) { return (V) get(root, key); }
@Override @SuppressWarnings("unchecked") public V get(Object key) { return (V) get(root, key); }
@Override @SuppressWarnings("unchecked") public V get(Object key) { return (V) get(root, key); }
/** * Get the object for the given key. An exact match is required. * * @param p the page * @param key the key * @return the value, or null if not found */ protected Object get(Page p, Object key) { if (!p.isLeaf()) { for (int i = 0; i < p.getKeyCount(); i++) { if (contains(p, i, key)) { Object o = get(p.getChildPage(i), key); if (o != null) { return o; } } } } else { for (int i = 0; i < p.getKeyCount(); i++) { if (keyType.equals(p.getKey(i), key)) { return p.getValue(i); } } } return null; }
/** * Get the object for the given key. An exact match is required. * * @param p the page * @param key the key * @return the value, or null if not found */ protected Object get(Page p, Object key) { if (!p.isLeaf()) { for (int i = 0; i < p.getKeyCount(); i++) { if (contains(p, i, key)) { Object o = get(p.getChildPage(i), key); if (o != null) { return o; } } } } else { for (int i = 0; i < p.getKeyCount(); i++) { if (keyType.equals(p.getKey(i), key)) { return p.getValue(i); } } } return null; }
/** * Get the object for the given key. An exact match is required. * * @param p the page * @param key the key * @return the value, or null if not found */ protected Object get(Page p, Object key) { if (!p.isLeaf()) { for (int i = 0; i < p.getKeyCount(); i++) { if (contains(p, i, key)) { Object o = get(p.getChildPage(i), key); if (o != null) { return o; } } } } else { for (int i = 0; i < p.getKeyCount(); i++) { if (keyType.equals(p.getKey(i), key)) { return p.getValue(i); } } } return null; }
if (contains(p, i, key)) { Page c = p.getChildPage(i); if (get(c, key) != null) { c = c.copy(writeVersion); Object result = set(c, writeVersion, key, value);
if (contains(p, i, key)) { Page c = p.getChildPage(i); if (get(c, key) != null) { c = c.copy(writeVersion); Object result = set(c, writeVersion, key, value);
if (contains(p, i, key)) { Page c = p.getChildPage(i); if (get(c, key) != null) { c = c.copy(writeVersion); Object result = set(c, writeVersion, key, value);