class BELParser::Parsers::BELScript::DefineNamespace::Parser
Attributes
_bel_eof_actions[RW]
_bel_index_offsets[RW]
_bel_indicies[RW]
_bel_key_spans[RW]
_bel_trans_actions[RW]
_bel_trans_keys[RW]
_bel_trans_targs[RW]
bel_en_define_namespace_node[RW]
bel_en_ident_node[RW]
bel_en_string_node[RW]
bel_error[RW]
bel_first_final[RW]
bel_start[RW]
Public Class Methods
new(content)
click to toggle source
# File lib/bel_parser/parsers/bel_script/define_namespace.rb, line 1546 def initialize(content) @content = content # begin: ragel class << self attr_accessor :_bel_trans_keys private :_bel_trans_keys, :_bel_trans_keys= end self._bel_trans_keys = [ 0, 0, 68, 100, 69, 101, 70, 102, 73, 105, 78, 110, 69, 101, 9, 32, 9, 110, 65, 97, 77, 109, 69, 101, 83, 115, 80, 112, 65, 97, 67, 99, 69, 101, 9, 32, 9, 122, 9, 122, 9, 97, 83, 115, 9, 32, 9, 117, 82, 114, 73, 108, 9, 32, 9, 34, 34, 92, 34, 92, 10, 10, 0, 0, 9, 32, 48, 122, 9, 34, 34, 92, 34, 92, 0, 0, 0, 0, 10, 122, 0, 0, 0, 0, 0 ] class << self attr_accessor :_bel_key_spans private :_bel_key_spans, :_bel_key_spans= end self._bel_key_spans = [ 0, 33, 33, 33, 33, 33, 33, 24, 102, 33, 33, 33, 33, 33, 33, 33, 33, 24, 114, 114, 89, 33, 24, 109, 33, 36, 24, 26, 59, 59, 1, 0, 24, 75, 26, 59, 59, 0, 0, 113, 0, 0 ] class << self attr_accessor :_bel_index_offsets private :_bel_index_offsets, :_bel_index_offsets= end self._bel_index_offsets = [ 0, 0, 34, 68, 102, 136, 170, 204, 229, 332, 366, 400, 434, 468, 502, 536, 570, 604, 629, 744, 859, 949, 983, 1008, 1118, 1152, 1189, 1214, 1241, 1301, 1361, 1363, 1364, 1389, 1465, 1492, 1552, 1612, 1613, 1614, 1728, 1729 ] class << self attr_accessor :_bel_indicies private :_bel_indicies, :_bel_indicies= end self._bel_indicies = [ 0, 1, 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 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 18, 18, 18, 18, 19, 18, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 19, 18, 20, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 20, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 18, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 18, 18, 18, 18, 18, 18, 18, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 18, 18, 18, 18, 21, 18, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 21, 18, 22, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 22, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 23, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 23, 1, 24, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 24, 1, 25, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 25, 1, 25, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 25, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 26, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 26, 1, 27, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 27, 1, 28, 1, 1, 29, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 28, 1, 1, 29, 1, 30, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 30, 1, 32, 32, 32, 32, 32, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 31, 32, 31, 33, 31, 35, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 34, 36, 34, 38, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 37, 39, 37, 40, 31, 37, 41, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 41, 1, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 1, 1, 1, 1, 1, 1, 1, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 1, 1, 1, 1, 42, 1, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 1, 44, 44, 44, 44, 44, 43, 43, 43, 43, 43, 43, 43, 43, 43, 43, 43, 43, 43, 43, 43, 43, 43, 43, 44, 43, 45, 43, 47, 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, 46, 48, 46, 50, 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, 51, 49, 49, 1, 53, 52, 52, 52, 52, 52, 52, 52, 52, 52, 52, 52, 52, 52, 52, 52, 52, 52, 52, 52, 52, 52, 52, 52, 52, 52, 52, 52, 52, 52, 52, 52, 52, 52, 52, 52, 52, 52, 54, 54, 54, 54, 54, 54, 54, 54, 54, 54, 52, 52, 52, 52, 52, 52, 52, 54, 54, 54, 54, 54, 54, 54, 54, 54, 54, 54, 54, 54, 54, 54, 54, 54, 54, 54, 54, 54, 54, 54, 54, 54, 54, 52, 52, 52, 52, 54, 52, 54, 54, 54, 54, 54, 54, 54, 54, 54, 54, 54, 54, 54, 54, 54, 54, 54, 54, 54, 54, 54, 54, 54, 54, 54, 54, 52, 52, 43, 0 ] class << self attr_accessor :_bel_trans_targs private :_bel_trans_targs, :_bel_trans_targs= end self._bel_trans_targs = [ 2, 0, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 0, 19, 20, 19, 20, 21, 22, 23, 24, 25, 26, 32, 27, 0, 27, 28, 29, 30, 31, 29, 30, 31, 38, 27, 39, 0, 34, 35, 36, 41, 37, 36, 41, 37, 0, 40, 39 ] class << self attr_accessor :_bel_trans_actions private :_bel_trans_actions, :_bel_trans_actions= end self._bel_trans_actions = [ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 3, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 7, 0, 0, 9, 10, 9, 0, 11, 0, 12, 13, 3, 15, 0, 0, 9, 17, 9, 0, 18, 0, 20, 21, 0 ] class << self attr_accessor :_bel_eof_actions private :_bel_eof_actions, :_bel_eof_actions= end self._bel_eof_actions = [ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 6, 8, 8, 7, 8, 0, 0, 14, 16, 16, 16, 0, 19, 22, 0 ] class << self attr_accessor :bel_start end self.bel_start = 1; class << self attr_accessor :bel_first_final end self.bel_first_final = 38; class << self attr_accessor :bel_error end self.bel_error = 0; class << self attr_accessor :bel_en_ident_node end self.bel_en_ident_node = 33; class << self attr_accessor :bel_en_string_node end self.bel_en_string_node = 34; class << self attr_accessor :bel_en_define_namespace_node end self.bel_en_define_namespace_node = 1; # end: ragel end
Public Instance Methods
each() { |ast_node| ... }
click to toggle source
# File lib/bel_parser/parsers/bel_script/define_namespace.rb, line 1894 def each @buffers = {} @incomplete = {} stack = [] data = @content.unpack('C*') p = 0 pe = data.length eof = data.length # begin: ragel begin p ||= 0 pe ||= data.length cs = bel_start end begin testEof = false _slen, _trans, _keys, _inds, _acts, _nacts = nil _goto_level = 0 _resume = 10 _eof_trans = 15 _again = 20 _test_eof = 30 _out = 40 while true if _goto_level <= 0 if p == pe _goto_level = _test_eof next end if cs == 0 _goto_level = _out next end end if _goto_level <= _resume _keys = cs << 1 _inds = _bel_index_offsets[cs] _slen = _bel_key_spans[cs] _wide = data[p].ord _trans = if ( _slen > 0 && _bel_trans_keys[_keys] <= _wide && _wide <= _bel_trans_keys[_keys + 1] ) then _bel_indicies[ _inds + _wide - _bel_trans_keys[_keys] ] else _bel_indicies[ _inds + _slen ] end cs = _bel_trans_targs[_trans] if _bel_trans_actions[_trans] != 0 case _bel_trans_actions[_trans] when 3 then begin trace('IDENTIFIER start_identifier') @identifier_started = true id_start = p; end when 21 then begin trace('IDENTIFIER end_identifier') id_end = p chars = data[id_start...id_end] completed = !chars.empty? ast_node = identifier(utf8_string(chars), complete: completed, character_range: [id_start, id_end]) @buffers[:ident] = ast_node end when 2 then begin trace('IDENTIFIER an_ident_err') id_end = p chars = data[id_start...id_end] ast_node = identifier(utf8_string(chars), complete: false, character_range: [id_start, id_end]) @buffers[:ident] = ast_node end when 20 then begin trace('IDENTIFIER ident_node_err') id_end = p chars = data[id_start...id_end] ast_node = identifier(utf8_string(chars), complete: false, character_range: [id_start, id_end]) yield ast_node end when 9 then begin trace('STRING start_string') @string_opened = true p_start = p end when 7 then begin trace('STRING a_string_err') p_end = p chars = data[p_start...p_end] ast_node = string(utf8_string(chars), complete: false, character_range: [p_start, p_end]) @buffers[:string] = ast_node end when 15 then begin trace('STRING string_node_err') p_end = p chars = data[p_start...p_end] ast_node = string(utf8_string(chars), complete: false, character_range: [p_start, p_end]) yield ast_node end when 5 then begin trace('DEFINE_NAMESPACE add_uri_domain') @buffers[:namespace_definition_domain] = uri() end when 13 then begin trace('DEFINE_NAMESPACE add_url_domain') @buffers[:namespace_definition_domain] = url() end when 4 then begin trace('IDENTIFIER end_identifier') id_end = p chars = data[id_start...id_end] completed = !chars.empty? ast_node = identifier(utf8_string(chars), complete: completed, character_range: [id_start, id_end]) @buffers[:ident] = ast_node end begin trace('DEFINE_NAMESPACE add_name') name = @buffers.delete(:ident) @buffers[:namespace_definition_name] = name end when 11 then begin trace('STRING stop_string') @string_closed = true p_end = p end begin trace('STRING string_end') completed = @string_opened && @string_closed chars = data[p_start...p_end] ast_node = string(utf8_string(chars), complete: true, character_range: [p_start, p_end]) @buffers[:string] = ast_node end when 10 then begin trace('STRING start_string') @string_opened = true p_start = p end begin trace('STRING stop_string') @string_closed = true p_end = p end begin trace('STRING string_end') completed = @string_opened && @string_closed chars = data[p_start...p_end] ast_node = string(utf8_string(chars), complete: true, character_range: [p_start, p_end]) @buffers[:string] = ast_node end when 18 then begin trace('STRING stop_string') @string_closed = true p_end = p end begin trace('STRING string_end') completed = @string_opened && @string_closed chars = data[p_start...p_end] ast_node = string(utf8_string(chars), complete: true, character_range: [p_start, p_end]) @buffers[:string] = ast_node end begin trace('STRING yield_string') yield @buffers[:string] end when 12 then begin trace('DEFINE_NAMESPACE add_string_value') string_node = @buffers.delete(:string) domain = @buffers.delete(:namespace_definition_domain) domain <<= string_node leaf = domain(domain) leaf.complete = string_node.complete @buffers[:namespace_definition_domain] = leaf end begin trace('DEFINE_NAMESPACE define_namespace_end') namespace_definition_node = namespace_definition() name = @buffers.delete(:namespace_definition_name) namespace_definition_node <<= keyword(name) domain = @buffers.delete(:namespace_definition_domain) unless domain.nil? namespace_definition_node <<= domain namespace_definition_node.complete = domain.complete end @buffers[:namespace_definition] = namespace_definition_node end begin trace('DEFINE_NAMESPACE yield_define_namespace') yield @buffers[:namespace_definition] end when 17 then begin trace('STRING start_string') @string_opened = true p_start = p end begin trace('STRING stop_string') @string_closed = true p_end = p end begin trace('STRING string_end') completed = @string_opened && @string_closed chars = data[p_start...p_end] ast_node = string(utf8_string(chars), complete: true, character_range: [p_start, p_end]) @buffers[:string] = ast_node end begin trace('STRING yield_string') yield @buffers[:string] end end end end if _goto_level <= _again if cs == 0 _goto_level = _out next end p += 1 if p != pe _goto_level = _resume next end end if _goto_level <= _test_eof if p == eof case _bel_eof_actions[cs] when 22 then begin trace('IDENTIFIER yield_identifier') yield @buffers[:ident] end when 7 then begin trace('STRING a_string_err') p_end = p chars = data[p_start...p_end] ast_node = string(utf8_string(chars), complete: false, character_range: [p_start, p_end]) @buffers[:string] = ast_node end when 19 then begin trace('IDENTIFIER end_identifier') id_end = p chars = data[id_start...id_end] completed = !chars.empty? ast_node = identifier(utf8_string(chars), complete: completed, character_range: [id_start, id_end]) @buffers[:ident] = ast_node end begin trace('IDENTIFIER yield_identifier') yield @buffers[:ident] end when 1 then begin trace('IDENTIFIER an_ident_eof') if @identifier_started id_end = p chars = data[id_start...id_end] completed = !chars.empty? ast_node = identifier(utf8_string(chars), complete: completed, character_range: [id_start, id_end]) @buffers[:ident] = ast_node end end begin trace('IDENTIFIER an_ident_err') id_end = p chars = data[id_start...id_end] ast_node = identifier(utf8_string(chars), complete: false, character_range: [id_start, id_end]) @buffers[:ident] = ast_node end when 6 then begin trace('STRING a_string_err') p_end = p chars = data[p_start...p_end] ast_node = string(utf8_string(chars), complete: false, character_range: [p_start, p_end]) @buffers[:string] = ast_node end begin trace('DEFINE_NAMESPACE define_namespace_node_eof') leaf = url() string_node = @buffers.delete(:string) unless string_node.nil? leaf <<= string_node leaf.complete = string_node.complete end domain_node = domain(leaf) domain_node.complete = leaf.complete namespace_definition_node = namespace_definition(domain_node) namespace_definition_node.complete = domain_node.complete yield namespace_definition_node end when 14 then begin trace('STRING string_node_err') p_end = p chars = data[p_start...p_end] ast_node = string(utf8_string(chars), complete: false, character_range: [p_start, p_end]) yield ast_node end begin trace('STRING string_node_eof') yield @buffers[:string] end when 8 then begin trace('STRING eof_string') p_end = p chars = data[p_start...p_end] ast_node = string(utf8_string(chars), complete: false, character_range: [p_start, p_end]) @buffers[:string] = ast_node end begin trace('STRING a_string_err') p_end = p chars = data[p_start...p_end] ast_node = string(utf8_string(chars), complete: false, character_range: [p_start, p_end]) @buffers[:string] = ast_node end begin trace('DEFINE_NAMESPACE define_namespace_node_eof') leaf = url() string_node = @buffers.delete(:string) unless string_node.nil? leaf <<= string_node leaf.complete = string_node.complete end domain_node = domain(leaf) domain_node.complete = leaf.complete namespace_definition_node = namespace_definition(domain_node) namespace_definition_node.complete = domain_node.complete yield namespace_definition_node end when 16 then begin trace('STRING eof_string') p_end = p chars = data[p_start...p_end] ast_node = string(utf8_string(chars), complete: false, character_range: [p_start, p_end]) @buffers[:string] = ast_node end begin trace('STRING string_node_err') p_end = p chars = data[p_start...p_end] ast_node = string(utf8_string(chars), complete: false, character_range: [p_start, p_end]) yield ast_node end begin trace('STRING string_node_eof') yield @buffers[:string] end end end end if _goto_level <= _out break end end end # end: ragel end