Class: LogaltyCertificateIssuanceApiCerty::GrantType
- Inherits:
-
Object
- Object
- LogaltyCertificateIssuanceApiCerty::GrantType
- Defined in:
- lib/logalty_certificate_issuance_api_certy/models/grant_type.rb
Overview
OAuth2 grant type. Fixed value ‘client_credentials`.
Constant Summary collapse
- GRANT_TYPE =
[ # TODO: Write general description for CLIENT_CREDENTIALS CLIENT_CREDENTIALS = 'client_credentials'.freeze ].freeze
Class Method Summary collapse
Class Method Details
.from_value(value, default_value = CLIENT_CREDENTIALS) ⇒ Object
20 21 22 23 24 |
# File 'lib/logalty_certificate_issuance_api_certy/models/grant_type.rb', line 20 def self.from_value(value, default_value = CLIENT_CREDENTIALS) return default_value if value.nil? default_value end |
.validate(value) ⇒ Object
14 15 16 17 18 |
# File 'lib/logalty_certificate_issuance_api_certy/models/grant_type.rb', line 14 def self.validate(value) return false if value.nil? GRANT_TYPE.include?(value) end |