Class: Motion::Configuration
- Inherits:
-
Object
- Object
- Motion::Configuration
- Defined in:
- lib/motion/configuration.rb
Class Attribute Summary collapse
-
.options ⇒ Object
readonly
Returns the value of attribute options.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize {|_self| ... } ⇒ Configuration
constructor
A new instance of Configuration.
Constructor Details
#initialize {|_self| ... } ⇒ Configuration
Returns a new instance of Configuration.
44 45 46 47 48 49 50 51 52 |
# File 'lib/motion/configuration.rb', line 44 def initialize yield self if block_given? # Ensure a value is selected for all options self.class..each(&method(:public_send)) # Prevent further changes @finalized = true end |
Class Attribute Details
.options ⇒ Object
Returns the value of attribute options.
8 9 10 |
# File 'lib/motion/configuration.rb', line 8 def @options end |
Class Method Details
.default ⇒ Object
10 11 12 |
# File 'lib/motion/configuration.rb', line 10 def default @default ||= new end |