Class: Cassowary::EditConstraint
- Inherits:
-
EditOrStayConstraint
- Object
- Constraint
- EditOrStayConstraint
- Cassowary::EditConstraint
- Defined in:
- lib/constraint/edit_or_stay_constraint.rb
Instance Attribute Summary collapse
-
#value ⇒ Object
Returns the value of attribute value.
Attributes inherited from EditOrStayConstraint
Attributes inherited from Constraint
Instance Method Summary collapse
- #edit_constraint? ⇒ Boolean
-
#initialize(hash = {}) ⇒ EditConstraint
constructor
A new instance of EditConstraint.
Methods inherited from EditOrStayConstraint
Methods inherited from Constraint
#expression, #inequality?, #required?, #stay_constraint?
Constructor Details
#initialize(hash = {}) ⇒ EditConstraint
Returns a new instance of EditConstraint.
25 26 27 28 |
# File 'lib/constraint/edit_or_stay_constraint.rb', line 25 def initialize(hash = {}) super self.value = hash[:value] end |
Instance Attribute Details
#value ⇒ Object
Returns the value of attribute value.
23 24 25 |
# File 'lib/constraint/edit_or_stay_constraint.rb', line 23 def value @value end |
Instance Method Details
#edit_constraint? ⇒ Boolean
30 31 32 |
# File 'lib/constraint/edit_or_stay_constraint.rb', line 30 def edit_constraint? true end |