Class: ActiveSchema::Configuration
- Inherits:
-
Object
- Object
- ActiveSchema::Configuration
- Defined in:
- lib/active_schema/configuration.rb
Instance Attribute Summary collapse
-
#feeder ⇒ Object
Returns the value of attribute feeder.
-
#skip_model ⇒ Object
Returns the value of attribute skip_model.
-
#skip_validation_for_column ⇒ Object
Returns the value of attribute skip_validation_for_column.
Instance Method Summary collapse
-
#initialize ⇒ Configuration
constructor
A new instance of Configuration.
Constructor Details
#initialize ⇒ Configuration
Returns a new instance of Configuration.
7 8 9 10 11 12 13 14 15 16 |
# File 'lib/active_schema/configuration.rb', line 7 def initialize self.feeder = OnTheFlyFeeder.new(self) self.skip_validation_for_column = proc {|column| column.name =~ /^(((created|updated)_(at|on))|position)$/ } self.skip_model = proc {|model| model == ::ActiveRecord::Base || (model.respond_to?(:abstract_class?) && model.abstract_class?) } end |
Instance Attribute Details
#feeder ⇒ Object
Returns the value of attribute feeder.
3 4 5 |
# File 'lib/active_schema/configuration.rb', line 3 def feeder @feeder end |
#skip_model ⇒ Object
Returns the value of attribute skip_model.
3 4 5 |
# File 'lib/active_schema/configuration.rb', line 3 def skip_model @skip_model end |
#skip_validation_for_column ⇒ Object
Returns the value of attribute skip_validation_for_column.
3 4 5 |
# File 'lib/active_schema/configuration.rb', line 3 def skip_validation_for_column @skip_validation_for_column end |