Class: Cot::Property
- Inherits:
-
Object
- Object
- Cot::Property
- Defined in:
- lib/cot/property.rb
Instance Attribute Summary collapse
-
#args ⇒ Object
Returns the value of attribute args.
Instance Method Summary collapse
-
#initialize(params = {}) ⇒ Property
constructor
A new instance of Property.
- #primary ⇒ Object
- #primary? ⇒ Boolean
Constructor Details
#initialize(params = {}) ⇒ Property
Returns a new instance of Property.
4 5 6 |
# File 'lib/cot/property.rb', line 4 def initialize(params = {}) @args = params end |
Instance Attribute Details
#args ⇒ Object
Returns the value of attribute args.
3 4 5 |
# File 'lib/cot/property.rb', line 3 def args @args end |
Instance Method Details
#primary ⇒ Object
8 9 10 |
# File 'lib/cot/property.rb', line 8 def primary args[:primary] = true end |
#primary? ⇒ Boolean
12 13 14 |
# File 'lib/cot/property.rb', line 12 def primary? args[:primary] end |