public class GraphCentricQuery extends BaseQuery implements ElementQuery<JanusGraphElement,JointIndexQuery>
ElementQuery
for JanusGraphQuery
. This query contains
the condition, and only one sub-query JointIndexQuery
.
It also maintains the ordering for the query result which is needed by the QueryProcessor
to correctly order the result.Constructor and Description |
---|
GraphCentricQuery(ElementCategory resultType,
Condition<JanusGraphElement> condition,
OrderList orders,
BackendQueryHolder<JointIndexQuery> indexQuery,
int limit) |
Modifier and Type | Method and Description |
---|---|
static GraphCentricQuery |
emptyQuery(ElementCategory resultType) |
boolean |
equals(Object other) |
Condition<JanusGraphElement> |
getCondition() |
BackendQueryHolder<JointIndexQuery> |
getIndexQuery() |
OrderList |
getOrder() |
QueryProfiler |
getProfiler() |
ElementCategory |
getResultType() |
Comparator<JanusGraphElement> |
getSortOrder()
Returns the expected sort order of this query if any was specified.
|
BackendQueryHolder<JointIndexQuery> |
getSubQuery(int position)
Returns the backend query at the given position that comprises this ElementQuery
|
boolean |
hasDuplicateResults()
Whether the combination of the individual sub-queries can result in duplicate
results.
|
int |
hashCode() |
boolean |
isEmpty()
Whether the result set of this query is empty
|
boolean |
isSorted()
Whether this query expects the results to be in a particular sort order.
|
boolean |
matches(JanusGraphElement element)
Whether the given element matches the conditions of this query.
|
int |
numSubQueries()
Returns the number of sub-queries this query is comprised of.
|
void |
observeWith(QueryProfiler profiler,
boolean hasSiblings) |
String |
toString() |
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
observeWith
public GraphCentricQuery(ElementCategory resultType, Condition<JanusGraphElement> condition, OrderList orders, BackendQueryHolder<JointIndexQuery> indexQuery, int limit)
public static GraphCentricQuery emptyQuery(ElementCategory resultType)
public Condition<JanusGraphElement> getCondition()
public ElementCategory getResultType()
public OrderList getOrder()
public boolean isEmpty()
ElementQuery
isEmpty
in interface ElementQuery<JanusGraphElement,JointIndexQuery>
public int numSubQueries()
ElementQuery
numSubQueries
in interface ElementQuery<JanusGraphElement,JointIndexQuery>
public BackendQueryHolder<JointIndexQuery> getIndexQuery()
public BackendQueryHolder<JointIndexQuery> getSubQuery(int position)
ElementQuery
getSubQuery
in interface ElementQuery<JanusGraphElement,JointIndexQuery>
public boolean isSorted()
ElementQuery
isSorted
in interface ElementQuery<JanusGraphElement,JointIndexQuery>
public Comparator<JanusGraphElement> getSortOrder()
ElementQuery
ElementQuery.isSorted()
first.getSortOrder
in interface ElementQuery<JanusGraphElement,JointIndexQuery>
public boolean hasDuplicateResults()
ElementQuery
hasDuplicateResults
in interface ElementQuery<JanusGraphElement,JointIndexQuery>
public boolean matches(JanusGraphElement element)
ElementQuery
Used for result filtering if the result set returned by the query executor is not fitted.
matches
in interface ElementQuery<JanusGraphElement,JointIndexQuery>
public void observeWith(QueryProfiler profiler, boolean hasSiblings)
observeWith
in interface ProfileObservable
public QueryProfiler getProfiler()
getProfiler
in interface ProfileObservable
Copyright © 2012–2024. All rights reserved.