Sha256: 74d80052004ebf364df790b8b8f81df526ff191f0a70eba3da4c9b9c890fae18
Contents?: true
Size: 743 Bytes
Versions: 19
Compression:
Stored size: 743 Bytes
Contents
require 'lhm/adapter' # Defines the same global namespace as LHM's gem does to mimic its API # while providing a different behaviour. We delegate all LHM's methods to # ActiveRecord so that you don't need to modify your old LHM migrations module Lhm # Yields an adapter instance so that Lhm migration Dsl methods get # delegated to ActiveRecord::Migration ones instead # # @param table_name [String] # @param _options [Hash] # @param block [Block] def self.change_table(table_name, _options = {}, &block) yield Adapter.new(@migration, table_name) end # Sets the migration to apply the adapter to # # @param migration [ActiveRecord::Migration] def self.migration=(migration) @migration = migration end end
Version data entries
19 entries across 19 versions & 2 rubygems