Module: XML::XMLRPC::Parser::ValueParser::Array
- Defined in:
- lib/xml/libxml/xmlrpc/parser.rb
Overview
Parse an ‘array’ type.
Class Method Summary collapse
Class Method Details
.parse(node) ⇒ Object
250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 |
# File 'lib/xml/libxml/xmlrpc/parser.rb', line 250 def self.parse(node) value = [] node.each_child do |child_node| if child_node.name == "data" value_nodes = [] child_node.each_child do |value_node| if value_node.name == "value" value_nodes.push value_node end end value = Parser::ValueParser.parse(value_nodes) break # yes, first hit is last hit, so says the stay-puff't spec. end end return value end |