public SimpleVertexQueryProcessor(InternalVertex vertex, Direction dir, TitanLabel label,
EdgeSerializer.TypedInterval[] sortKeyConstraints, int limit) {
this(vertex);
Preconditions.checkNotNull(dir);
RelationQueryCache cache = tx.getGraph().getRelationCache();
if (label==null) {
assert sortKeyConstraints==null;
sliceQuery = cache.getQuery(RelationType.EDGE);
filterDirection = dir==Direction.BOTH?null:dir;
} else {
if (AbstractVertexCentricQueryBuilder.hasSortKeyConstraints(sortKeyConstraints)) {
sliceQuery = edgeSerializer.getQuery((InternalType)label,dir,sortKeyConstraints,null);
} else {
sliceQuery = cache.getQuery((InternalType)label,dir);
}
filterDirection = null;
}
this.limit = limit;