Parent

Files

Class/Module Index [+]

Quicksearch

XSD::XMLParser::Parser

Attributes

charset[RW]

Public Class Methods

add_factory(factory) click to toggle source
# File lib/xsd/xmlparser/parser.rb, line 40
def self.add_factory(factory)
  if $DEBUG
    puts "Set #{ factory } as XML processor."
  end
  @@parser_factory = factory
end
create_parser(host, opt = {}) click to toggle source
# File lib/xsd/xmlparser/parser.rb, line 33
def self.create_parser(host, opt = {})
  unless @@parser_factory
    raise ParserError.new("illegal XML parser configuration")
  end
  @@parser_factory.new(host, opt)
end
factory() click to toggle source
# File lib/xsd/xmlparser/parser.rb, line 29
def self.factory
  @@parser_factory
end
new(host, opt = {}) click to toggle source
# File lib/xsd/xmlparser/parser.rb, line 51
def initialize(host, opt = {})
  @host = host
  @charset = opt[:charset] || nil
end

Public Instance Methods

parse(string_or_readable) click to toggle source
# File lib/xsd/xmlparser/parser.rb, line 56
def parse(string_or_readable)
  @textbuf = ''
  prologue
  do_parse(string_or_readable)
  epilogue
end

[Validate]

Generated with the Darkfish Rdoc Generator 2.