Class: RbYAML::StreamStartToken

Inherits:
Token show all
Defined in:
lib/rbyaml/tokens.rb

Instance Attribute Summary collapse

Attributes inherited from Token

#end_mark, #start_mark

Instance Method Summary collapse

Methods inherited from Token

#__is_alias, #__is_anchor, #__is_block_end, #__is_block_entry, #__is_block_mapping_start, #__is_block_sequence_start, #__is_directive, #__is_document_end, #__is_document_start, #__is_flow_entry, #__is_flow_mapping_end, #__is_flow_mapping_start, #__is_flow_sequence_end, #__is_flow_sequence_start, #__is_key, #__is_scalar, #__is_stream_end, #__is_tag, #__is_value, #hash

Constructor Details

#initialize(start_mark = nil, end_mark = nil, encoding = nil) ⇒ StreamStartToken

Returns a new instance of StreamStartToken.



64
65
66
67
# File 'lib/rbyaml/tokens.rb', line 64

def initialize(start_mark=nil, end_mark=nil, encoding=nil)
  super(start_mark,end_mark)
  @encoding = encoding
end

Instance Attribute Details

#encodingObject (readonly)

Returns the value of attribute encoding.



63
64
65
# File 'lib/rbyaml/tokens.rb', line 63

def encoding
  @encoding
end

Instance Method Details

#__is_stream_startObject



59
# File 'lib/rbyaml/tokens.rb', line 59

def __is_stream_start; true; end

#tidObject



60
61
62
# File 'lib/rbyaml/tokens.rb', line 60

def tid
  "<stream start>"
end