E- The generic type of the [E]lements of the relation.
public interface IMutableRelation<E> extends IRelation<E>, IMutableResource<IRelation<E>>
IRelation. The relation must maintain any secondary indices under mutation.
The methods declared by this interface return a "mutation count" - the mutation count MUST be exact and MUST NOT count overwrites that do not change the state of the tuple (the same key and value). The mutation counts are used to determine the fixed point for closure of a rule set. If they do not follow this contract then the closure operation will not terminate!
If fact, it is MUCH more efficient if an implementation avoids the overwrite
of an element with identical data. All index writes (including overwrites)
add data to the
AbstractJournal backing the mutable
absorbing writes for an index. An "overwrite" thus incurs more IO and will
trigger overflow for the journal earlier than if overwrite were avoided. In
contrast, while you have a lock on the mutable index you can test for a
pre-existing key and compare the serialized byte values with relatively
little cost (zero additional IO).
|Modifier and Type||Method and Description|
Remove elements from the relation.
Write elements on the relation.
getAccessPath, getAccessPath, getAccessPath, getElementClass, getExecutorService, getFQN, getIndex, getIndexManager, getIndexNames, getKeyOrder, getKeyOrders, getPrimaryKeyOrder, newElement
long insert(IChunkedOrderedIterator<E> itr)
itr- An iterator visiting the elements to be written.
long delete(IChunkedOrderedIterator<E> itr)
itr- An iterator visiting the elements to be removed. Existing elements in the relation having a key equal to the key formed from the visited elements will be removed from the relation.
Copyright © 2006–2016 SYSTAP, LLC DBA Blazegraph. All rights reserved.