// TraversalReason provides additional information to traversals using AdvVisitFn.
typeTraversalReasonbyte// enum = SelectionMatch | SelectionParent | SelectionCandidate // probably only pointful for block edges?
typeTraversalReasonbyte
const(
TraversalReason_SelectionMatchTraversalReason='m'// Tells AdvVisitFn that this node was explicitly selected. (This is the set of nodes that VisitFn is called for.)
TraversalReason_SelectionParentTraversalReason='p'// Tells AdvVisitFn that this node is a parent of one that will be explicitly selected. (These calls only happen if the feature is enabled -- enabling parent detection requires a different algorithm and adds some overhead.)
TraversalReason_SelectionCandidateTraversalReason='x'// Tells AdvVisitFn that this node was visited while searching for selection matches. It is not necessarily implied that any explicit match will be a child of this node; only that we had to consider it. (Merkle-proofs generally need to include any node in this group.)
Interests()[]PathSegment// returns the segments we're likely interested in **or nil** if we're a high-cardinality or expression based matcher and need all segments proposed to us.
Explore(ipld.Node,PathSegment)Selector// explore one step -- iteration comes from outside (either whole node, or by following suggestions of Interests). returns nil if no interest. you have to traverse to the next node yourself (the selector doesn't do it for you because you might be considering multiple selection reasons at the same time).