Author: kayyagari
Date: Mon Apr 8 19:02:46 2013
New Revision: 1465724
URL: http://svn.apache.org/r1465724
Log:
create duplicate holder for non-page values
Modified:
labs/mavibot/branches/mavibot-multivalue-support/mavibot/src/main/java/org/apache/mavibot/btree/BTree.java
Modified:
labs/mavibot/branches/mavibot-multivalue-support/mavibot/src/main/java/org/apache/mavibot/btree/BTree.java
URL:
http://svn.apache.org/viewvc/labs/mavibot/branches/mavibot-multivalue-support/mavibot/src/main/java/org/apache/mavibot/btree/BTree.java?rev=1465724&r1=1465723&r2=1465724&view=diff
==============================================================================
---
labs/mavibot/branches/mavibot-multivalue-support/mavibot/src/main/java/org/apache/mavibot/btree/BTree.java
(original)
+++
labs/mavibot/branches/mavibot-multivalue-support/mavibot/src/main/java/org/apache/mavibot/btree/BTree.java
Mon Apr 8 19:02:46 2013
@@ -1743,16 +1743,19 @@ public class BTree<K, V>
return new ReferenceHolder<Page<K, V>, K, V>( this, ( Page<K,
V> ) value,
( ( AbstractPage<K, V> ) value ).getOffset() );
}
+ else if ( isAllowDuplicates() )
+ {
+ return new DuplicateKeyMemoryHolder<K, V>( this, ( V ) value );
+ }
else
{
// Atm, keep the values in memory
return new MemoryHolder<K, V>( this, ( V ) value );
-
}
}
else
{
- if ( isAllowDuplicates() )
+ if ( isAllowDuplicates() && !( value instanceof Page ) )
{
return new DuplicateKeyMemoryHolder<K, V>( this, ( V ) value );
}
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]