public class LP_NL_O_OB_P_S_SE_SL_Traverser<T> extends LP_O_OB_P_S_SE_SL_Traverser<T>
Traverser.Admin<T>
Attachable.Exceptions, Attachable.Method
Modifier and Type | Field and Description |
---|---|
protected org.apache.commons.collections.map.ReferenceMap |
loopNames |
protected Stack<LabelledCounter> |
nestedLoops |
path
bulk, future, loopName, loops, sack, sideEffects
tags
t
HALT
Modifier | Constructor and Description |
---|---|
protected |
LP_NL_O_OB_P_S_SE_SL_Traverser() |
|
LP_NL_O_OB_P_S_SE_SL_Traverser(T t,
Step<T,?> step) |
Modifier and Type | Method and Description |
---|---|
boolean |
equals(Object o) |
Set<String> |
getLoopNames()
If this traverser supports loops then return the loop names if any.
|
int |
hashCode() |
void |
incrLoops()
Increment the number of times the traverser has gone through a looping section of traversal.
|
void |
initialiseLoops(String stepLabel,
String loopName)
Initialise a loop by setting up the looping construct.
|
int |
loops()
Return the number of times the traverser has gone through a looping section of a traversal.
|
int |
loops(String loopName)
Return the number of times the traverser has gone through the named looping section of a traversal.
|
void |
merge(Traverser.Admin<?> other)
When two traversers are have equality with each other, then they can be merged.
|
void |
resetLoops()
Set the number of times the traverser has gone through a loop back to 0.
|
Traverser.Admin<T> |
split()
Generate a sibling traverser of the current traverser with a full copy of all state within the sibling.
|
<R> Traverser.Admin<R> |
split(R r,
Step<T,R> step)
Generate a child traverser of the current traverser for current as step and new object location.
|
addLabels, detach, dropLabels, dropPath, equals, keepLabels, path
bulk, equals, getSideEffects, getStepId, sack, sack, setBulk, setSideEffects, setStepId
equals, getTags
attach, clone, get, set, toString
finalize, getClass, notify, notifyAll, wait, wait, wait
isHalted
asAdmin, compareTo, path, path, sideEffects, sideEffects
protected Stack<LabelledCounter> nestedLoops
protected org.apache.commons.collections.map.ReferenceMap loopNames
public int loops()
Traverser
public int loops(String loopName)
Traverser
public void initialiseLoops(String stepLabel, String loopName)
Traverser.Admin
LoopsStep
initialiseLoops
in interface Traverser.Admin<T>
initialiseLoops
in class O_OB_S_SE_SL_Traverser<T>
stepLabel
- the label of the step that is being set-up.loopName
- the user defined name for referencing the loop counter or null if not setpublic void incrLoops()
Traverser.Admin
incrLoops
in interface Traverser.Admin<T>
incrLoops
in class O_OB_S_SE_SL_Traverser<T>
public void resetLoops()
Traverser.Admin
resetLoops
in interface Traverser.Admin<T>
resetLoops
in class O_OB_S_SE_SL_Traverser<T>
public <R> Traverser.Admin<R> split(R r, Step<T,R> step)
Traverser.Admin
split
in interface Traverser.Admin<T>
split
in class LP_O_OB_P_S_SE_SL_Traverser<T>
R
- The current object type of the childr
- The current object of the childstep
- The step yielding the splitpublic Traverser.Admin<T> split()
Traverser.Admin
split
in interface Traverser.Admin<T>
split
in class LP_O_OB_P_S_SE_SL_Traverser<T>
public void merge(Traverser.Admin<?> other)
Traverser.Admin
merge
in interface Traverser.Admin<T>
merge
in class O_OB_S_SE_SL_Traverser<T>
other
- the other traverser to merge into this traverser. Once merged, the other can be garbage collected.public Set<String> getLoopNames()
Traverser.Admin
getLoopNames
in interface Traverser.Admin<T>
getLoopNames
in class O_OB_S_SE_SL_Traverser<T>
public boolean equals(Object o)
equals
in class LP_O_OB_P_S_SE_SL_Traverser<T>
public int hashCode()
hashCode
in class LP_O_OB_P_S_SE_SL_Traverser<T>
Copyright © 2013–2022 Apache Software Foundation. All rights reserved.