module Nokogiri::XML
Constants
- XML_C14N_1_0
-
Original C14N 1.0 spec canonicalization
- XML_C14N_1_1
-
C14N 1.1 spec canonicalization
- XML_C14N_EXCLUSIVE_1_0
-
Exclusive C14N 1.0 spec canonicalization
Public Class Methods
Source
# File lib/nokogiri/xml.rb, line 23 def Reader(string_or_io, url = nil, encoding = nil, options = ParseOptions::STRICT) options = Nokogiri::XML::ParseOptions.new(options) if Integer === options yield options if block_given? if string_or_io.respond_to?(:read) return Reader.from_io(string_or_io, url, encoding, options.to_i) end Reader.from_memory(string_or_io, url, encoding, options.to_i) end
Parse an XML
document using the Nokogiri::XML::Reader
API. See Nokogiri::XML::Reader
for mor information
Source
# File lib/nokogiri/xml/relax_ng.rb, line 9 def RelaxNG(string_or_io, options = ParseOptions::DEFAULT_SCHEMA) RelaxNG.new(string_or_io, options) end
Create a new Nokogiri::XML::RelaxNG
document from string_or_io
. See Nokogiri::XML::RelaxNG
for an example.
Source
# File lib/nokogiri/xml/schema.rb, line 9 def Schema(string_or_io, options = ParseOptions::DEFAULT_SCHEMA) Schema.new(string_or_io, options) end
Create a new Nokogiri::XML::Schema
object using a string_or_io
object.
Source
# File lib/nokogiri/xml.rb, line 42 def fragment(string, options = ParseOptions::DEFAULT_XML, &block) XML::DocumentFragment.parse(string, options, &block) end
Parse a fragment from string
in to a NodeSet
.
Source
# File lib/nokogiri/xml.rb, line 36 def parse(thing, url = nil, encoding = nil, options = ParseOptions::DEFAULT_XML, &block) Document.parse(thing, url, encoding, options, &block) end
Parse XML
. Convenience method for Nokogiri::XML::Document.parse