Class: Hotsheet::Column
- Inherits:
-
Object
- Object
- Hotsheet::Column
- Includes:
- Config
- Defined in:
- lib/hotsheet/column.rb
Constant Summary collapse
- CONFIG =
{ editable: { allowed_classes: [FalseClass, Proc], default: true }, type: { allowed_classes: [Symbol], default: nil }, visible: { allowed_classes: [FalseClass, Proc], default: true } }.freeze
Instance Attribute Summary collapse
-
#config ⇒ Object
readonly
Returns the value of attribute config.
Instance Method Summary collapse
- #editable? ⇒ Boolean
-
#initialize(config) ⇒ Column
constructor
A new instance of Column.
- #type ⇒ Object
- #visible? ⇒ Boolean
Methods included from Config
Constructor Details
Instance Attribute Details
#config ⇒ Object (readonly)
Returns the value of attribute config.
6 7 8 |
# File 'lib/hotsheet/column.rb', line 6 def config @config end |
Instance Method Details
#editable? ⇒ Boolean
18 19 20 |
# File 'lib/hotsheet/column.rb', line 18 def editable? is? :editable end |
#type ⇒ Object
22 23 24 |
# File 'lib/hotsheet/column.rb', line 22 def type @config[:type] end |
#visible? ⇒ Boolean
26 27 28 |
# File 'lib/hotsheet/column.rb', line 26 def visible? is? :visible end |