class Opulent::Settings
@Settings
Constants
- BUFFER
Set buffer variable name
- DEFAULTS
Opulent
runtime settings- DEFAULT_EACH_KEY
Default yield target which is used for child block replacements
- DEFAULT_EACH_VALUE
Default yield target which is used for child block replacements
- END_EXPLICIT
- END_INSERTION
Check to see if we need to insert an end block for the current evaluation control do || .* end
- END_REMOVAL
- EVALUATION_CHECK
Check if the attribute value is a bare string
- FILE_EXTENSION
Default
Opulent
file extension- INLINE_NODE
List of inline node names
- INTERPOLATION_CHECK
Check whether text should or shouldn't be evaluated
- MULTI_NODE
List of inline node parents which can be either inline or have complex structures inside of them, such as anchor tags
- SELF_ENCLOSING
List of self enclosing node elements
- SHORTHAND
Shorthand attribute associations
Public Class Methods
Set defaults as initial settings
# File lib/opulent/settings.rb, line 62 def initialize @settings = DEFAULTS.clone end
Public Instance Methods
Get an option at runtime
@param name [Symbol] Identifier for the option
# File lib/opulent/settings.rb, line 70 def [](name) @settings[name] end
Set a new option at runtime
@param name [Symbol] Identifier for the option @param value Option value to be set
# File lib/opulent/settings.rb, line 79 def []=(name, value) @settings[name] = value end
Remove an option at runtime
@param name [Symbol] Identifier for the option @param value Option value to be set
# File lib/opulent/settings.rb, line 88 def delete(name) @settings.delete name end
Update the engine settings with the required option changes
@param opts [Hash] Option extension hash
# File lib/opulent/settings.rb, line 96 def update_settings(opts) opts.each do |key, value| @settings[key] = value end end