Class: PermitConfig
- Inherits:
-
Object
- Object
- PermitConfig
- Defined in:
- lib/config.rb
Instance Attribute Summary collapse
-
#api_url ⇒ Object
This class is used to configure the Permit SDK.
-
#context ⇒ Object
This class is used to configure the Permit SDK.
-
#debug ⇒ Object
This class is used to configure the Permit SDK.
-
#logger ⇒ Object
This class is used to configure the Permit SDK.
-
#pdp_url ⇒ Object
This class is used to configure the Permit SDK.
-
#token ⇒ Object
This class is used to configure the Permit SDK.
Instance Method Summary collapse
-
#initialize(token, api_url = DEFAULT_API_URL, pdp_url = DEFAULT_PDP_URL, context = nil, debug = false, logger = nil) ⇒ PermitConfig
constructor
A new instance of PermitConfig.
Constructor Details
#initialize(token, api_url = DEFAULT_API_URL, pdp_url = DEFAULT_PDP_URL, context = nil, debug = false, logger = nil) ⇒ PermitConfig
Returns a new instance of PermitConfig.
14 15 16 17 18 19 20 21 |
# File 'lib/config.rb', line 14 def initialize( token, api_url = DEFAULT_API_URL, pdp_url = DEFAULT_PDP_URL,context = nil, debug = false, logger = nil) @api_url = api_url @pdp_url = pdp_url @context = context @token = token @debug = debug @logger = logger end |
Instance Attribute Details
#api_url ⇒ Object
This class is used to configure the Permit SDK. It is used to set the base url of the PDP and the api key.
Example:
“‘ruby permit = Permit::Permit.new permit.config.base_url = ’pdp.permit.io’ permit.config “‘
12 13 14 |
# File 'lib/config.rb', line 12 def api_url @api_url end |
#context ⇒ Object
This class is used to configure the Permit SDK. It is used to set the base url of the PDP and the api key.
Example:
“‘ruby permit = Permit::Permit.new permit.config.base_url = ’pdp.permit.io’ permit.config “‘
12 13 14 |
# File 'lib/config.rb', line 12 def context @context end |
#debug ⇒ Object
This class is used to configure the Permit SDK. It is used to set the base url of the PDP and the api key.
Example:
“‘ruby permit = Permit::Permit.new permit.config.base_url = ’pdp.permit.io’ permit.config “‘
12 13 14 |
# File 'lib/config.rb', line 12 def debug @debug end |
#logger ⇒ Object
This class is used to configure the Permit SDK. It is used to set the base url of the PDP and the api key.
Example:
“‘ruby permit = Permit::Permit.new permit.config.base_url = ’pdp.permit.io’ permit.config “‘
12 13 14 |
# File 'lib/config.rb', line 12 def logger @logger end |
#pdp_url ⇒ Object
This class is used to configure the Permit SDK. It is used to set the base url of the PDP and the api key.
Example:
“‘ruby permit = Permit::Permit.new permit.config.base_url = ’pdp.permit.io’ permit.config “‘
12 13 14 |
# File 'lib/config.rb', line 12 def pdp_url @pdp_url end |
#token ⇒ Object
This class is used to configure the Permit SDK. It is used to set the base url of the PDP and the api key.
Example:
“‘ruby permit = Permit::Permit.new permit.config.base_url = ’pdp.permit.io’ permit.config “‘
12 13 14 |
# File 'lib/config.rb', line 12 def token @token end |