Class: Plant::Selector::ArrayCollection
- Inherits:
-
BlankSlate
- Object
- BlankSlate
- Plant::Selector::ArrayCollection
- Defined in:
- lib/selector.rb
Instance Method Summary collapse
- #compare(operator, operand) ⇒ Object
-
#initialize(collection) ⇒ ArrayCollection
constructor
A new instance of ArrayCollection.
- #method_missing(method, *args, &block) ⇒ Object
Constructor Details
#initialize(collection) ⇒ ArrayCollection
Returns a new instance of ArrayCollection.
49 50 51 |
# File 'lib/selector.rb', line 49 def initialize collection @collection = collection end |
Dynamic Method Handling
This class handles dynamic methods through the method_missing method
#method_missing(method, *args, &block) ⇒ Object
58 59 60 61 62 63 64 |
# File 'lib/selector.rb', line 58 def method_missing method, *args, &block if (@method) return compare(method, *args) end @method = method self end |