Class: StashAPI::Options
- Inherits:
-
Object
- Object
- StashAPI::Options
- Defined in:
- lib/stash_api/options.rb
Constant Summary collapse
- @@default_options =
{}
Class Method Summary collapse
Class Method Details
.option(key, value = nil) ⇒ Object
9 10 11 12 13 14 15 16 17 18 |
# File 'lib/stash_api/options.rb', line 9 def self.option(key, value = nil) return @@default_options[key] unless value @@default_options[key] = value if key == :domain build_base_uri end value end |
.options ⇒ Object
5 6 7 |
# File 'lib/stash_api/options.rb', line 5 def self. @@default_options end |
.reset_defaults ⇒ Object
20 21 22 23 |
# File 'lib/stash_api/options.rb', line 20 def self.reset_defaults @@default_options = {} build_base_uri # reset the base_uri end |