Class: OCI::IdentityDomains::Models::ExtensionGroupGroup

Inherits:
Object
  • Object
show all
Defined in:
lib/oci/identity_domains/models/extension_group_group.rb

Overview

Oracle Identity Cloud Service Group

Constant Summary collapse

CREATION_MECHANISM_ENUM =
[
  CREATION_MECHANISM_BULK = 'bulk'.freeze,
  CREATION_MECHANISM_API = 'api'.freeze,
  CREATION_MECHANISM_ADSYNC = 'adsync'.freeze,
  CREATION_MECHANISM_AUTHSYNC = 'authsync'.freeze,
  CREATION_MECHANISM_IDCSUI = 'idcsui'.freeze,
  CREATION_MECHANISM_IMPORT = 'import'.freeze,
  CREATION_MECHANISM_UNKNOWN_ENUM_VALUE = 'UNKNOWN_ENUM_VALUE'.freeze
].freeze

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(attributes = {}) ⇒ ExtensionGroupGroup

Initializes the object

Parameters:

  • attributes (Hash) (defaults to: {})

    Model attributes in the form of hash

Options Hash (attributes):



145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
# File 'lib/oci/identity_domains/models/extension_group_group.rb', line 145

def initialize(attributes = {})
  return unless attributes.is_a?(Hash)

  # convert string to symbol for hash key
  attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }

  self.description = attributes[:'description'] if attributes[:'description']

  self.creation_mechanism = attributes[:'creationMechanism'] if attributes[:'creationMechanism']

  raise 'You cannot provide both :creationMechanism and :creation_mechanism' if attributes.key?(:'creationMechanism') && attributes.key?(:'creation_mechanism')

  self.creation_mechanism = attributes[:'creation_mechanism'] if attributes[:'creation_mechanism']

  self.password_policy = attributes[:'passwordPolicy'] if attributes[:'passwordPolicy']

  raise 'You cannot provide both :passwordPolicy and :password_policy' if attributes.key?(:'passwordPolicy') && attributes.key?(:'password_policy')

  self.password_policy = attributes[:'password_policy'] if attributes[:'password_policy']

  self.synced_from_app = attributes[:'syncedFromApp'] if attributes[:'syncedFromApp']

  raise 'You cannot provide both :syncedFromApp and :synced_from_app' if attributes.key?(:'syncedFromApp') && attributes.key?(:'synced_from_app')

  self.synced_from_app = attributes[:'synced_from_app'] if attributes[:'synced_from_app']

  self.grants = attributes[:'grants'] if attributes[:'grants']

  self.owners = attributes[:'owners'] if attributes[:'owners']

  self.app_roles = attributes[:'appRoles'] if attributes[:'appRoles']

  raise 'You cannot provide both :appRoles and :app_roles' if attributes.key?(:'appRoles') && attributes.key?(:'app_roles')

  self.app_roles = attributes[:'app_roles'] if attributes[:'app_roles']
end

Instance Attribute Details

#app_rolesArray<OCI::IdentityDomains::Models::GroupExtAppRoles>

A list of appRoles that the user belongs to, either thorough direct membership, nested groups, or dynamically calculated

SCIM++ Properties: - caseExact: false - idcsCompositeKey: [value] - idcsSearchable: true - multiValued: true - mutability: readOnly - required: false - returned: request - type: complex - uniqueness: none



100
101
102
# File 'lib/oci/identity_domains/models/extension_group_group.rb', line 100

def app_roles
  @app_roles
end

#creation_mechanismString

Source from which this group got created.

SCIM++ Properties: - caseExact: false - idcsCsvAttributeNameMappings: [[defaultValue:import]] - idcsSearchable: true - multiValued: false - mutability: immutable - required: false - returned: request - type: string - uniqueness: none

Returns:

  • (String)


51
52
53
# File 'lib/oci/identity_domains/models/extension_group_group.rb', line 51

def creation_mechanism
  @creation_mechanism
end

#descriptionString

Group description

SCIM++ Properties: - caseExact: false - idcsCsvAttributeName: Description - idcsCsvAttributeNameMappings: [[columnHeaderName:Description]] - idcsSearchable: true - multiValued: false - mutability: readWrite - required: false - returned: default - type: string - uniqueness: none

Returns:

  • (String)


36
37
38
# File 'lib/oci/identity_domains/models/extension_group_group.rb', line 36

def description
  @description
end

#grantsArray<OCI::IdentityDomains::Models::GroupExtGrants>

Grants assigned to group

SCIM++ Properties: - idcsSearchable: true - multiValued: true - mutability: readOnly - required: false - returned: request - type: complex - uniqueness: none



70
71
72
# File 'lib/oci/identity_domains/models/extension_group_group.rb', line 70

def grants
  @grants
end

#ownersArray<OCI::IdentityDomains::Models::GroupExtOwners>

Group owners

SCIM++ Properties: - caseExact: false - idcsCompositeKey: [value, type] - idcsSearchable: true - multiValued: true - mutability: readWrite - required: false - returned: request - type: complex - uniqueness: none



85
86
87
# File 'lib/oci/identity_domains/models/extension_group_group.rb', line 85

def owners
  @owners
end

#password_policyOCI::IdentityDomains::Models::GroupExtPasswordPolicy



54
55
56
# File 'lib/oci/identity_domains/models/extension_group_group.rb', line 54

def password_policy
  @password_policy
end

#synced_from_appOCI::IdentityDomains::Models::GroupExtSyncedFromApp



57
58
59
# File 'lib/oci/identity_domains/models/extension_group_group.rb', line 57

def synced_from_app
  @synced_from_app
end

Class Method Details

.attribute_mapObject

Attribute mapping from ruby-style variable name to JSON key.



103
104
105
106
107
108
109
110
111
112
113
114
115
# File 'lib/oci/identity_domains/models/extension_group_group.rb', line 103

def self.attribute_map
  {
    # rubocop:disable Style/SymbolLiteral
    'description': :'description',
    'creation_mechanism': :'creationMechanism',
    'password_policy': :'passwordPolicy',
    'synced_from_app': :'syncedFromApp',
    'grants': :'grants',
    'owners': :'owners',
    'app_roles': :'appRoles'
    # rubocop:enable Style/SymbolLiteral
  }
end

.swagger_typesObject

Attribute type mapping.



118
119
120
121
122
123
124
125
126
127
128
129
130
# File 'lib/oci/identity_domains/models/extension_group_group.rb', line 118

def self.swagger_types
  {
    # rubocop:disable Style/SymbolLiteral
    'description': :'String',
    'creation_mechanism': :'String',
    'password_policy': :'OCI::IdentityDomains::Models::GroupExtPasswordPolicy',
    'synced_from_app': :'OCI::IdentityDomains::Models::GroupExtSyncedFromApp',
    'grants': :'Array<OCI::IdentityDomains::Models::GroupExtGrants>',
    'owners': :'Array<OCI::IdentityDomains::Models::GroupExtOwners>',
    'app_roles': :'Array<OCI::IdentityDomains::Models::GroupExtAppRoles>'
    # rubocop:enable Style/SymbolLiteral
  }
end

Instance Method Details

#==(other) ⇒ Object

Checks equality by comparing each attribute.

Parameters:

  • other (Object)

    the other object to be compared



202
203
204
205
206
207
208
209
210
211
212
213
# File 'lib/oci/identity_domains/models/extension_group_group.rb', line 202

def ==(other)
  return true if equal?(other)

  self.class == other.class &&
    description == other.description &&
    creation_mechanism == other.creation_mechanism &&
    password_policy == other.password_policy &&
    synced_from_app == other.synced_from_app &&
    grants == other.grants &&
    owners == other.owners &&
    app_roles == other.app_roles
end

#build_from_hash(attributes) ⇒ Object

Builds the object from hash

Parameters:

  • attributes (Hash)

    Model attributes in the form of hash

Returns:

  • (Object)

    Returns the model itself



238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
# File 'lib/oci/identity_domains/models/extension_group_group.rb', line 238

def build_from_hash(attributes)
  return nil unless attributes.is_a?(Hash)

  self.class.swagger_types.each_pair do |key, type|
    if type =~ /^Array<(.*)>/i
      # check to ensure the input is an array given that the the attribute
      # is documented as an array but the input is not
      if attributes[self.class.attribute_map[key]].is_a?(Array)
        public_method("#{key}=").call(
          attributes[self.class.attribute_map[key]]
            .map { |v| OCI::Internal::Util.convert_to_type(Regexp.last_match(1), v) }
        )
      end
    elsif !attributes[self.class.attribute_map[key]].nil?
      public_method("#{key}=").call(
        OCI::Internal::Util.convert_to_type(type, attributes[self.class.attribute_map[key]])
      )
    end
    # or else data not found in attributes(hash), not an issue as the data can be optional
  end

  self
end

#eql?(other) ⇒ Boolean

Parameters:

  • other (Object)

    the other object to be compared

Returns:

  • (Boolean)

See Also:

  • `==` method


218
219
220
# File 'lib/oci/identity_domains/models/extension_group_group.rb', line 218

def eql?(other)
  self == other
end

#hashFixnum

Calculates hash code according to all attributes.

Returns:

  • (Fixnum)

    Hash code



227
228
229
# File 'lib/oci/identity_domains/models/extension_group_group.rb', line 227

def hash
  [description, creation_mechanism, password_policy, synced_from_app, grants, owners, app_roles].hash
end

#to_hashHash

Returns the object in the form of hash

Returns:

  • (Hash)

    Returns the object in the form of hash



271
272
273
274
275
276
277
278
279
280
# File 'lib/oci/identity_domains/models/extension_group_group.rb', line 271

def to_hash
  hash = {}
  self.class.attribute_map.each_pair do |attr, param|
    value = public_method(attr).call
    next if value.nil? && !instance_variable_defined?("@#{attr}")

    hash[param] = _to_hash(value)
  end
  hash
end

#to_sString

Returns the string representation of the object

Returns:

  • (String)

    String presentation of the object



265
266
267
# File 'lib/oci/identity_domains/models/extension_group_group.rb', line 265

def to_s
  to_hash.to_s
end