class LibXML::XML::Attr

def child?


Returns whether this attribute has child attributes.

attr.child? -> (true|false)
call-seq:
def child?
  not self.children.nil?
end

def doc?

XML::Document.
Determine whether this attribute is associated with an

attr.doc? -> (true|false)
call-seq:
def doc?
  not self.doc.nil?
end

def each_sibling(&blk)

def each_sibling(&blk)
  siblings(self,&blk)
end

def last?

Determine whether this is the last attribute.

attr.last? -> (true|false)
call-seq:
def last?
  self.last.nil?
end

def namespaces

associated with this node.
which is used to access the namespaces
Returns this node's XML::Namespaces object,

attr.namespacess -> XML::Namespaces
call-seq:
def namespaces
  @namespaces ||= XML::Namespaces.new(self)
end

def next?

Determine whether there is a next attribute.

attr.next? -> (true|false)
call-seq:
def next?
  not self.next.nil?
end

def node_type_name

Returns this node's type name
def node_type_name
  if node_type == Node::ATTRIBUTE_NODE
    'attribute'
  else
    raise(UnknownType, "Unknown node type: %n", node.node_type);
  end
end

def ns?

namespace.
Determine whether this attribute has an associated

attr.ns? -> (true|false)
call-seq:
def ns?
  not self.ns.nil?
end

def parent?

Determine whether this attribute has a parent.

attr.parent? -> (true|false)
call-seq:
def parent?
  not self.parent.nil?
end

def prev?

Determine whether there is a previous attribute.

attr.prev? -> (true|false)
call-seq:
def prev?
  not self.prev.nil?
end

def siblings(node, &blk)

Iterates nodes and attributes
def siblings(node, &blk)
  if n = node
    loop do
      blk.call(n)
      break unless n = n.next
    end
  end
end

def to_a

def to_a
  inject([]) do |ary,a| 
    ary << [a.name, a.value]
    ary
  end
end

def to_h

def to_h
  inject({}) do |h,a|
    h[a.name] = a.value
    h
  end
end

def to_s

def to_s
  "#{name} = #{value}"
end