class Psych::Visitors::DepthFirst - Documentation for Ruby 4.0
Description: Documentation for the Psych::Visitors::DepthFirst class
Keywords: ruby,class,Psych::Visitors::DepthFirst

🔍

No recent searches

# class Psych::Visitors::DepthFirst

### Public Class Methods

new (block)
Source

    # File ext/psych/lib/psych/visitors/depth_first.rb, line 5
    def initialize block
      @block = block
    end

### Private Instance Methods

nary (o)
Source

    # File ext/psych/lib/psych/visitors/depth_first.rb, line 11
    def nary o
      o.children.each { |x| visit x }
      @block.call o
    end

Also aliased as: visit_Psych_Nodes_Stream, visit_Psych_Nodes_Document, visit_Psych_Nodes_Sequence, visit_Psych_Nodes_Mapping
terminal (o)
Source

    # File ext/psych/lib/psych/visitors/depth_first.rb, line 20
    def terminal o
      @block.call o
    end

Also aliased as: visit_Psych_Nodes_Scalar, visit_Psych_Nodes_Alias
visit_Psych_Nodes_Alias (o)
Alias for: terminal
visit_Psych_Nodes_Document (o)
Alias for: nary
visit_Psych_Nodes_Mapping (o)
Alias for: nary
visit_Psych_Nodes_Scalar (o)
Alias for: terminal
visit_Psych_Nodes_Sequence (o)
Alias for: nary
visit_Psych_Nodes_Stream (o)
Alias for: nary