Class: SDM::MFAConfig
- Inherits:
-
Object
- Object
- SDM::MFAConfig
- Defined in:
- lib/models/porcelain.rb
Instance Attribute Summary collapse
-
#enabled ⇒ Object
Indicates if MFA is enabled for the organization.
-
#okta ⇒ Object
Okta MFA configuration.
-
#provider ⇒ Object
The MFA provider, one of the MFAProvider constants.
Instance Method Summary collapse
-
#initialize(enabled: nil, okta: nil, provider: nil) ⇒ MFAConfig
constructor
A new instance of MFAConfig.
- #to_json(options = {}) ⇒ Object
Constructor Details
#initialize(enabled: nil, okta: nil, provider: nil) ⇒ MFAConfig
Returns a new instance of MFAConfig.
10724 10725 10726 10727 10728 10729 10730 10731 10732 |
# File 'lib/models/porcelain.rb', line 10724 def initialize( enabled: nil, okta: nil, provider: nil ) @enabled = enabled == nil ? false : enabled @okta = okta == nil ? nil : okta @provider = provider == nil ? "" : provider end |
Instance Attribute Details
#enabled ⇒ Object
Indicates if MFA is enabled for the organization.
10718 10719 10720 |
# File 'lib/models/porcelain.rb', line 10718 def enabled @enabled end |
#okta ⇒ Object
Okta MFA configuration. Future providers will be added to this wrapper.
10720 10721 10722 |
# File 'lib/models/porcelain.rb', line 10720 def okta @okta end |
#provider ⇒ Object
The MFA provider, one of the MFAProvider constants.
10722 10723 10724 |
# File 'lib/models/porcelain.rb', line 10722 def provider @provider end |
Instance Method Details
#to_json(options = {}) ⇒ Object
10734 10735 10736 10737 10738 10739 10740 |
# File 'lib/models/porcelain.rb', line 10734 def to_json( = {}) hash = {} self.instance_variables.each do |var| hash[var.id2name.delete_prefix("@")] = self.instance_variable_get var end hash.to_json end |