Class: XMigra::DeclarativeSupport::Table::ColumnListConstraint
- Inherits:
-
Constraint
- Object
- Constraint
- XMigra::DeclarativeSupport::Table::ColumnListConstraint
- Defined in:
- lib/xmigra/declarative_support/table.rb
Direct Known Subclasses
Constant Summary
Constants inherited from Constraint
XMigra::DeclarativeSupport::Table::Constraint::SUBTYPES
Instance Attribute Summary collapse
-
#columns ⇒ Object
readonly
Returns the value of attribute columns.
Attributes inherited from Constraint
Instance Method Summary collapse
- #constrained_colnames ⇒ Object
-
#initialize(name, constr_spec) ⇒ ColumnListConstraint
constructor
A new instance of ColumnListConstraint.
Methods inherited from Constraint
bad_spec, #constraint_type, deserialize, each_type, implicit_type, inherited, #only_on_column_at_creation?, type_by_identifier
Constructor Details
#initialize(name, constr_spec) ⇒ ColumnListConstraint
Returns a new instance of ColumnListConstraint.
169 170 171 172 |
# File 'lib/xmigra/declarative_support/table.rb', line 169 def initialize(name, constr_spec) super(name, constr_spec) @columns = get_and_validate_columns(constr_spec) end |
Instance Attribute Details
#columns ⇒ Object (readonly)
Returns the value of attribute columns.
174 175 176 |
# File 'lib/xmigra/declarative_support/table.rb', line 174 def columns @columns end |
Instance Method Details
#constrained_colnames ⇒ Object
176 177 178 |
# File 'lib/xmigra/declarative_support/table.rb', line 176 def constrained_colnames columns end |