Represents a YAML stream. This is the root node for any YAML parse tree. This node must have one or more child nodes. The only valid child node for a Psych::Nodes::Stream node is Psych::Nodes::Document.

Methods
N
Constants
ANY = Psych::Parser::ANY
 

Any encoding

UTF8 = Psych::Parser::UTF8
 

UTF-8 encoding

UTF16LE = Psych::Parser::UTF16LE
 

UTF-16LE encoding

UTF16BE = Psych::Parser::UTF16BE
 

UTF-16BE encoding

Attributes
[RW] encoding

The encoding used for this stream

Class Public methods
new(encoding = UTF8)

Create a new Psych::Nodes::Stream node with an encoding that defaults to Psych::Nodes::Stream::UTF8.

See also Psych::Handler#start_stream

# File ext/psych/lib/psych/nodes/stream.rb, line 32
def initialize encoding = UTF8
  super()
  @encoding = encoding
end