Sha256: 39bf2ecbb85e71ab63ee901bc1275d57677fc34d9e2bde585d688d83329226c7

Contents?: true

Size: 598 Bytes

Versions: 176

Compression:

Stored size: 598 Bytes

Contents

module Arel
  module Compatibility # :nodoc:
    class Wheres # :nodoc:
      include Enumerable

      module Value # :nodoc:
        attr_accessor :visitor
        def value
          visitor.accept self
        end

        def name
          super.to_sym
        end
      end

      def initialize engine, collection
        @engine     = engine
        @collection = collection
      end

      def each
        to_sql = Visitors::ToSql.new @engine

        @collection.each { |c|
          c.extend(Value)
          c.visitor = to_sql
          yield c
        }
      end
    end
  end
end

Version data entries

176 entries across 154 versions & 23 rubygems

Version Path
fc-webicons-0.0.3 vendor/bundle/ruby/1.9.1/gems/arel-3.0.2/lib/arel/compatibility/wheres.rb
fc-webicons-0.0.2 vendor/bundle/ruby/1.9.1/gems/arel-3.0.2/lib/arel/compatibility/wheres.rb
fc-webicons-0.0.1 vendor/bundle/ruby/1.9.1/gems/arel-3.0.2/lib/arel/compatibility/wheres.rb
arel-4.0.0.beta2 lib/arel/compatibility/wheres.rb
arel-4.0.0.beta1 lib/arel/compatibility/wheres.rb
active_mailer-0.0.5 test/fixtures/dummyapp_rails_3.2/vendor/bundle/ruby/1.9.1/gems/arel-3.0.2/lib/arel/compatibility/wheres.rb
active_mailer-0.0.4 test/fixtures/dummyapp_rails_3.2/vendor/bundle/ruby/1.9.1/gems/arel-3.0.2/lib/arel/compatibility/wheres.rb
active_mailer-0.0.3 test/fixtures/dummyapp_rails_3.2/vendor/bundle/ruby/1.9.1/gems/arel-3.0.2/lib/arel/compatibility/wheres.rb
challah-0.9.1.beta.3 vendor/bundle/gems/arel-3.0.2/lib/arel/compatibility/wheres.rb
devise_sociable-0.1.0 vendor/bundle/gems/arel-3.0.2/lib/arel/compatibility/wheres.rb
challah-0.9.1.beta vendor/bundle/gems/arel-3.0.2/lib/arel/compatibility/wheres.rb
sunrise-cms-0.5.0.rc1 vendor/bundle/ruby/1.9.1/gems/arel-3.0.2/lib/arel/compatibility/wheres.rb
challah-0.9.0 vendor/bundle/gems/arel-3.0.2/lib/arel/compatibility/wheres.rb
dirty_history-0.7.3 dirty_history/ruby/1.9.1/gems/arel-2.2.1/lib/arel/compatibility/wheres.rb
dirty_history-0.7.2 dirty_history/ruby/1.9.1/gems/arel-2.2.1/lib/arel/compatibility/wheres.rb
dirty_history-0.7.1 dirty_history/ruby/1.9.1/gems/arel-2.2.1/lib/arel/compatibility/wheres.rb
challah-rolls-0.2.0 vendor/bundle/gems/challah-0.8.0.pre/vendor/bundle/gems/arel-3.0.2/lib/arel/compatibility/wheres.rb
challah-rolls-0.2.0 vendor/bundle/gems/challah-0.8.3/vendor/bundle/gems/arel-3.0.2/lib/arel/compatibility/wheres.rb
challah-rolls-0.2.0 vendor/bundle/gems/arel-3.0.2/lib/arel/compatibility/wheres.rb
challah-0.8.3 vendor/bundle/gems/arel-3.0.2/lib/arel/compatibility/wheres.rb