Class: VCDOM::MiniDOM::ElementNS

Inherits:
Element show all
Includes:
ModNamespaceURIManageable
Defined in:
lib/vcdom/minidom/element_ns.rb

Constant Summary

Constants inherited from Node

Node::ATTRIBUTE_NODE, Node::CDATA_SECTION_NODE, Node::COMMENT_NODE, Node::DOCUMENT_FRAGMENT_NODE, Node::DOCUMENT_NODE, Node::DOCUMENT_TYPE_NODE, Node::ELEMENT_NODE, Node::ENTITY_NODE, Node::ENTITY_REFERENCE_NODE, Node::NOTATION_NODE, Node::PROCESSING_INSTRUCTION_NODE, Node::TEXT_NODE

Instance Method Summary collapse

Methods included from ModNamespaceURIManageable

#init_mod_namespaceuri_manageable, #local_name, #namespace_uri, #prefix, #prefix=

Methods inherited from Element

#attributes, #get_attribute, #get_attribute_node, #get_attribute_node_ns, #get_attribute_ns, #has_attribute, #has_attribute_ns, #has_attributes, #node_type, #remove_attribute, #remove_attribute_node, #remove_attribute_ns, #set_attribute, #set_attribute_node, #set_attribute_node_ns, #set_attribute_ns, #tagname

Methods included from ModElementsGetter

#get_elements_by_tagname, #get_elements_by_tagname_ns

Methods included from ModParentNode

#append_child, #child_nodes, #first_child, #has_child_nodes, #insert_before, #last_child, #remove_child, #replace_child, #text_content, #text_content=

Methods included from ModChildNode

#init_mod_child_node, #next_sibling, #parent_node, #previous_sibling

Methods inherited from Node

#append_child, #attributes, #child_nodes, #first_child, #has_attributes, #has_child_nodes, #insert_before, #last_child, #local_name, #namespace_uri, #next_sibling, #node_value, #node_value=, #owner_document, #parent_node, #prefix, #prefix=, #previous_sibling, #remove_child, #replace_child, #text_content, #text_content=

Constructor Details

#initialize(owner_document, namespace_uri, qualified_name) ⇒ ElementNS

INVALID_CHARACTER_ERR: Raised if the specified qualifiedName is not an

          XML name according to the XML version in use specified in 
          the Document.xmlVersion attribute. ?
NAMESPACE_ERR: Raised if the qualifiedName is a malformed qualified name, 
          if the qualifiedName has a prefix and the namespaceURI is null, 
          or if the qualifiedName has a prefix that is "xml" and the 
          namespaceURI is different from 
          "http://www.w3.org/XML/1998/namespace" [XML Namespaces], or 
          if the qualifiedName or its prefix is "xmlns" and the 
          namespaceURI is different from "http://www.w3.org/2000/xmlns/", 
          or if the namespaceURI is "http://www.w3.org/2000/xmlns/" and 
          neither the qualifiedName nor its prefix is "xmlns".


26
27
28
29
30
31
32
33
34
35
36
37
38
# File 'lib/vcdom/minidom/element_ns.rb', line 26

def initialize( owner_document, namespace_uri, qualified_name )
  begin
    super( owner_document, qualified_name )
  rescue DOMException => err
    if err.code == DOMException::INVALID_CHARACTER_ERR then
      raise DOMException.new( DOMException::INVALID_CHARACTER_ERR, 
              'The specified qualified name "' + qualified_name + '" is not an XML name.' )
    else
      raise err
    end
  end
  init_mod_namespaceuri_manageable( namespace_uri, qualified_name )
end