Class: DristiClient::Configuration
- Inherits:
-
Object
- Object
- DristiClient::Configuration
- Defined in:
- lib/dristi_client/configuration.rb
Constant Summary collapse
- ENDPOINT =
"https://dristiapp.com/api/errors"
Instance Attribute Summary collapse
-
#api_token ⇒ Object
Returns the value of attribute api_token.
-
#enabled ⇒ Object
Returns the value of attribute enabled.
-
#endpoint ⇒ Object
readonly
Returns the value of attribute endpoint.
-
#ignored_exceptions ⇒ Object
Returns the value of attribute ignored_exceptions.
Instance Method Summary collapse
-
#initialize ⇒ Configuration
constructor
A new instance of Configuration.
- #valid? ⇒ Boolean
Constructor Details
#initialize ⇒ Configuration
Returns a new instance of Configuration.
10 11 12 13 14 15 |
# File 'lib/dristi_client/configuration.rb', line 10 def initialize @api_token = nil @endpoint = ENDPOINT @enabled = true @ignored_exceptions = [] end |
Instance Attribute Details
#api_token ⇒ Object
Returns the value of attribute api_token.
7 8 9 |
# File 'lib/dristi_client/configuration.rb', line 7 def api_token @api_token end |
#enabled ⇒ Object
Returns the value of attribute enabled.
7 8 9 |
# File 'lib/dristi_client/configuration.rb', line 7 def enabled @enabled end |
#endpoint ⇒ Object (readonly)
Returns the value of attribute endpoint.
8 9 10 |
# File 'lib/dristi_client/configuration.rb', line 8 def endpoint @endpoint end |
#ignored_exceptions ⇒ Object
Returns the value of attribute ignored_exceptions.
7 8 9 |
# File 'lib/dristi_client/configuration.rb', line 7 def ignored_exceptions @ignored_exceptions end |
Instance Method Details
#valid? ⇒ Boolean
17 18 19 |
# File 'lib/dristi_client/configuration.rb', line 17 def valid? !api_token.nil? && !api_token.empty? end |