Class: Capcoauth::Config

Inherits:
Object
  • Object
show all
Defined in:
lib/capcoauth/config.rb

Defined Under Namespace

Classes: Builder

Constant Summary collapse

CAPCOAUTH_URL_DEFAULT =
'https://capcoauth.capco.com'.freeze
TOKEN_VERIFY_TTL_DEFAULT =
60.freeze

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#cache_storeObject

Returns the value of attribute cache_store.



49
50
51
# File 'lib/capcoauth/config.rb', line 49

def cache_store
  @cache_store
end

#capcoauth_urlObject

Returns the value of attribute capcoauth_url.



49
50
51
# File 'lib/capcoauth/config.rb', line 49

def capcoauth_url
  @capcoauth_url
end

#loggerObject

Returns the value of attribute logger.



49
50
51
# File 'lib/capcoauth/config.rb', line 49

def logger
  @logger
end

#perform_login_redirectsObject

Returns the value of attribute perform_login_redirects.



49
50
51
# File 'lib/capcoauth/config.rb', line 49

def 
  @perform_login_redirects
end

#require_userObject

Returns the value of attribute require_user.



49
50
51
# File 'lib/capcoauth/config.rb', line 49

def require_user
  @require_user
end

#send_notificationsObject

Returns the value of attribute send_notifications.



49
50
51
# File 'lib/capcoauth/config.rb', line 49

def send_notifications
  @send_notifications
end

#token_verify_ttlObject

Returns the value of attribute token_verify_ttl.



49
50
51
# File 'lib/capcoauth/config.rb', line 49

def token_verify_ttl
  @token_verify_ttl
end

#user_id_fieldObject

Returns the value of attribute user_id_field.



49
50
51
# File 'lib/capcoauth/config.rb', line 49

def user_id_field
  @user_id_field
end

#user_resolverObject

Returns the value of attribute user_resolver.



49
50
51
# File 'lib/capcoauth/config.rb', line 49

def user_resolver
  @user_resolver
end

#using_routesObject

Returns the value of attribute using_routes.



49
50
51
# File 'lib/capcoauth/config.rb', line 49

def using_routes
  @using_routes
end

Instance Method Details

#client_idObject



60
61
62
# File 'lib/capcoauth/config.rb', line 60

def client_id
  @client_id || raise(MissingRequiredOptionError, 'Missing required option `client_id`')
end

#client_id=(val = nil) ⇒ Object



63
64
65
66
# File 'lib/capcoauth/config.rb', line 63

def client_id= (val=nil)
  raise(MissingRequiredOptionError, '`client_id` cannot be set to nil') if val.nil?
  @client_id = val
end

#client_secretObject



67
68
69
# File 'lib/capcoauth/config.rb', line 67

def client_secret
  @client_secret || raise(MissingRequiredOptionError, 'Missing required option `client_secret`')
end

#client_secret=(val = nil) ⇒ Object



70
71
72
73
# File 'lib/capcoauth/config.rb', line 70

def client_secret= (val=nil)
  raise(MissingRequiredOptionError, '`client_secret` cannot be set to nil') if val.nil?
  @client_secret = val
end