Class: Skyhook::Configuration
- Inherits:
-
Object
- Object
- Skyhook::Configuration
- Defined in:
- lib/skyhook/configuration.rb
Direct Known Subclasses
Constant Summary collapse
- FORMATS =
%W(json xml vdf).map { |x| x.to_sym.freeze }
- BASE =
'api.steampowered.com'
Class Method Summary collapse
Class Method Details
.configure(options = {}) ⇒ Object
10 11 12 13 14 15 16 17 18 |
# File 'lib/skyhook/configuration.rb', line 10 def self.configure( = {} ) if [ :format ] FORMATS.include?( [ :format ] ) ? self.format = [ :format ] : raise(ArgumentError, "#{ [ :format ] } is not a valid format" ) else @@format = :json end @@api_key = [:api_key] if [:api_key] @@debug = [:debug] if [:debug] end |