Class: DataMigrations::Instruction::Exec

Inherits:
Base
  • Object
show all
Defined in:
lib/data_migrations/instruction/exec.rb

Instance Attribute Summary collapse

Attributes inherited from Base

#columns, #migration, #options

Instance Method Summary collapse

Methods inherited from Base

#execute

Constructor Details

#initialize(migration, statement) ⇒ Exec

Returns a new instance of Exec.



6
7
8
9
# File 'lib/data_migrations/instruction/exec.rb', line 6

def initialize(migration, statement)
  super(migration)
  @statement = statement
end

Instance Attribute Details

#statementObject (readonly)

Returns the value of attribute statement.



4
5
6
# File 'lib/data_migrations/instruction/exec.rb', line 4

def statement
  @statement
end

Instance Method Details

#statementsObject



11
12
13
# File 'lib/data_migrations/instruction/exec.rb', line 11

def statements
  [statement]
end