class XMLable::Handlers::Attribute
Attribute
handles XML attributes objects
Public Instance Methods
from_xml_attribute(attribute)
click to toggle source
Create attribute object from the XML attribute
@param [Nokogiri::XML::Attr] attribute
@return [XMLable::Mixins::Object]
# File lib/xmlable/handlers/attribute.rb, line 36 def from_xml_attribute(attribute) Builder.build_attribute(attribute, self) end
inject_wraped(klass)
click to toggle source
@see XMLable::Handler::Base#inject_class
# File lib/xmlable/handlers/attribute.rb, line 14 def inject_wraped(klass) klass.class_eval do include XMLable::Mixins::ValueStorage include XMLable::Mixins::Instantiable end klass end
proxy()
click to toggle source
@see XMLable::Handler::Base#proxy
# File lib/xmlable/handlers/attribute.rb, line 25 def proxy @proxy ||= type_class.tap { |a| a.class_eval(&@block) if block_settings? } end