|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface IRelation<E>
An abstraction corresponding to a set of elements using some schema (think a
table containing a set of rows). Each relation is backed by one or more
indices and knows how to return the IAccessPath that is most
efficient given an IPredicate expressing a query against the
IRelation.
| Method Summary | |
|---|---|
IAccessPath<E> |
getAccessPath(IPredicate<E> predicate)
Return the best IAccessPath for a relation given a predicate with
zero or more unbound variables. |
Class<E> |
getElementClass()
Return the class for the generic type of this relation. |
ExecutorService |
getExecutorService()
The service used to run asynchronous or parallel tasks for the IRelation. |
IIndexManager |
getIndexManager()
The IIndexManager for the IRelation. |
Set<String> |
getIndexNames()
Return the fully qualified name of each index maintained by this relation. |
E |
newElement(IPredicate<E> predicate,
IBindingSet bindingSet)
Create and return a new element. |
| Methods inherited from interface com.bigdata.relation.locator.ILocatableResource |
|---|
getContainerNamespace, getNamespace, getTimestamp |
| Method Detail |
|---|
IIndexManager getIndexManager()
IIndexManager for the IRelation.
ExecutorService getExecutorService()
IRelation.
IAccessPath<E> getAccessPath(IPredicate<E> predicate)
IAccessPath for a relation given a predicate with
zero or more unbound variables.
If there is an IIndex that directly corresponeds to the natural
order implied by the variable pattern on the predicate then the access
path should use that index. Otherwise you should choose the best index
given the constraints and make sure that the IAccessPath
incorporates additional filters that will allow you to filter out the
irrelevant ITuples during the scan - this is very important when
the index is remote!
If there are any IElementFilters then the access path MUST
incorporate those constraints such that only elements that satisify the
constraints may be visited.
Whether the constraints arise because of the lack of a perfect index for
the access path or because they were explicitly specified for the
IPredicate, those constraints should be translated into
constraints imposed on the underlying ITupleIterator and sent
with it to be evaluated local to the data.
Note: Filters should be specified when the IAccessPath is
constructed so that they will be evalated on the data service rather than
materializing the elements and then filtering then. This can be
accomplished by adding the filter as a constraint on the predicate when
specifying the access path.
predicate - The constraint on the elements to be visited.
IAccessPath for that IPredicate.Set<String> getIndexNames()
E newElement(IPredicate<E> predicate,
IBindingSet bindingSet)
ISolution for an IRule during either a query or mutation
operations. The element is NOT inserted into the relation.
predicate - The predicate that is the head of some IRule.bindingSet - A set of bindings for that IRule.
IllegalArgumentException - if any parameter is null.
IllegalStateException - if the predicate is not fully bound given those bindings.Class<E> getElementClass()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||