Class MergeVertexStep<S>
- java.lang.Object
-
- org.apache.tinkerpop.gremlin.process.traversal.step.util.AbstractStep<S,E>
-
- org.apache.tinkerpop.gremlin.process.traversal.step.map.FlatMapStep<S,E>
-
- org.apache.tinkerpop.gremlin.process.traversal.step.map.MergeStep<S,Vertex,Map>
-
- org.apache.tinkerpop.gremlin.process.traversal.step.map.MergeVertexStep<S>
-
- All Implemented Interfaces:
Serializable
,AutoCloseable
,Cloneable
,Iterator<Traverser.Admin<Vertex>>
,Step<S,Vertex>
,Configuring
,Deleting<Event>
,Mutating<Event>
,Parameterizing
,TraversalOptionParent<Merge,S,Map>
,TraversalParent
,Writing<Event>
public class MergeVertexStep<S> extends MergeStep<S,Vertex,Map>
Implementation for themergeV()
step covering both the start step version and the one used mid-traversal.- See Also:
- Serialized Form
-
-
Field Summary
-
Fields inherited from class org.apache.tinkerpop.gremlin.process.traversal.step.map.MergeStep
callbackRegistry, first, isStart, mergeTraversal, onCreateTraversal, onMatchTraversal
-
Fields inherited from class org.apache.tinkerpop.gremlin.process.traversal.step.util.AbstractStep
id, labels, nextEnd, nextStep, previousStep, starts, traversal, traverserStepIdAndLabelsSetByChild
-
-
Constructor Summary
Constructors Constructor Description MergeVertexStep(Traversal.Admin traversal, boolean isStart)
MergeVertexStep(Traversal.Admin traversal, boolean isStart, Map merge)
MergeVertexStep(Traversal.Admin traversal, boolean isStart, Traversal.Admin<S,Map> mergeTraversal)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description MergeVertexStep<S>
clone()
Cloning is used to duplicate steps for the purpose of traversal optimization and OLTP replication.protected Iterator<Vertex>
flatMap(Traverser.Admin<S> traverser)
protected Set
getAllowedTokens()
protected Map
onCreateMap(Traverser.Admin<S> traverser, Map mergeMap)
Fuse the mergeMap with any additional key/values from the onCreateTraversal.static void
validateMapInput(Map map, boolean ignoreTokens)
-
Methods inherited from class org.apache.tinkerpop.gremlin.process.traversal.step.map.MergeStep
addChildOption, configure, getCallbackRegistry, getGraph, getLocalChildren, getMergeTraversal, getMutatingCallbackRegistry, getOnCreateTraversal, getOnMatchTraversal, getParameters, getRequirements, hashCode, isFirst, isStart, materializeMap, processNextStart, reset, searchVertices, searchVerticesLabelConstraint, searchVerticesPropertyConstraints, searchVerticesTraversal, setTraversal, toString, validate, validate, validateNoOverrides
-
Methods inherited from class org.apache.tinkerpop.gremlin.process.traversal.step.map.FlatMapStep
closeIterator
-
Methods inherited from class org.apache.tinkerpop.gremlin.process.traversal.step.util.AbstractStep
addLabel, addStart, addStarts, equals, getId, getLabels, getNextStep, getPreviousStep, getStarts, getTraversal, hasNext, hasStarts, isTraverserStepIdAndLabelsSetByChild, next, prepareTraversalForNextStep, removeLabel, setId, setNextStep, setPreviousStep
-
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface java.util.Iterator
forEachRemaining, remove
-
Methods inherited from interface org.apache.tinkerpop.gremlin.process.traversal.step.TraversalParent
addGlobalChild, addLocalChild, asStep, close, getGlobalChildren, getSelfAndChildRequirements, integrateChild, removeGlobalChild, removeLocalChild, replaceLocalChild
-
-
-
-
Constructor Detail
-
MergeVertexStep
public MergeVertexStep(Traversal.Admin traversal, boolean isStart)
-
MergeVertexStep
public MergeVertexStep(Traversal.Admin traversal, boolean isStart, Map merge)
-
MergeVertexStep
public MergeVertexStep(Traversal.Admin traversal, boolean isStart, Traversal.Admin<S,Map> mergeTraversal)
-
-
Method Detail
-
validateMapInput
public static void validateMapInput(Map map, boolean ignoreTokens)
-
clone
public MergeVertexStep<S> clone()
Description copied from interface:Step
Cloning is used to duplicate steps for the purpose of traversal optimization and OLTP replication. When cloning a step, it is important that the steps, the cloned step is equivalent to the state of the step whenStep.reset()
is called. Moreover, the previous and next steps should be set toEmptyStep
.
-
getAllowedTokens
protected Set getAllowedTokens()
- Specified by:
getAllowedTokens
in classMergeStep<S,Vertex,Map>
-
flatMap
protected Iterator<Vertex> flatMap(Traverser.Admin<S> traverser)
-
onCreateMap
protected Map onCreateMap(Traverser.Admin<S> traverser, Map mergeMap)
Fuse the mergeMap with any additional key/values from the onCreateTraversal. No overrides allowed.
-
-