class Believer::FilterCommand
A command implementation which includes a CQL WHERE clause
Public Instance Methods
query_attributes()
click to toggle source
Calls superclass method
Believer::Command#query_attributes
# File lib/believer/filter_command.rb, line 5 def query_attributes attrs = super attrs.merge(:wheres => (wheres.dup)) end
where(*args)
click to toggle source
# File lib/believer/filter_command.rb, line 18 def where(*args) q = clone q.wheres << WhereClause.new(*args) q end
wheres()
click to toggle source
# File lib/believer/filter_command.rb, line 10 def wheres @wheres ||= [] end
wheres=(w)
click to toggle source
# File lib/believer/filter_command.rb, line 14 def wheres=(w) @wheres = w.is_a?(Array) ? w : [w] end