Class: REXML::DocType

Class REXML::DocType |
In: | rexml/doctype.rb
Parent: | Parent

Represents an XML DOCTYPE declaration; that is, the contents of <!DOCTYPE ... >. DOCTYPES can be used to declare the DTD of a document, as well as being used to declare entities used in the document.

Methods

add clone entity new parse_stream pull write

Attributes

:entities | [R] |
     name is the name of the doctype
external_id is the referenced DTD, if given
:external_id | [R] |
     name is the name of the doctype
external_id is the referenced DTD, if given
:name | [R] |
     name is the name of the doctype
external_id is the referenced DTD, if given

Public Class methods

new( first, parent=nil )

Constructor @param parent If first is String, it must be String and set to external_id. Otherwise, it is set as the parent of this object. @param first can be multiple types. If String, name is set to this and external_id is set to nil. If DocType, the object is cloned. If Source, the source is scanned for the DOCTYPE declaration.

parse_stream(source, listener)

pull(source)

Public Instance methods

clone()

write( output, indent=0 )

entity( name )

add(child)