Class: Microformat
- Extended by:
- Base
- Defined in:
- lib/microformat.rb,
lib/microformat/simple.rb
Defined Under Namespace
Instance Method Summary collapse
Methods included from Base
find, find_in_children, timeout=
Dynamic Method Handling
This class handles dynamic methods through the method_missing method
#method_missing(method, *args, &block) ⇒ Object
304 305 306 307 308 |
# File 'lib/microformat.rb', line 304 def method_missing(method, *args, &block) return super unless method == :properties || @properties.include?(method.to_s) self.class.class_eval { define_method(method) { instance_variable_get("@#{method}") } } instance_variable_get("@#{method}") end |