Class: QueryContext

Inherits:
Object
  • Object
show all
Defined in:
lib/needle_in_a_haystack/strategies/query_context.rb

Instance Method Summary collapse

Constructor Details

#initialize(strategy) ⇒ QueryContext

Returns a new instance of QueryContext.



2
3
4
# File 'lib/needle_in_a_haystack/strategies/query_context.rb', line 2

def initialize(strategy)
  @strategy = strategy
end

Instance Method Details

#executeObject



6
7
8
# File 'lib/needle_in_a_haystack/strategies/query_context.rb', line 6

def execute
  @strategy.execute
end