module Doorkeeper::Request

Public Instance Methods

authorization_response_types() click to toggle source
# File lib/doorkeeper/request.rb, line 30
def authorization_response_types
  Doorkeeper.configuration.authorization_response_types
end
authorization_strategy(response_type) click to toggle source
# File lib/doorkeeper/request.rb, line 12
def authorization_strategy(response_type)
  get_strategy response_type, authorization_response_types
rescue NameError
  raise Errors::InvalidAuthorizationStrategy
end
get_strategy(grant_or_request_type, available) click to toggle source
# File lib/doorkeeper/request.rb, line 24
def get_strategy(grant_or_request_type, available)
  fail Errors::MissingRequestStrategy unless grant_or_request_type.present?
  fail NameError unless available.include?(grant_or_request_type.to_s)
  "Doorkeeper::Request::#{grant_or_request_type.to_s.camelize}".constantize
end
token_grant_types() click to toggle source
# File lib/doorkeeper/request.rb, line 35
def token_grant_types
  Doorkeeper.configuration.token_grant_types
end
token_strategy(grant_type) click to toggle source
# File lib/doorkeeper/request.rb, line 18
def token_strategy(grant_type)
  get_strategy grant_type, token_grant_types
rescue NameError
  raise Errors::InvalidTokenStrategy
end