Class: Hipflag::Client
- Inherits:
-
Object
- Object
- Hipflag::Client
- Includes:
- Flag
- Defined in:
- lib/hipflag/client.rb,
lib/hipflag/client/flag.rb
Defined Under Namespace
Modules: Flag
Constant Summary collapse
- NotFound =
Class.new(RuntimeError)
- ServerError =
Class.new(RuntimeError)
Class.new(RuntimeError)
- UnprocessableEntity =
Class.new(RuntimeError)
- BASE_URL =
'https://api.hipflag.com/v1/'
- TIMEOUT =
10
Instance Method Summary collapse
-
#initialize(options = {}) ⇒ Client
constructor
A new instance of Client.
Methods included from Flag
Constructor Details
#initialize(options = {}) ⇒ Client
Returns a new instance of Client.
17 18 19 20 21 22 23 |
# File 'lib/hipflag/client.rb', line 17 def initialize( = {}) Configurable::OPTIONS.each do |key| instance_variable_set(:"@#{key}", [key] || Hipflag.send(key)) end http_client.base_url = BASE_URL end |