aboutsummaryrefslogtreecommitdiffstats
path: root/activerecord/lib/active_record/dynamic_scope_match.rb
diff options
context:
space:
mode:
authorRizwan Reza <rizwanreza@gmail.com>2010-06-15 23:02:51 +0430
committerRizwan Reza <rizwanreza@gmail.com>2010-06-15 23:02:51 +0430
commitc7f78b184df5cdeee301af06472f7f14465ed7e4 (patch)
tree9a57f556b21d09c1fee3cdb44352105e38f077d3 /activerecord/lib/active_record/dynamic_scope_match.rb
parentde65c82bfa4fc41954750572e644fdf37bacb31e (diff)
downloadrails-c7f78b184df5cdeee301af06472f7f14465ed7e4.tar.gz
rails-c7f78b184df5cdeee301af06472f7f14465ed7e4.tar.bz2
rails-c7f78b184df5cdeee301af06472f7f14465ed7e4.zip
Added description and title to Dynamic Scope Match
Diffstat (limited to 'activerecord/lib/active_record/dynamic_scope_match.rb')
-rw-r--r--activerecord/lib/active_record/dynamic_scope_match.rb7
1 files changed, 7 insertions, 0 deletions
diff --git a/activerecord/lib/active_record/dynamic_scope_match.rb b/activerecord/lib/active_record/dynamic_scope_match.rb
index f796ba669a..15f65be6bc 100644
--- a/activerecord/lib/active_record/dynamic_scope_match.rb
+++ b/activerecord/lib/active_record/dynamic_scope_match.rb
@@ -1,4 +1,11 @@
module ActiveRecord
+
+ # = Active Record Dynamic Scope Match
+ #
+ # Provides dynamic attribute-based scopes such as <tt>scoped_by_price(4.99)</tt>
+ # if, for example, the <tt>Product</tt> has an attribute with that name. You can
+ # chain more <tt>scoped_by_* </tt> methods after the other. It acts like a named
+ # scope except that it's dynamic.
class DynamicScopeMatch
def self.match(method)
ds_match = self.new(method)