Sha256: 21e9d5d3bfa84db6afad9225639cc75b43f3eb38f859b2df151a5e1fff6e6b5b
Contents?: true
Size: 442 Bytes
Versions: 13
Compression:
Stored size: 442 Bytes
Contents
# encoding: utf-8 module Laximo module Respond class ListUnits < Laximo::Respond::Base def parsing_result(str) str.xpath('//ListUnits/row').inject([]) { |arr, node| h = node_to_hash(node) { |h1, n1| h1[:attributes] = nodes_to_hash(n1.xpath('./attribute')) } arr << h unless h.empty? } end # parsing_result end # ListUnits end # Respond end # Laximo
Version data entries
13 entries across 13 versions & 1 rubygems