Class: SimpleMigrator::Migration
- Inherits:
-
Object
- Object
- SimpleMigrator::Migration
- Defined in:
- lib/simple_migrator/migration.rb
Instance Attribute Summary collapse
-
#name ⇒ Object
readonly
Returns the value of attribute name.
-
#proc ⇒ Object
readonly
Returns the value of attribute proc.
Instance Method Summary collapse
- #<=>(other) ⇒ Object
-
#initialize(name, proc) ⇒ Migration
constructor
A new instance of Migration.
Constructor Details
#initialize(name, proc) ⇒ Migration
Returns a new instance of Migration.
5 6 7 8 |
# File 'lib/simple_migrator/migration.rb', line 5 def initialize(name, proc) @name = name @proc = proc end |
Instance Attribute Details
#name ⇒ Object (readonly)
Returns the value of attribute name.
3 4 5 |
# File 'lib/simple_migrator/migration.rb', line 3 def name @name end |
#proc ⇒ Object (readonly)
Returns the value of attribute proc.
3 4 5 |
# File 'lib/simple_migrator/migration.rb', line 3 def proc @proc end |
Instance Method Details
#<=>(other) ⇒ Object
10 11 12 |
# File 'lib/simple_migrator/migration.rb', line 10 def <=>(other) self.name <=> other.name end |