class Trivet::TraverseControl

Objects of this class control the Trivet::Node#traverse method. You generally will not need to instantiate this object yourself. See Trivet::Node#traverse for details.

Attributes

pruned[RW]

Returns true if the traversal is being pruned.

stopped[R]

Returns true if the traversal has been stopped.

Public Class Methods

new() click to toggle source
# File lib/trivet.rb, line 1605
def initialize
        @pruned = false
        @stopped = false
end

Public Instance Methods

prune() click to toggle source

Prunes the traversal so that the process does not recurse into children.

# File lib/trivet.rb, line 1634
def prune
        @pruned = true
end
stop() click to toggle source

Stops the traversal completely.

# File lib/trivet.rb, line 1639
def stop
        @stopped = true
end