Class: WorkOS::PatchConnection

Inherits:
Types::BaseModel
  • Object
show all
Defined in:
lib/workos/sso/patch_connection.rb

Constant Summary collapse

HASH_ATTRS =
{
  name: :name,
  external_id: :external_id,
  connection_type: :connection_type,
  attribute_maps: :attribute_maps,
  saml_options: :saml_options,
  oidc_options: :oidc_options
}.freeze

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(json) ⇒ PatchConnection

Returns a new instance of PatchConnection.



24
25
26
27
28
29
30
31
32
# File 'lib/workos/sso/patch_connection.rb', line 24

def initialize(json)
  hash = self.class.normalize(json)
  @name = hash[:name]
  @external_id = hash[:external_id]
  @connection_type = hash[:connection_type]
  @attribute_maps = hash[:attribute_maps] ? WorkOS::PatchConnectionAttributeMaps.new(hash[:attribute_maps]) : nil
  @saml_options = hash[:saml_options] ? WorkOS::PatchConnectionSAMLOptions.new(hash[:saml_options]) : nil
  @oidc_options = hash[:oidc_options] ? WorkOS::PatchConnectionOIDCOptions.new(hash[:oidc_options]) : nil
end

Instance Attribute Details

#attribute_mapsObject

Returns the value of attribute attribute_maps.



16
17
18
# File 'lib/workos/sso/patch_connection.rb', line 16

def attribute_maps
  @attribute_maps
end

#connection_typeObject

Returns the value of attribute connection_type.



16
17
18
# File 'lib/workos/sso/patch_connection.rb', line 16

def connection_type
  @connection_type
end

#external_idObject

Returns the value of attribute external_id.



16
17
18
# File 'lib/workos/sso/patch_connection.rb', line 16

def external_id
  @external_id
end

#nameObject

Returns the value of attribute name.



16
17
18
# File 'lib/workos/sso/patch_connection.rb', line 16

def name
  @name
end

#oidc_optionsObject

Returns the value of attribute oidc_options.



16
17
18
# File 'lib/workos/sso/patch_connection.rb', line 16

def oidc_options
  @oidc_options
end

#saml_optionsObject

Returns the value of attribute saml_options.



16
17
18
# File 'lib/workos/sso/patch_connection.rb', line 16

def saml_options
  @saml_options
end