public class GraphStep<S,E extends Element> extends AbstractStep<S,E> implements GraphComputing, AutoCloseable
Modifier and Type | Field and Description |
---|---|
protected boolean |
done |
protected Object[] |
ids |
protected boolean |
isStart |
protected Supplier<Iterator<E>> |
iteratorSupplier |
protected Class<E> |
returnClass |
id, labels, nextEnd, nextStep, previousStep, starts, traversal, traverserStepIdAndLabelsSetByChild
Constructor and Description |
---|
GraphStep(Traversal.Admin traversal,
Class<E> returnClass,
boolean isStart,
Object... ids) |
Modifier and Type | Method and Description |
---|---|
void |
addIds(Object... newIds) |
void |
clearIds() |
void |
close()
Attempts to close an underlying iterator if it is of type
CloseableIterator . |
void |
convertElementsToIds() |
Object[] |
getIds() |
Class<E> |
getReturnClass() |
int |
hashCode() |
boolean |
isStartStep() |
static boolean |
isStartStep(Step<?,?> step) |
void |
onGraphComputer()
The step will be executing on a
GraphComputer . |
static boolean |
processHasContainerIds(GraphStep<?,?> graphStep,
HasContainer hasContainer)
Helper method for providers that want to "fold in"
HasContainer 's based on id checking into the ids of the GraphStep . |
protected Traverser.Admin<E> |
processNextStart() |
void |
reset()
Reset the state of the step such that it has no incoming starts.
|
boolean |
returnsEdge() |
boolean |
returnsVertex() |
void |
setIteratorSupplier(Supplier<Iterator<E>> iteratorSupplier) |
String |
toString() |
addLabel, addStart, addStarts, clone, equals, getId, getLabels, getNextStep, getPreviousStep, getTraversal, hasNext, next, removeLabel, setId, setNextStep, setPreviousStep, setTraversal
finalize, getClass, notify, notifyAll, wait, wait, wait
atMaster, atMaster
equals, getRequirements
forEachRemaining, remove
protected Object[] ids
protected boolean isStart
protected boolean done
public GraphStep(Traversal.Admin traversal, Class<E> returnClass, boolean isStart, Object... ids)
public boolean isStartStep()
public static boolean isStartStep(Step<?,?> step)
public boolean returnsVertex()
public boolean returnsEdge()
public Object[] getIds()
public void addIds(Object... newIds)
public void clearIds()
public void onGraphComputer()
GraphComputing
GraphComputer
.onGraphComputer
in interface GraphComputing
public void convertElementsToIds()
protected Traverser.Admin<E> processNextStart()
processNextStart
in class AbstractStep<S,E extends Element>
public void reset()
Step
public int hashCode()
hashCode
in class AbstractStep<S,E extends Element>
public void close()
CloseableIterator
. Graph providers may choose
to return this interface containing their vertices and edges if there are expensive resources that might need to
be released at some point.close
in interface AutoCloseable
public static boolean processHasContainerIds(GraphStep<?,?> graphStep, HasContainer hasContainer)
HasContainer
's based on id checking into the ids of the GraphStep
.graphStep
- the GraphStep to potentially addIds(Object...)
.hasContainer
- The HasContainer
to check for id validation.HasContainer
updated ids and thus, was processed.Copyright © 2013–2019 Apache Software Foundation. All rights reserved.