Class: XmlHasher::Parser
- Inherits:
-
Object
- Object
- XmlHasher::Parser
- Defined in:
- lib/xmlhasher/parser.rb
Instance Method Summary collapse
-
#initialize(options = {}) ⇒ Parser
constructor
A new instance of Parser.
- #parse(xml) ⇒ Object
Constructor Details
#initialize(options = {}) ⇒ Parser
Returns a new instance of Parser.
7 8 9 |
# File 'lib/xmlhasher/parser.rb', line 7 def initialize( = {}) = end |
Instance Method Details
#parse(xml) ⇒ Object
11 12 13 14 15 |
# File 'lib/xmlhasher/parser.rb', line 11 def parse(xml) handler = Handler.new() Ox.sax_parse(handler, convert(xml)) handler.to_hash end |