module Stretchy::Scopes::ClassMethods

Public Instance Methods

stretch(name, block) click to toggle source
# File lib/stretchy/scopes.rb, line 25
def stretch(name, block)
  stretchy_scope.send(:define_method, name, &block)
end
stretchify(options = {}) click to toggle source
# File lib/stretchy/scopes.rb, line 9
def stretchify(options = {})
  @stretchy_options = options
end
stretchy_options() click to toggle source
# File lib/stretchy/scopes.rb, line 17
def stretchy_options
  Hash(@stretchy_options)
end
stretchy_scope() click to toggle source
# File lib/stretchy/scopes.rb, line 21
def stretchy_scope
  @scopes_class ||= Class.new Stretchy::API
end