本文整理汇总了Java中org.apache.tinkerpop.gremlin.process.traversal.step.map.GraphStep.getReturnClass方法的典型用法代码示例。如果您正苦于以下问题:Java GraphStep.getReturnClass方法的具体用法?Java GraphStep.getReturnClass怎么用?Java GraphStep.getReturnClass使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类org.apache.tinkerpop.gremlin.process.traversal.step.map.GraphStep
的用法示例。
在下文中一共展示了GraphStep.getReturnClass方法的9个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: TinkerGraphStep
import org.apache.tinkerpop.gremlin.process.traversal.step.map.GraphStep; //导入方法依赖的package包/类
public TinkerGraphStep(final GraphStep<S, E> originalGraphStep) {
super(originalGraphStep.getTraversal(), originalGraphStep.getReturnClass(), originalGraphStep.isStartStep(), originalGraphStep.getIds());
originalGraphStep.getLabels().forEach(this::addLabel);
// we used to only setIteratorSupplier() if there were no ids OR the first id was instanceof Element,
// but that allowed the filter in g.V(v).has('k','v') to be ignored. this created problems for
// PartitionStrategy which wants to prevent someone from passing "v" from one TraversalSource to
// another TraversalSource using a different partition
this.setIteratorSupplier(() -> (Iterator<E>) (Vertex.class.isAssignableFrom(this.returnClass) ? this.vertices() : this.edges()));
}
示例2: LiteGraphStep
import org.apache.tinkerpop.gremlin.process.traversal.step.map.GraphStep; //导入方法依赖的package包/类
public LiteGraphStep(final GraphStep<S, E> originalGraphStep) {
super(originalGraphStep.getTraversal(), originalGraphStep.getReturnClass(), originalGraphStep.isStartStep(), originalGraphStep.getIds());
originalGraphStep.getLabels().forEach(this::addLabel);
// we used to only setIteratorSupplier() if there were no ids OR the first id was instanceof Element,
// but that allowed the filter in g.V(v).has('k','v') to be ignored. this created problems for
// PartitionStrategy which wants to prevent someone from passing "v" from one TraversalSource to
// another TraversalSource using a different partition
this.setIteratorSupplier(() -> (Iterator<E>) (Vertex.class.isAssignableFrom(this.returnClass) ? this.vertices() : this.edges()));
}
示例3: TitanGraphStep
import org.apache.tinkerpop.gremlin.process.traversal.step.map.GraphStep; //导入方法依赖的package包/类
public TitanGraphStep(final GraphStep<S, E> originalStep) {
super(originalStep.getTraversal(), originalStep.getReturnClass(), originalStep.isStartStep(), originalStep.getIds());
originalStep.getLabels().forEach(this::addLabel);
this.setIteratorSupplier(() -> {
TitanTransaction tx = TitanTraversalUtil.getTx(traversal);
TitanGraphQuery query = tx.query();
for (HasContainer condition : hasContainers) {
query.has(condition.getKey(), TitanPredicate.Converter.convert(condition.getBiPredicate()), condition.getValue());
}
for (OrderEntry order : orders) query.orderBy(order.key, order.order);
if (limit != BaseQuery.NO_LIMIT) query.limit(limit);
((GraphCentricQueryBuilder) query).profiler(queryProfiler);
return Vertex.class.isAssignableFrom(this.returnClass) ? query.vertices().iterator() : query.edges().iterator();
});
}
示例4: UniGraphStartStep
import org.apache.tinkerpop.gremlin.process.traversal.step.map.GraphStep; //导入方法依赖的package包/类
public UniGraphStartStep(GraphStep<S, E> originalStep, ControllerManager controllerManager) {
super(originalStep.getTraversal(), originalStep.getReturnClass(), originalStep.isStartStep(), originalStep.getIds());
originalStep.getLabels().forEach(this::addLabel);
this.predicates = UniGraph.createIdPredicate(originalStep.getIds(), originalStep.getReturnClass());
this.stepDescriptor = new StepDescriptor(this);
this.controllers = controllerManager.getControllers(SearchQuery.SearchController.class);
this.setIteratorSupplier(this::query);
limit = -1;
this.propertyKeys = new HashSet<>();
}
示例5: BitsyGraphStep
import org.apache.tinkerpop.gremlin.process.traversal.step.map.GraphStep; //导入方法依赖的package包/类
public BitsyGraphStep(final GraphStep<S, E> originalGraphStep) {
super(originalGraphStep.getTraversal(), originalGraphStep.getReturnClass(), originalGraphStep.isStartStep(), originalGraphStep.getIds());
originalGraphStep.getLabels().forEach(this::addLabel);
this.setIteratorSupplier(() -> (Iterator<E>) (Vertex.class.isAssignableFrom(this.returnClass) ? this.vertices() : this.edges()));
}
示例6: HBaseGraphStep
import org.apache.tinkerpop.gremlin.process.traversal.step.map.GraphStep; //导入方法依赖的package包/类
@SuppressWarnings("unchecked")
public HBaseGraphStep(final GraphStep<S, E> originalGraphStep) {
super(originalGraphStep.getTraversal(), originalGraphStep.getReturnClass(), originalGraphStep.isStartStep(), originalGraphStep.getIds());
originalGraphStep.getLabels().forEach(this::addLabel);
this.setIteratorSupplier(() -> (Iterator<E>) (Vertex.class.isAssignableFrom(this.returnClass) ? this.vertices() : this.edges()));
}
示例7: Neo4jGraphStep
import org.apache.tinkerpop.gremlin.process.traversal.step.map.GraphStep; //导入方法依赖的package包/类
public Neo4jGraphStep(final GraphStep<S, E> originalGraphStep) {
super(originalGraphStep.getTraversal(), originalGraphStep.getReturnClass(), originalGraphStep.isStartStep(), originalGraphStep.getIds());
originalGraphStep.getLabels().forEach(this::addLabel);
this.setIteratorSupplier(() -> (Iterator<E>) (Vertex.class.isAssignableFrom(this.returnClass) ? this.vertices() : this.edges()));
}
示例8: OrientGraphStep
import org.apache.tinkerpop.gremlin.process.traversal.step.map.GraphStep; //导入方法依赖的package包/类
public OrientGraphStep(final GraphStep<S, E> originalGraphStep) {
super(originalGraphStep.getTraversal(), originalGraphStep.getReturnClass(), originalGraphStep.isStartStep(), originalGraphStep.getIds());
originalGraphStep.getLabels().forEach(this::addLabel);
this.setIteratorSupplier(() -> (Iterator<E>) (isVertexStep() ? this.vertices() : this.edges()));
}
示例9: constructSqlgStep
import org.apache.tinkerpop.gremlin.process.traversal.step.map.GraphStep; //导入方法依赖的package包/类
@Override
protected SqlgStep constructSqlgStep(Step startStep) {
Preconditions.checkArgument(startStep instanceof GraphStep, "Expected a GraphStep, found instead a " + startStep.getClass().getName());
GraphStep<?, ?> graphStep = (GraphStep) startStep;
return new SqlgGraphStep(this.sqlgGraph, this.traversal, graphStep.getReturnClass(), graphStep.isStartStep(), graphStep.getIds());
}