Class: HTML5::TreeBuilders::SimpleTree::DocumentType

Inherits:
Node
  • Object
show all
Defined in:
lib/feed_tools/vendor/html5/lib/html5/treebuilders/simpletree.rb

Instance Attribute Summary collapse

Attributes inherited from Node

#attributes, #name, #value

Attributes inherited from Base::Node

#_flags, #childNodes, #parent

Instance Method Summary collapse

Methods inherited from Node

#appendChild, #cloneNode, #hasContent, #insertBefore, #insertText, #printTree, #removeChild

Methods inherited from Base::Node

#appendChild, #cloneNode, #hasContent, #insertBefore, #insertText, #removeChild, #reparentChildren

Constructor Details

#initialize(name) ⇒ DocumentType

Returns a new instance of DocumentType.



121
122
123
124
125
# File 'lib/feed_tools/vendor/html5/lib/html5/treebuilders/simpletree.rb', line 121

def initialize name
  super name
  @public_id = nil
  @system_id = nil
end

Instance Attribute Details

#public_idObject

Returns the value of attribute public_id.



115
116
117
# File 'lib/feed_tools/vendor/html5/lib/html5/treebuilders/simpletree.rb', line 115

def public_id
  @public_id
end

#system_idObject

Returns the value of attribute system_id.



115
116
117
# File 'lib/feed_tools/vendor/html5/lib/html5/treebuilders/simpletree.rb', line 115

def system_id
  @system_id
end

Instance Method Details

#to_sObject



117
118
119
# File 'lib/feed_tools/vendor/html5/lib/html5/treebuilders/simpletree.rb', line 117

def to_s
  "<!DOCTYPE #{name}>"
end