Sha256: fd1ae11351d6e6fb251e85851cc7cbc6b455d49dc9e93ad694dc23c7b086dadf

Contents?: true

Size: 515 Bytes

Versions: 121

Compression:

Stored size: 515 Bytes

Contents

# frozen_string_literal: true

module ActiveRecord
  class Relation
    class FromClause # :nodoc:
      attr_reader :value, :name

      def initialize(value, name)
        @value = value
        @name = name
      end

      def merge(other)
        self
      end

      def empty?
        value.nil?
      end

      def ==(other)
        self.class == other.class && value == other.value && name == other.name
      end

      def self.empty
        @empty ||= new(nil, nil).freeze
      end
    end
  end
end

Version data entries

121 entries across 116 versions & 11 rubygems

Version Path
activerecord-8.0.0.beta1 lib/active_record/relation/from_clause.rb
omg-activerecord-8.0.0.alpha9 lib/active_record/relation/from_clause.rb
omg-activerecord-8.0.0.alpha8 lib/active_record/relation/from_clause.rb
omg-activerecord-8.0.0.alpha7 lib/active_record/relation/from_clause.rb
omg-activerecord-8.0.0.alpha4 lib/active_record/relation/from_clause.rb
omg-activerecord-8.0.0.alpha3 lib/active_record/relation/from_clause.rb
omg-activerecord-8.0.0.alpha2 lib/active_record/relation/from_clause.rb
omg-activerecord-8.0.0.alpha1 lib/active_record/relation/from_clause.rb
activerecord-7.1.4 lib/active_record/relation/from_clause.rb
activerecord-7.2.1 lib/active_record/relation/from_clause.rb
activerecord-7.2.0 lib/active_record/relation/from_clause.rb
activerecord-7.2.0.rc1 lib/active_record/relation/from_clause.rb
blacklight-spotlight-3.6.0.beta8 vendor/bundle/ruby/3.2.0/gems/activerecord-7.0.8.4/lib/active_record/relation/from_clause.rb
blacklight-spotlight-3.6.0.beta8 vendor/bundle/ruby/3.2.0/gems/activerecord-7.1.3.4/lib/active_record/relation/from_clause.rb
activerecord-7.2.0.beta3 lib/active_record/relation/from_clause.rb
cm-admin-1.5.22 vendor/bundle/ruby/3.3.0/gems/activerecord-7.0.5.1/lib/active_record/relation/from_clause.rb
cm-admin-1.5.21 vendor/bundle/ruby/3.3.0/gems/activerecord-7.0.5.1/lib/active_record/relation/from_clause.rb
cm-admin-1.5.20 vendor/bundle/ruby/3.3.0/gems/activerecord-7.0.5.1/lib/active_record/relation/from_clause.rb
tinymce-rails-7.1.2 vendor/bundle/ruby/3.3.0/gems/activerecord-7.1.3.4/lib/active_record/relation/from_clause.rb
activerecord-7.2.0.beta2 lib/active_record/relation/from_clause.rb