diff options
author | Nick Kallen <nkallen@nick-kallens-computer-2.local> | 2008-01-12 18:08:25 -0800 |
---|---|---|
committer | Nick Kallen <nkallen@nick-kallens-computer-2.local> | 2008-01-12 18:08:25 -0800 |
commit | c1e223f8a9e7394ede2fcd5621f7d43721023a20 (patch) | |
tree | 57f82f89cb0ebcedd81e73964a2f39a5e08818af /lib/active_relation/relations/attribute.rb | |
parent | cebfc0c1d830799c8b26834760fe40b44efb2d08 (diff) | |
download | rails-c1e223f8a9e7394ede2fcd5621f7d43721023a20.tar.gz rails-c1e223f8a9e7394ede2fcd5621f7d43721023a20.tar.bz2 rails-c1e223f8a9e7394ede2fcd5621f7d43721023a20.zip |
removed operator overloading of the predications (==, etc.)
Diffstat (limited to 'lib/active_relation/relations/attribute.rb')
-rw-r--r-- | lib/active_relation/relations/attribute.rb | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/lib/active_relation/relations/attribute.rb b/lib/active_relation/relations/attribute.rb index b7233a4b17..2fe702cb14 100644 --- a/lib/active_relation/relations/attribute.rb +++ b/lib/active_relation/relations/attribute.rb @@ -21,32 +21,32 @@ module ActiveRelation self.alias(qualified_name) end - def eql?(other) + def ==(other) relation == other.relation and name == other.name and @alias == other.alias end module Predications - def ==(other) + def equals(other) Predicates::Equality.new(self, other) end - def <(other) + def less_than(other) Predicates::LessThan.new(self, other) end - def <=(other) + def less_than_or_equal_to(other) Predicates::LessThanOrEqualTo.new(self, other) end - def >(other) + def greater_than(other) Predicates::GreaterThan.new(self, other) end - def >=(other) + def greater_than_or_equal_to(other) Predicates::GreaterThanOrEqualTo.new(self, other) end - def =~(regexp) + def matches(regexp) Predicates::Match.new(self, regexp) end end |