Class: KafoWizards::Entries::BooleanEntry
- Inherits:
-
AbstractEntry
- Object
- AbstractEntry
- KafoWizards::Entries::BooleanEntry
- Defined in:
- lib/kafo_wizards/entries/boolean.rb
Instance Attribute Summary
Attributes inherited from AbstractEntry
#default_value, #description, #label, #name, #parent, #post_hook, #pre_hook, #validators, #value
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(name, options = {}) ⇒ BooleanEntry
constructor
A new instance of BooleanEntry.
Methods inherited from AbstractEntry
#call_post_hook, #call_pre_hook, descendants, #display_type, inherited, #required?, #update, #validate
Constructor Details
#initialize(name, options = {}) ⇒ BooleanEntry
Returns a new instance of BooleanEntry.
5 6 7 8 |
# File 'lib/kafo_wizards/entries/boolean.rb', line 5 def initialize(name, ={}) super(name, ) @value = @default_value ? true : false end |
Class Method Details
.entry_type ⇒ Object
10 11 12 |
# File 'lib/kafo_wizards/entries/boolean.rb', line 10 def self.entry_type :boolean end |