Module: SAXMachine
- Included in:
- WeBee::Datacenter, WeBee::DatacenterLimit, WeBee::Datastore, WeBee::Enterprise, WeBee::Machine, WeBee::OVFPackage, WeBee::Rack, WeBee::User, WeBee::VDC, WeBee::VDCNetwork, WeBee::VirtualAppliance, WeBee::VirtualMachine
- Defined in:
- lib/webee.rb
Overview
Monkeypatch SAXMachine to keep the raw XMK
Ugly but fun, isn’t it? This may blow up at some point
Instance Method Summary collapse
Instance Method Details
#old_parse ⇒ Object
18 |
# File 'lib/webee.rb', line 18 alias_method :old_parse, :parse |
#parse(xml, on_error = nil, on_warning = nil) ⇒ Object
20 21 22 23 24 25 26 27 |
# File 'lib/webee.rb', line 20 def parse(xml, on_error = nil, on_warning = nil) obj = old_parse(xml, on_error, on_warning) obj.instance_variable_set :@raw, xml obj.class.send :define_method, 'raw' do @raw end obj end |