class Interface::Queryable
Public Class Methods
each(&block)
click to toggle source
# File lib/Olib/interface/queryable.rb, line 7 def self.each(&block) fetch.each &block end
empty?()
click to toggle source
# File lib/Olib/interface/queryable.rb, line 42 def self.empty? (fetch || []).empty? end
fetch()
click to toggle source
# File lib/Olib/interface/queryable.rb, line 3 def self.fetch [] end
find(&block)
click to toggle source
# File lib/Olib/interface/queryable.rb, line 15 def self.find(&block) fetch.find &block end
first()
click to toggle source
# File lib/Olib/interface/queryable.rb, line 34 def self.first fetch.first end
map(&block)
click to toggle source
# File lib/Olib/interface/queryable.rb, line 11 def self.map(&block) fetch.map &block end
reject(&block)
click to toggle source
# File lib/Olib/interface/queryable.rb, line 27 def self.reject(&block) fetch.reject &block end
sample(n = 1)
click to toggle source
# File lib/Olib/interface/queryable.rb, line 38 def self.sample(n = 1) fetch.sample n end
select(&block)
click to toggle source
# File lib/Olib/interface/queryable.rb, line 23 def self.select(&block) fetch.select &block end
size()
click to toggle source
# File lib/Olib/interface/queryable.rb, line 46 def self.size fetch.size end
sort(&block)
click to toggle source
# File lib/Olib/interface/queryable.rb, line 19 def self.sort(&block) fetch.sort &block end
where(**conds)
click to toggle source
# File lib/Olib/interface/queryable.rb, line 31 def self.where(**conds) end