Class: Rabbit::Parser::SlidePropertySetter
- Inherits:
-
Object
- Object
- Rabbit::Parser::SlidePropertySetter
- Defined in:
- lib/rabbit/parser.rb
Instance Method Summary collapse
- #apply(element) ⇒ Object
-
#initialize(slide) ⇒ SlidePropertySetter
constructor
A new instance of SlidePropertySetter.
Constructor Details
#initialize(slide) ⇒ SlidePropertySetter
Returns a new instance of SlidePropertySetter.
46 47 48 |
# File 'lib/rabbit/parser.rb', line 46 def initialize() @slide = end |
Instance Method Details
#apply(element) ⇒ Object
50 51 52 53 54 55 56 |
# File 'lib/rabbit/parser.rb', line 50 def apply(element) return unless element.is_a?(Element::DescriptionList) element.each do |item| name = Parser.normalize_property_name(item.term.text) @slide[name] = item.content.text.strip end end |