class XMLBuilder::PathParser::Attribute

Attributes

name[R]

Public Class Methods

new(name) click to toggle source
# File lib/ec2/amitools/xmlbuilder.rb, line 200
def initialize(name)
  @name = name
end

Public Instance Methods

assign_visit(rexml_node, value) click to toggle source
# File lib/ec2/amitools/xmlbuilder.rb, line 209
def assign_visit(rexml_node, value)
  raise 'Can only assign an attribute to an element.' if !rexml_node.is_a?(REXML::Element)
  rexml_node.attributes[@name] = value.to_s
end
retrieve_visit(rexml_node) click to toggle source
# File lib/ec2/amitools/xmlbuilder.rb, line 214
def retrieve_visit(rexml_node)
  raise 'Accessor not valid for paths with an attribute'
end
walk_visit(rexml_node) click to toggle source

Stays on the same node in the dom

# File lib/ec2/amitools/xmlbuilder.rb, line 205
def walk_visit(rexml_node)
  rexml_node
end