class Nokogiri::XML::Node

def each

Iterate over each attribute name and value pair for this Node.
##
def each
  attribute_nodes.each do |node|
    yield [node.node_name, node.value]
  end
end