Class: JkoApi::Configuration
- Inherits:
-
Object
- Object
- JkoApi::Configuration
- Defined in:
- lib/jko_api/configuration.rb
Instance Attribute Summary collapse
-
#api_namespace ⇒ Object
Returns the value of attribute api_namespace.
-
#base_controller ⇒ Object
Returns the value of attribute base_controller.
-
#token_model ⇒ Object
Returns the value of attribute token_model.
-
#use_authentication ⇒ Object
Returns the value of attribute use_authentication.
Instance Method Summary collapse
- #authenticate? ⇒ Boolean
-
#initialize ⇒ Configuration
constructor
A new instance of Configuration.
- #strategy ⇒ Object
Constructor Details
#initialize ⇒ Configuration
Returns a new instance of Configuration.
6 7 8 9 10 11 |
# File 'lib/jko_api/configuration.rb', line 6 def initialize @base_controller = ApiApplicationController @api_namespace = 'api' @use_authentication = false @strategy = :bearer end |
Instance Attribute Details
#api_namespace ⇒ Object
Returns the value of attribute api_namespace.
4 5 6 |
# File 'lib/jko_api/configuration.rb', line 4 def api_namespace @api_namespace end |
#base_controller ⇒ Object
Returns the value of attribute base_controller.
4 5 6 |
# File 'lib/jko_api/configuration.rb', line 4 def base_controller @base_controller end |
#token_model ⇒ Object
Returns the value of attribute token_model.
4 5 6 |
# File 'lib/jko_api/configuration.rb', line 4 def token_model @token_model end |
#use_authentication ⇒ Object
Returns the value of attribute use_authentication.
4 5 6 |
# File 'lib/jko_api/configuration.rb', line 4 def use_authentication @use_authentication end |
Instance Method Details
#authenticate? ⇒ Boolean
13 14 15 |
# File 'lib/jko_api/configuration.rb', line 13 def authenticate? use_authentication end |
#strategy ⇒ Object
17 18 19 |
# File 'lib/jko_api/configuration.rb', line 17 def strategy @strategy.to_s.inquiry end |