Class: Dexcom::Configuration

Inherits:
Object
  • Object
show all
Defined in:
lib/dexcom/configuration.rb

Constant Summary collapse

DEFAULT_LOGGER =
nil
DEFAULT_LOGGER_LEVEL =
:info

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeConfiguration

Returns a new instance of Configuration.



10
11
12
13
14
15
16
# File 'lib/dexcom/configuration.rb', line 10

def initialize
  @username = nil
  @password = nil
  @outside_usa = nil
  @logger = DEFAULT_LOGGER
  @log_level = DEFAULT_LOGGER_LEVEL
end

Instance Attribute Details

#log_levelObject

Returns the value of attribute log_level.



5
6
7
# File 'lib/dexcom/configuration.rb', line 5

def log_level
  @log_level
end

#loggerObject

Returns the value of attribute logger.



5
6
7
# File 'lib/dexcom/configuration.rb', line 5

def logger
  @logger
end

#outside_usaObject

Returns the value of attribute outside_usa.



5
6
7
# File 'lib/dexcom/configuration.rb', line 5

def outside_usa
  @outside_usa
end

#passwordObject

Returns the value of attribute password.



5
6
7
# File 'lib/dexcom/configuration.rb', line 5

def password
  @password
end

#usernameObject

Returns the value of attribute username.



5
6
7
# File 'lib/dexcom/configuration.rb', line 5

def username
  @username
end

Instance Method Details

#base_urlObject



18
19
20
# File 'lib/dexcom/configuration.rb', line 18

def base_url
  outside_usa ? URL_BASE_OUTSIDE_USA : URL_BASE
end