Class: GrapeDeviseAuth::Configuration
- Inherits:
-
Object
- Object
- GrapeDeviseAuth::Configuration
- Defined in:
- lib/grape_devise_auth/configuration.rb
Constant Summary collapse
- ACCESS_TOKEN_KEY =
'HTTP_ACCESS_TOKEN'
- EXPIRY_KEY =
'HTTP_EXPIRY'
- UID_KEY =
'HTTP_UID'
- CLIENT_KEY =
'HTTP_CLIENT'
- REQUEST_START =
'REQUEST_START'
- CURRENT_AUTH_HEADERS =
'CURRENT_AUTH_HEADERS'
Instance Attribute Summary collapse
-
#batch_request_buffer_throttle ⇒ Object
Returns the value of attribute batch_request_buffer_throttle.
-
#change_headers_on_each_request ⇒ Object
Returns the value of attribute change_headers_on_each_request.
-
#default_provider ⇒ Object
Returns the value of attribute default_provider.
-
#headers_names ⇒ Object
Returns the value of attribute headers_names.
-
#max_number_of_devices ⇒ Object
Returns the value of attribute max_number_of_devices.
-
#remove_tokens_after_password_reset ⇒ Object
Returns the value of attribute remove_tokens_after_password_reset.
-
#token_lifespan ⇒ Object
Returns the value of attribute token_lifespan.
Instance Method Summary collapse
-
#initialize ⇒ Configuration
constructor
A new instance of Configuration.
Constructor Details
#initialize ⇒ Configuration
Returns a new instance of Configuration.
18 19 20 21 22 23 24 25 26 27 28 29 30 |
# File 'lib/grape_devise_auth/configuration.rb', line 18 def initialize @batch_request_buffer_throttle = 2.weeks @change_headers_on_each_request = true @default_provider = 'email' @token_lifespan = 2.weeks @max_number_of_devices = 10 @headers_names = {:'access-token' => 'access-token', :'client' => 'client', :'expiry' => 'expiry', :'uid' => 'uid', :'token-type' => 'token-type' } @remove_tokens_after_password_reset = false end |
Instance Attribute Details
#batch_request_buffer_throttle ⇒ Object
Returns the value of attribute batch_request_buffer_throttle.
3 4 5 |
# File 'lib/grape_devise_auth/configuration.rb', line 3 def batch_request_buffer_throttle @batch_request_buffer_throttle end |
#change_headers_on_each_request ⇒ Object
Returns the value of attribute change_headers_on_each_request.
3 4 5 |
# File 'lib/grape_devise_auth/configuration.rb', line 3 def change_headers_on_each_request @change_headers_on_each_request end |
#default_provider ⇒ Object
Returns the value of attribute default_provider.
3 4 5 |
# File 'lib/grape_devise_auth/configuration.rb', line 3 def default_provider @default_provider end |
#headers_names ⇒ Object
Returns the value of attribute headers_names.
3 4 5 |
# File 'lib/grape_devise_auth/configuration.rb', line 3 def headers_names @headers_names end |
#max_number_of_devices ⇒ Object
Returns the value of attribute max_number_of_devices.
3 4 5 |
# File 'lib/grape_devise_auth/configuration.rb', line 3 def max_number_of_devices @max_number_of_devices end |
#remove_tokens_after_password_reset ⇒ Object
Returns the value of attribute remove_tokens_after_password_reset.
3 4 5 |
# File 'lib/grape_devise_auth/configuration.rb', line 3 def remove_tokens_after_password_reset @remove_tokens_after_password_reset end |
#token_lifespan ⇒ Object
Returns the value of attribute token_lifespan.
3 4 5 |
# File 'lib/grape_devise_auth/configuration.rb', line 3 def token_lifespan @token_lifespan end |