Sha256: 43559399384a8ac3375efc341ce3024b24ea875ee064f0b28d7737945a65c3c7

Contents?: true

Size: 1.06 KB

Versions: 17

Compression:

Stored size: 1.06 KB

Contents

module Scenic
  # The in-memory representation of a database index.
  #
  # **This object is used internally by adapters and the schema dumper and is
  # not intended to be used by application code. It is documented here for
  # use by adapter gems.**
  #
  # @api extension
  class Index
    # The name of the object that has the index
    # @return [String]
    attr_reader :object_name

    # The name of the index
    # @return [String]
    attr_reader :index_name

    # The SQL statement that defines the index
    # @return [String]
    #
    # @example
    #   "CREATE INDEX index_users_on_email ON users USING btree (email)"
    attr_reader :definition

    # Returns a new instance of Index
    #
    # @param object_name [String] The name of the object that has the index
    # @param index_name [String] The name of the index
    # @param definition [String] The SQL statements that defined the index
    def initialize(object_name:, index_name:, definition:)
      @object_name = object_name
      @index_name = index_name
      @definition = definition
    end
  end
end

Version data entries

17 entries across 17 versions & 2 rubygems

Version Path
scenic-1.8.0 lib/scenic/index.rb
scenic-1.7.0 lib/scenic/index.rb
scenic-1.6.0 lib/scenic/index.rb
scenic-1.5.5 lib/scenic/index.rb
scenic-jets-1.5.5 lib/scenic/index.rb
scenic-jets-1.5.4 lib/scenic/index.rb
scenic-1.5.4 lib/scenic/index.rb
scenic-1.5.3 lib/scenic/index.rb
scenic-1.5.2 lib/scenic/index.rb
scenic-1.5.1 lib/scenic/index.rb
scenic-1.5.0 lib/scenic/index.rb
scenic-1.4.1 lib/scenic/index.rb
scenic-1.4.0 lib/scenic/index.rb
scenic-1.3.0 lib/scenic/index.rb
scenic-1.2.0 lib/scenic/index.rb
scenic-1.1.1 lib/scenic/index.rb
scenic-1.1.0 lib/scenic/index.rb