public class GraphCentricQueryBuilder extends Object implements TitanGraphQuery<GraphCentricQueryBuilder>
TitanGraphQuery, optimizes the query and compiles the result into a GraphCentricQuery which
is then executed through a QueryProcessor.| Constructor and Description |
|---|
GraphCentricQueryBuilder(StandardTitanTx tx,
IndexSerializer serializer) |
| Modifier and Type | Method and Description |
|---|---|
GraphCentricQuery |
constructQuery(ElementCategory resultType) |
GraphCentricQuery |
constructQueryWithoutProfile(ElementCategory resultType) |
Iterable<TitanEdge> |
edges()
Returns all edges that match the conditions.
|
GraphCentricQueryBuilder |
has(PropertyKey key,
TitanPredicate predicate,
Object condition) |
GraphCentricQueryBuilder |
has(String key) |
GraphCentricQueryBuilder |
has(String key,
Object value) |
GraphCentricQueryBuilder |
has(String key,
TitanPredicate predicate,
Object condition)
The returned element must have a property for the given key that matches the condition according to the
specified relation
|
GraphCentricQueryBuilder |
hasNot(String key) |
GraphCentricQueryBuilder |
hasNot(String key,
Object value) |
static List<Object[]> |
indexCover(CompositeIndexType index,
Condition<TitanElement> condition,
Set<Condition> covered) |
static Condition<TitanElement> |
indexCover(MixedIndexType index,
Condition<TitanElement> condition,
IndexSerializer indexInfo,
Set<Condition> covered) |
static boolean |
indexCoversOrder(MixedIndexType index,
OrderList orders) |
<T extends Comparable<?>> |
interval(String s,
T t1,
T t2) |
GraphCentricQueryBuilder |
limit(int limit)
Limits the size of the returned result set
|
GraphCentricQueryBuilder |
orderBy(String keyName,
org.apache.tinkerpop.gremlin.process.traversal.Order order)
Orders the element results of this query according
to their property for the given key in the given order (increasing/decreasing).
|
GraphCentricQueryBuilder |
profiler(QueryProfiler profiler) |
Iterable<TitanVertexProperty> |
properties()
Returns all properties that match the conditions
|
Iterable<TitanVertex> |
vertices()
Returns all vertices that match the conditions.
|
public GraphCentricQueryBuilder(StandardTitanTx tx, IndexSerializer serializer)
public GraphCentricQueryBuilder profiler(QueryProfiler profiler)
public GraphCentricQueryBuilder has(String key, TitanPredicate predicate, Object condition)
TitanGraphQueryhas in interface TitanGraphQuery<GraphCentricQueryBuilder>key - Key that identifies the propertypredicate - Relation between property and conditionpublic GraphCentricQueryBuilder has(PropertyKey key, TitanPredicate predicate, Object condition)
public GraphCentricQueryBuilder has(String key)
has in interface TitanGraphQuery<GraphCentricQueryBuilder>public GraphCentricQueryBuilder hasNot(String key)
hasNot in interface TitanGraphQuery<GraphCentricQueryBuilder>public GraphCentricQueryBuilder has(String key, Object value)
has in interface TitanGraphQuery<GraphCentricQueryBuilder>public GraphCentricQueryBuilder hasNot(String key, Object value)
hasNot in interface TitanGraphQuery<GraphCentricQueryBuilder>public <T extends Comparable<?>> GraphCentricQueryBuilder interval(String s, T t1, T t2)
interval in interface TitanGraphQuery<GraphCentricQueryBuilder>public GraphCentricQueryBuilder limit(int limit)
TitanGraphQuerylimit in interface TitanGraphQuery<GraphCentricQueryBuilder>limit - The maximum number of results to returnpublic GraphCentricQueryBuilder orderBy(String keyName, org.apache.tinkerpop.gremlin.process.traversal.Order order)
TitanGraphQueryorderBy in interface TitanGraphQuery<GraphCentricQueryBuilder>keyName - The key of the properties on which to orderorder - the ordering directionpublic Iterable<TitanVertex> vertices()
TitanGraphQueryvertices in interface TitanGraphQuery<GraphCentricQueryBuilder>public Iterable<TitanEdge> edges()
TitanGraphQueryedges in interface TitanGraphQuery<GraphCentricQueryBuilder>public Iterable<TitanVertexProperty> properties()
TitanGraphQueryproperties in interface TitanGraphQuery<GraphCentricQueryBuilder>public GraphCentricQuery constructQuery(ElementCategory resultType)
public GraphCentricQuery constructQueryWithoutProfile(ElementCategory resultType)
public static final boolean indexCoversOrder(MixedIndexType index, OrderList orders)
public static List<Object[]> indexCover(CompositeIndexType index, Condition<TitanElement> condition, Set<Condition> covered)
public static final Condition<TitanElement> indexCover(MixedIndexType index, Condition<TitanElement> condition, IndexSerializer indexInfo, Set<Condition> covered)
Copyright © 2012–2015. All rights reserved.