Class: SchemaDev::Config::Tuple
- Inherits:
-
Object
- Object
- SchemaDev::Config::Tuple
- Defined in:
- lib/schema_dev/config.rb
Instance Method Summary collapse
Instance Method Details
#match?(other) ⇒ Boolean
77 78 79 80 81 82 |
# File 'lib/schema_dev/config.rb', line 77 def match?(other) return false if self.ruby and other.ruby and self.ruby != other.ruby return false if self.activerecord and other.activerecord and self.activerecord != other.activerecord return false if self.db and other.db and self.db != other.db true end |
#match_any?(others) ⇒ Boolean
84 85 86 |
# File 'lib/schema_dev/config.rb', line 84 def match_any?(others) others.any?{|other| self.match? other} end |
#to_hash ⇒ Object
88 89 90 |
# File 'lib/schema_dev/config.rb', line 88 def to_hash super.reject{ |k, val| val.nil? } end |