Class: OCI::DataSafe::Models::SensitiveColumn

Inherits:
Object
  • Object
show all
Defined in:
lib/oci/data_safe/models/sensitive_column.rb

Overview

A sensitive column is a resource corresponding to a database column that is considered sensitive. It's a subresource of sensitive data model resource and is always associated with a sensitive data model. Note that referential relationships are also managed as part of sensitive columns.

Constant Summary collapse

LIFECYCLE_STATE_ENUM =
[
  LIFECYCLE_STATE_CREATING = 'CREATING'.freeze,
  LIFECYCLE_STATE_ACTIVE = 'ACTIVE'.freeze,
  LIFECYCLE_STATE_UPDATING = 'UPDATING'.freeze,
  LIFECYCLE_STATE_DELETING = 'DELETING'.freeze,
  LIFECYCLE_STATE_FAILED = 'FAILED'.freeze,
  LIFECYCLE_STATE_UNKNOWN_ENUM_VALUE = 'UNKNOWN_ENUM_VALUE'.freeze
].freeze
OBJECT_TYPE_ENUM =
[
  OBJECT_TYPE_TABLE = 'TABLE'.freeze,
  OBJECT_TYPE_EDITIONING_VIEW = 'EDITIONING_VIEW'.freeze,
  OBJECT_TYPE_UNKNOWN_ENUM_VALUE = 'UNKNOWN_ENUM_VALUE'.freeze
].freeze
STATUS_ENUM =
[
  STATUS_VALID = 'VALID'.freeze,
  STATUS_INVALID = 'INVALID'.freeze,
  STATUS_UNKNOWN_ENUM_VALUE = 'UNKNOWN_ENUM_VALUE'.freeze
].freeze
SOURCE_ENUM =
[
  SOURCE_MANUAL = 'MANUAL'.freeze,
  SOURCE_DISCOVERY = 'DISCOVERY'.freeze,
  SOURCE_UNKNOWN_ENUM_VALUE = 'UNKNOWN_ENUM_VALUE'.freeze
].freeze
RELATION_TYPE_ENUM =
[
  RELATION_TYPE_NONE = 'NONE'.freeze,
  RELATION_TYPE_APP_DEFINED = 'APP_DEFINED'.freeze,
  RELATION_TYPE_DB_DEFINED = 'DB_DEFINED'.freeze,
  RELATION_TYPE_UNKNOWN_ENUM_VALUE = 'UNKNOWN_ENUM_VALUE'.freeze
].freeze
CONFIDENCE_LEVEL_ENUM =
[
  CONFIDENCE_LEVEL_NONE = 'NONE'.freeze,
  CONFIDENCE_LEVEL_HIGH = 'HIGH'.freeze,
  CONFIDENCE_LEVEL_MEDIUM = 'MEDIUM'.freeze,
  CONFIDENCE_LEVEL_LOW = 'LOW'.freeze,
  CONFIDENCE_LEVEL_UNKNOWN_ENUM_VALUE = 'UNKNOWN_ENUM_VALUE'.freeze
].freeze

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(attributes = {}) ⇒ SensitiveColumn

Initializes the object

Parameters:

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

    Model attributes in the form of hash

Options Hash (attributes):

  • :key (String)

    The value to assign to the #key property

  • :sensitive_data_model_id (String)

    The value to assign to the #sensitive_data_model_id property

  • :time_created (DateTime)

    The value to assign to the #time_created property

  • :time_updated (DateTime)

    The value to assign to the #time_updated property

  • :lifecycle_state (String)

    The value to assign to the #lifecycle_state property

  • :lifecycle_details (String)

    The value to assign to the #lifecycle_details property

  • :app_name (String)

    The value to assign to the #app_name property

  • :schema_name (String)

    The value to assign to the #schema_name property

  • :object_name (String)

    The value to assign to the #object_name property

  • :column_name (String)

    The value to assign to the #column_name property

  • :object_type (String)

    The value to assign to the #object_type property

  • :data_type (String)

    The value to assign to the #data_type property

  • :status (String)

    The value to assign to the #status property

  • :sensitive_type_id (String)

    The value to assign to the #sensitive_type_id property

  • :source (String)

    The value to assign to the #source property

  • :parent_column_keys (Array<String>)

    The value to assign to the #parent_column_keys property

  • :relation_type (String)

    The value to assign to the #relation_type property

  • :estimated_data_value_count (Integer)

    The value to assign to the #estimated_data_value_count property

  • :confidence_level (String)

    The value to assign to the #confidence_level property

  • :confidence_level_details (Array<Object>)

    The value to assign to the #confidence_level_details property

  • :sample_data_values (Array<String>)

    The value to assign to the #sample_data_values property

  • :app_defined_child_column_keys (Array<String>)

    The value to assign to the #app_defined_child_column_keys property

  • :db_defined_child_column_keys (Array<String>)

    The value to assign to the #db_defined_child_column_keys property

  • :column_groups (Array<String>)

    The value to assign to the #column_groups property



272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
# File 'lib/oci/data_safe/models/sensitive_column.rb', line 272

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.key = attributes[:'key'] if attributes[:'key']

  self.sensitive_data_model_id = attributes[:'sensitiveDataModelId'] if attributes[:'sensitiveDataModelId']

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

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

  self.time_created = attributes[:'timeCreated'] if attributes[:'timeCreated']

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

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

  self.time_updated = attributes[:'timeUpdated'] if attributes[:'timeUpdated']

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

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

  self.lifecycle_state = attributes[:'lifecycleState'] if attributes[:'lifecycleState']

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

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

  self.lifecycle_details = attributes[:'lifecycleDetails'] if attributes[:'lifecycleDetails']

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

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

  self.app_name = attributes[:'appName'] if attributes[:'appName']

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

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

  self.schema_name = attributes[:'schemaName'] if attributes[:'schemaName']

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

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

  self.object_name = attributes[:'objectName'] if attributes[:'objectName']

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

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

  self.column_name = attributes[:'columnName'] if attributes[:'columnName']

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

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

  self.object_type = attributes[:'objectType'] if attributes[:'objectType']

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

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

  self.data_type = attributes[:'dataType'] if attributes[:'dataType']

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

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

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

  self.sensitive_type_id = attributes[:'sensitiveTypeId'] if attributes[:'sensitiveTypeId']

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

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

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

  self.parent_column_keys = attributes[:'parentColumnKeys'] if attributes[:'parentColumnKeys']

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

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

  self.relation_type = attributes[:'relationType'] if attributes[:'relationType']

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

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

  self.estimated_data_value_count = attributes[:'estimatedDataValueCount'] if attributes[:'estimatedDataValueCount']

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

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

  self.confidence_level = attributes[:'confidenceLevel'] if attributes[:'confidenceLevel']

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

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

  self.confidence_level_details = attributes[:'confidenceLevelDetails'] if attributes[:'confidenceLevelDetails']

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

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

  self.sample_data_values = attributes[:'sampleDataValues'] if attributes[:'sampleDataValues']

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

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

  self.app_defined_child_column_keys = attributes[:'appDefinedChildColumnKeys'] if attributes[:'appDefinedChildColumnKeys']

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

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

  self.db_defined_child_column_keys = attributes[:'dbDefinedChildColumnKeys'] if attributes[:'dbDefinedChildColumnKeys']

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

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

  self.column_groups = attributes[:'columnGroups'] if attributes[:'columnGroups']

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

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

Instance Attribute Details

#app_defined_child_column_keysArray<String>

Unique keys identifying the columns that are application-level (non-dictionary) children of the sensitive column.

Returns:

  • (Array<String>)


166
167
168
# File 'lib/oci/data_safe/models/sensitive_column.rb', line 166

def app_defined_child_column_keys
  @app_defined_child_column_keys
end

#app_nameString

[Required] The name of the application associated with the sensitive column. It's useful when the application name is different from the schema name. Otherwise, it can be ignored.

Returns:

  • (String)


89
90
91
# File 'lib/oci/data_safe/models/sensitive_column.rb', line 89

def app_name
  @app_name
end

#column_groupsArray<String>

The composite key groups to which the sensitive column belongs. If the column is part of a composite key, it's assigned a column group. It helps identify and manage referential relationships that involve composite keys.

Returns:

  • (Array<String>)


176
177
178
# File 'lib/oci/data_safe/models/sensitive_column.rb', line 176

def column_groups
  @column_groups
end

#column_nameString

[Required] The name of the sensitive column.

Returns:

  • (String)


101
102
103
# File 'lib/oci/data_safe/models/sensitive_column.rb', line 101

def column_name
  @column_name
end

#confidence_levelString

The confidence level of the sensitive column associated with the sensitive type. The confidence level of the discovered sensitive columns can be either HIGH, MEDIUM or LOW. The confidence level will be NONE for manually added sensitive columns.

Returns:

  • (String)


148
149
150
# File 'lib/oci/data_safe/models/sensitive_column.rb', line 148

def confidence_level
  @confidence_level
end

#confidence_level_detailsArray<Object>

List containing maps as values. Example: {\"Operations\": [ {\"CostCenter\": \"42\"} ] }

Returns:

  • (Array<Object>)


154
155
156
# File 'lib/oci/data_safe/models/sensitive_column.rb', line 154

def confidence_level_details
  @confidence_level_details
end

#data_typeString

[Required] The data type of the sensitive column.

Returns:

  • (String)


109
110
111
# File 'lib/oci/data_safe/models/sensitive_column.rb', line 109

def data_type
  @data_type
end

#db_defined_child_column_keysArray<String>

Unique keys identifying the columns that are database-level (dictionary-defined) children of the sensitive column.

Returns:

  • (Array<String>)


170
171
172
# File 'lib/oci/data_safe/models/sensitive_column.rb', line 170

def db_defined_child_column_keys
  @db_defined_child_column_keys
end

#estimated_data_value_countInteger

[Required] The estimated number of data values the column has in the associated database.

Returns:

  • (Integer)


141
142
143
# File 'lib/oci/data_safe/models/sensitive_column.rb', line 141

def estimated_data_value_count
  @estimated_data_value_count
end

#keyString

[Required] The unique key that identifies the sensitive column. It's numeric and unique within a sensitive data model.

Returns:

  • (String)


59
60
61
# File 'lib/oci/data_safe/models/sensitive_column.rb', line 59

def key
  @key
end

#lifecycle_detailsString

Details about the current state of the sensitive column.

Returns:

  • (String)


83
84
85
# File 'lib/oci/data_safe/models/sensitive_column.rb', line 83

def lifecycle_details
  @lifecycle_details
end

#lifecycle_stateString

[Required] The current state of the sensitive column.

Returns:

  • (String)


79
80
81
# File 'lib/oci/data_safe/models/sensitive_column.rb', line 79

def lifecycle_state
  @lifecycle_state
end

#object_nameString

[Required] The database object that contains the sensitive column.

Returns:

  • (String)


97
98
99
# File 'lib/oci/data_safe/models/sensitive_column.rb', line 97

def object_name
  @object_name
end

#object_typeString

[Required] The type of the database object that contains the sensitive column.

Returns:

  • (String)


105
106
107
# File 'lib/oci/data_safe/models/sensitive_column.rb', line 105

def object_type
  @object_type
end

#parent_column_keysArray<String>

Unique keys identifying the columns that are parents of the sensitive column. At present, it tracks a single parent only.

Returns:

  • (Array<String>)


130
131
132
# File 'lib/oci/data_safe/models/sensitive_column.rb', line 130

def parent_column_keys
  @parent_column_keys
end

#relation_typeString

[Required] The type of referential relationship the sensitive column has with its parent. NONE indicates that the sensitive column does not have a parent. DB_DEFINED indicates that the relationship is defined in the database dictionary. APP_DEFINED indicates that the relationship is defined at the application level and not in the database dictionary.

Returns:

  • (String)


137
138
139
# File 'lib/oci/data_safe/models/sensitive_column.rb', line 137

def relation_type
  @relation_type
end

#sample_data_valuesArray<String>

Original data values collected for the sensitive column from the associated database. Sample data helps review the column and ensure that it actually contains sensitive data. Note that sample data is retrieved by a data discovery job only if the isSampleDataCollectionEnabled attribute is set to true. At present, only one data value is collected per sensitive column.

Returns:

  • (Array<String>)


162
163
164
# File 'lib/oci/data_safe/models/sensitive_column.rb', line 162

def sample_data_values
  @sample_data_values
end

#schema_nameString

[Required] The database schema that contains the sensitive column.

Returns:

  • (String)


93
94
95
# File 'lib/oci/data_safe/models/sensitive_column.rb', line 93

def schema_name
  @schema_name
end

#sensitive_data_model_idString

[Required] The OCID of the sensitive data model that contains the sensitive column.

Returns:

  • (String)


63
64
65
# File 'lib/oci/data_safe/models/sensitive_column.rb', line 63

def sensitive_data_model_id
  @sensitive_data_model_id
end

#sensitive_type_idString

The OCID of the sensitive type associated with the sensitive column.

Returns:

  • (String)


120
121
122
# File 'lib/oci/data_safe/models/sensitive_column.rb', line 120

def sensitive_type_id
  @sensitive_type_id
end

#sourceString

[Required] The source of the sensitive column. DISCOVERY indicates that the column was added to the sensitive data model using a data discovery job. MANUAL indicates that the column was added manually.

Returns:

  • (String)


126
127
128
# File 'lib/oci/data_safe/models/sensitive_column.rb', line 126

def source
  @source
end

#statusString

[Required] The status of the sensitive column. VALID means the column is considered sensitive. INVALID means the column is not considered sensitive. Tracking invalid columns in a sensitive data model helps ensure that an incremental data discovery job does not identify these columns as sensitive again.

Returns:

  • (String)


116
117
118
# File 'lib/oci/data_safe/models/sensitive_column.rb', line 116

def status
  @status
end

#time_createdDateTime

[Required] The date and time, in the format defined by RFC3339, the sensitive column was created in the sensitive data model.

Returns:

  • (DateTime)


69
70
71
# File 'lib/oci/data_safe/models/sensitive_column.rb', line 69

def time_created
  @time_created
end

#time_updatedDateTime

[Required] The date and time, in the format defined by RFC3339, the sensitive column was last updated in the sensitive data model.

Returns:

  • (DateTime)


75
76
77
# File 'lib/oci/data_safe/models/sensitive_column.rb', line 75

def time_updated
  @time_updated
end

Class Method Details

.attribute_mapObject

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



179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
# File 'lib/oci/data_safe/models/sensitive_column.rb', line 179

def self.attribute_map
  {
    # rubocop:disable Style/SymbolLiteral
    'key': :'key',
    'sensitive_data_model_id': :'sensitiveDataModelId',
    'time_created': :'timeCreated',
    'time_updated': :'timeUpdated',
    'lifecycle_state': :'lifecycleState',
    'lifecycle_details': :'lifecycleDetails',
    'app_name': :'appName',
    'schema_name': :'schemaName',
    'object_name': :'objectName',
    'column_name': :'columnName',
    'object_type': :'objectType',
    'data_type': :'dataType',
    'status': :'status',
    'sensitive_type_id': :'sensitiveTypeId',
    'source': :'source',
    'parent_column_keys': :'parentColumnKeys',
    'relation_type': :'relationType',
    'estimated_data_value_count': :'estimatedDataValueCount',
    'confidence_level': :'confidenceLevel',
    'confidence_level_details': :'confidenceLevelDetails',
    'sample_data_values': :'sampleDataValues',
    'app_defined_child_column_keys': :'appDefinedChildColumnKeys',
    'db_defined_child_column_keys': :'dbDefinedChildColumnKeys',
    'column_groups': :'columnGroups'
    # rubocop:enable Style/SymbolLiteral
  }
end

.swagger_typesObject

Attribute type mapping.



211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
# File 'lib/oci/data_safe/models/sensitive_column.rb', line 211

def self.swagger_types
  {
    # rubocop:disable Style/SymbolLiteral
    'key': :'String',
    'sensitive_data_model_id': :'String',
    'time_created': :'DateTime',
    'time_updated': :'DateTime',
    'lifecycle_state': :'String',
    'lifecycle_details': :'String',
    'app_name': :'String',
    'schema_name': :'String',
    'object_name': :'String',
    'column_name': :'String',
    'object_type': :'String',
    'data_type': :'String',
    'status': :'String',
    'sensitive_type_id': :'String',
    'source': :'String',
    'parent_column_keys': :'Array<String>',
    'relation_type': :'String',
    'estimated_data_value_count': :'Integer',
    'confidence_level': :'String',
    'confidence_level_details': :'Array<Object>',
    'sample_data_values': :'Array<String>',
    'app_defined_child_column_keys': :'Array<String>',
    'db_defined_child_column_keys': :'Array<String>',
    'column_groups': :'Array<String>'
    # 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



496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
# File 'lib/oci/data_safe/models/sensitive_column.rb', line 496

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

  self.class == other.class &&
    key == other.key &&
    sensitive_data_model_id == other.sensitive_data_model_id &&
    time_created == other.time_created &&
    time_updated == other.time_updated &&
    lifecycle_state == other.lifecycle_state &&
    lifecycle_details == other.lifecycle_details &&
    app_name == other.app_name &&
    schema_name == other.schema_name &&
    object_name == other.object_name &&
    column_name == other.column_name &&
    object_type == other.object_type &&
    data_type == other.data_type &&
    status == other.status &&
    sensitive_type_id == other.sensitive_type_id &&
    source == other.source &&
    parent_column_keys == other.parent_column_keys &&
    relation_type == other.relation_type &&
    estimated_data_value_count == other.estimated_data_value_count &&
    confidence_level == other.confidence_level &&
    confidence_level_details == other.confidence_level_details &&
    sample_data_values == other.sample_data_values &&
    app_defined_child_column_keys == other.app_defined_child_column_keys &&
    db_defined_child_column_keys == other.db_defined_child_column_keys &&
    column_groups == other.column_groups
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



549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
# File 'lib/oci/data_safe/models/sensitive_column.rb', line 549

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


529
530
531
# File 'lib/oci/data_safe/models/sensitive_column.rb', line 529

def eql?(other)
  self == other
end

#hashFixnum

Calculates hash code according to all attributes.

Returns:

  • (Fixnum)

    Hash code



538
539
540
# File 'lib/oci/data_safe/models/sensitive_column.rb', line 538

def hash
  [key, sensitive_data_model_id, time_created, time_updated, lifecycle_state, lifecycle_details, app_name, schema_name, object_name, column_name, object_type, data_type, status, sensitive_type_id, source, parent_column_keys, relation_type, estimated_data_value_count, confidence_level, confidence_level_details, sample_data_values, app_defined_child_column_keys, db_defined_child_column_keys, column_groups].hash
end

#to_hashHash

Returns the object in the form of hash

Returns:

  • (Hash)

    Returns the object in the form of hash



582
583
584
585
586
587
588
589
590
591
# File 'lib/oci/data_safe/models/sensitive_column.rb', line 582

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



576
577
578
# File 'lib/oci/data_safe/models/sensitive_column.rb', line 576

def to_s
  to_hash.to_s
end