Module: ActiveSupport::XmlMini

Extended by:
XmlMini
Included in:
XmlMini
Defined in:
lib/active_support/xml_mini.rb

Overview

XmlMini

To use the much faster libxml parser:

gem 'libxml-ruby', '=0.9.7'
XmlMini.backend = 'LibXML'

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#backendObject

Returns the value of attribute backend.



10
11
12
# File 'lib/active_support/xml_mini.rb', line 10

def backend
  @backend
end

Instance Method Details

#with_backend(name) ⇒ Object



22
23
24
25
26
27
# File 'lib/active_support/xml_mini.rb', line 22

def with_backend(name)
  old_backend, self.backend = backend, name
  yield
ensure
  self.backend = old_backend
end