Parent

Class Index [+]

Quicksearch

Nokogiri::XML::ParseOptions

 

Parse options for passing to Nokogiri.XML or Nokogiri.HTML

Constants

STRICT

Strict parsing

RECOVER

Recover from errors

NOENT

Substitute entities

DTDLOAD

Load external subsets

DTDATTR

Default DTD attributes

DTDVALID

validate with the DTD

NOERROR

suppress error reports

NOWARNING

suppress warning reports

PEDANTIC

pedantic error reporting

NOBLANKS

remove blank nodes

SAX1

use the SAX1 interface internally

XINCLUDE

Implement XInclude substitution

NONET

Forbid network access. Recommended for dealing with untrusted documents.

NODICT

Do not reuse the context dictionary

NSCLEAN

remove redundant namespaces declarations

NOCDATA

merge CDATA as text nodes

NOXINCNODE

do not generate XINCLUDE START/END nodes

COMPACT

compact small text nodes; no modification of the tree allowed afterwards (will possibly crash if you try to modify the tree)

OLD10

parse using XML-1.0 before update 5

NOBASEFIX

do not fixup XINCLUDE xml:base uris

HUGE

relax any hardcoded limit from the parser

DEFAULT_XML

the default options used for parsing XML documents

DEFAULT_HTML

Attributes

options[RW]

Public Class Methods

new(options = STRICT) click to toggle source
    # File lib/nokogiri/xml/parse_options.rb, line 55
55:       def initialize options = STRICT
56:         @options = options
57:       end

Public Instance Methods

inspect() click to toggle source
    # File lib/nokogiri/xml/parse_options.rb, line 89
89:       def inspect
90:         options = []
91:         self.class.constants.each do |k|
92:           options << k.downcase if send(:"#{k.downcase}?")
93:         end
94:         super.sub(/>$/, " " + options.join(', ') + ">")
95:       end
strict() click to toggle source
    # File lib/nokogiri/xml/parse_options.rb, line 78
78:       def strict
79:         @options &= ~RECOVER
80:         self
81:       end
strict?() click to toggle source
    # File lib/nokogiri/xml/parse_options.rb, line 83
83:       def strict?
84:         @options & RECOVER == STRICT
85:       end

Disabled; run with --debug to generate this.

[Validate]

Generated with the Darkfish Rdoc Generator 1.1.6.