Class: DaedalSL::AndFilter

Inherits:
BlockQuery show all
Defined in:
lib/daedal-sl/and_filter.rb

Instance Attribute Summary

Attributes inherited from BlockQuery

#base, #parent

Instance Method Summary collapse

Methods inherited from BlockQuery

build, #method_missing

Constructor Details

#initialize(parent, options) ⇒ AndFilter

Returns a new instance of AndFilter.



4
5
6
7
# File 'lib/daedal-sl/and_filter.rb', line 4

def initialize(parent, options)
  @query_type = Daedal::Filters::AndFilter
  super
end

Dynamic Method Handling

This class handles dynamic methods through the method_missing method in the class DaedalSL::BlockQuery

Instance Method Details

#filterObject



9
10
11
12
13
# File 'lib/daedal-sl/and_filter.rb', line 9

def filter
  if (result = yield)
    @base.filters << result
  end
end