Class: Cliqr::Config::Event Private
Overview
This class is part of a private API. You should avoid using this class if possible, as it may be removed or be changed in the future.
The configuration setting which defines a event
Instance Attribute Summary collapse
-
#handler ⇒ Cliqr::Events::Handler
private
Event handler.
-
#name ⇒ String
private
Name of the event.
Instance Method Summary collapse
-
#finalize ⇒ Cliqr::Config::Base
private
Finalize config by adding default values for unset values.
-
#initialize ⇒ Event
constructor
private
New config instance with all attributes set as UNSET.
Methods inherited from Base
#set_config, #skip_validation?
Methods included from Validation
#errors, included, #read_attributes, #valid?, #validate, #validations
Methods included from DSL
Constructor Details
#initialize ⇒ Event
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
New config instance with all attributes set as UNSET
27 28 29 30 |
# File 'lib/cliqr/config/event.rb', line 27 def initialize @name = UNSET @handler = UNSET end |
Instance Attribute Details
#handler ⇒ Cliqr::Events::Handler
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Event handler
19 20 21 |
# File 'lib/cliqr/config/event.rb', line 19 def handler @handler end |
#name ⇒ String
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Name of the event
12 13 14 |
# File 'lib/cliqr/config/event.rb', line 12 def name @name end |
Instance Method Details
#finalize ⇒ Cliqr::Config::Base
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Finalize config by adding default values for unset values
35 36 37 38 39 40 |
# File 'lib/cliqr/config/event.rb', line 35 def finalize @name = Config.get_if_unset(@name, '') @handler = Config.get_if_unset(@handler, nil) self end |