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.
6 7 8 |
# File 'lib/xmlhasher/parser.rb', line 6 def initialize( = {}) = end |
Instance Method Details
#parse(xml) ⇒ Object
10 11 12 13 14 |
# File 'lib/xmlhasher/parser.rb', line 10 def parse(xml) handler = Handler.new() Ox.sax_parse(handler, convert(xml)) handler.to_hash end |