Class: OCI::LogAnalytics::Models::LogAnalyticsSource

Inherits:
Object
  • Object
show all
Defined in:
lib/oci/log_analytics/models/log_analytics_source.rb

Overview

LogAnalyticsSource

Constant Summary collapse

LIFECYCLE_STATE_ENUM =
[
  LIFECYCLE_STATE_ACTIVE = 'ACTIVE'.freeze,
  LIFECYCLE_STATE_DELETED = 'DELETED'.freeze,
  LIFECYCLE_STATE_UNKNOWN_ENUM_VALUE = 'UNKNOWN_ENUM_VALUE'.freeze
].freeze

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(attributes = {}) ⇒ LogAnalyticsSource

Initializes the object

Parameters:

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

    Model attributes in the form of hash

Options Hash (attributes):



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
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
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
525
526
527
528
529
530
531
532
533
534
535
536
537
# File 'lib/oci/log_analytics/models/log_analytics_source.rb', line 330

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

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

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

  self.association_count = attributes[:'associationCount'] if attributes[:'associationCount']

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

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

  self.association_entity = attributes[:'associationEntity'] if attributes[:'associationEntity']

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

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

  self.data_filter_definitions = attributes[:'dataFilterDefinitions'] if attributes[:'dataFilterDefinitions']

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

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

  self.database_credential = attributes[:'databaseCredential'] if attributes[:'databaseCredential']

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

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

  self.extended_field_definitions = attributes[:'extendedFieldDefinitions'] if attributes[:'extendedFieldDefinitions']

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

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

  self.is_for_cloud = attributes[:'isForCloud'] unless attributes[:'isForCloud'].nil?

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

  self.is_for_cloud = attributes[:'is_for_cloud'] unless attributes[:'is_for_cloud'].nil?

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

  self.metric_definitions = attributes[:'metricDefinitions'] if attributes[:'metricDefinitions']

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

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

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

  self.oob_parsers = attributes[:'oobParsers'] if attributes[:'oobParsers']

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

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

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

  self.pattern_count = attributes[:'patternCount'] if attributes[:'patternCount']

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

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

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

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

  self.display_name = attributes[:'displayName'] if attributes[:'displayName']

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

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

  self.edit_version = attributes[:'editVersion'] if attributes[:'editVersion']

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

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

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

  self.source_id = attributes[:'sourceId'] if attributes[:'sourceId']

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

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

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

  self.is_secure_content = attributes[:'isSecureContent'] unless attributes[:'isSecureContent'].nil?

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

  self.is_secure_content = attributes[:'is_secure_content'] unless attributes[:'is_secure_content'].nil?

  self.is_system = attributes[:'isSystem'] unless attributes[:'isSystem'].nil?

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

  self.is_system = attributes[:'is_system'] unless attributes[:'is_system'].nil?

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

  self.is_auto_association_enabled = attributes[:'isAutoAssociationEnabled'] unless attributes[:'isAutoAssociationEnabled'].nil?

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

  self.is_auto_association_enabled = attributes[:'is_auto_association_enabled'] unless attributes[:'is_auto_association_enabled'].nil?

  self.is_auto_association_override = attributes[:'isAutoAssociationOverride'] unless attributes[:'isAutoAssociationOverride'].nil?

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

  self.is_auto_association_override = attributes[:'is_auto_association_override'] unless attributes[:'is_auto_association_override'].nil?

  self.rule_id = attributes[:'ruleId'] if attributes[:'ruleId']

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

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

  self.type_name = attributes[:'typeName'] if attributes[:'typeName']

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

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

  self.type_display_name = attributes[:'typeDisplayName'] if attributes[:'typeDisplayName']

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

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

  self.warning_config = attributes[:'warningConfig'] if attributes[:'warningConfig']

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

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

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

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

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

  self.label_definitions = attributes[:'labelDefinitions'] if attributes[:'labelDefinitions']

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

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

  self.entity_types = attributes[:'entityTypes'] if attributes[:'entityTypes']

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

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

  self.is_timezone_override = attributes[:'isTimezoneOverride'] unless attributes[:'isTimezoneOverride'].nil?

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

  self.is_timezone_override = attributes[:'is_timezone_override'] unless attributes[:'is_timezone_override'].nil?

  self.user_parsers = attributes[:'userParsers'] if attributes[:'userParsers']

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

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

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

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

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

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

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

  self.source_properties = attributes[:'sourceProperties'] if attributes[:'sourceProperties']

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

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

  self.lifecycle_state = attributes[:'lifecycleState'] if attributes[:'lifecycleState']
  self.lifecycle_state = "ACTIVE" if lifecycle_state.nil? && !attributes.key?(:'lifecycleState') # rubocop:disable Style/StringLiterals

  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_state = "ACTIVE" if lifecycle_state.nil? && !attributes.key?(:'lifecycleState') && !attributes.key?(:'lifecycle_state') # rubocop:disable Style/StringLiterals
end

Instance Attribute Details

#association_countInteger

The association count.

Returns:

  • (Integer)


24
25
26
# File 'lib/oci/log_analytics/models/log_analytics_source.rb', line 24

def association_count
  @association_count
end

#association_entityArray<OCI::LogAnalytics::Models::LogAnalyticsAssociation>

The association entities.



28
29
30
# File 'lib/oci/log_analytics/models/log_analytics_source.rb', line 28

def association_entity
  @association_entity
end

#categoriesArray<OCI::LogAnalytics::Models::LogAnalyticsCategory>

An array of categories assigned to this source. The isSystem flag denotes if each category assignment is user-created or Oracle-defined.



173
174
175
# File 'lib/oci/log_analytics/models/log_analytics_source.rb', line 173

def categories
  @categories
end

#data_filter_definitionsArray<OCI::LogAnalytics::Models::LogAnalyticsSourceDataFilter>

The data filter definitions.



32
33
34
# File 'lib/oci/log_analytics/models/log_analytics_source.rb', line 32

def data_filter_definitions
  @data_filter_definitions
end

#database_credentialString

The database credential.

Returns:

  • (String)


36
37
38
# File 'lib/oci/log_analytics/models/log_analytics_source.rb', line 36

def database_credential
  @database_credential
end

#descriptionString

The source description.

Returns:

  • (String)


77
78
79
# File 'lib/oci/log_analytics/models/log_analytics_source.rb', line 77

def description
  @description
end

#display_nameString

The source display name.

Returns:

  • (String)


81
82
83
# File 'lib/oci/log_analytics/models/log_analytics_source.rb', line 81

def display_name
  @display_name
end

#edit_versionInteger

The source edit version.

Returns:

  • (Integer)


85
86
87
# File 'lib/oci/log_analytics/models/log_analytics_source.rb', line 85

def edit_version
  @edit_version
end

#endpointsArray<OCI::LogAnalytics::Models::LogAnalyticsEndpoint>

An array of REST API endpoints for log collection.



177
178
179
# File 'lib/oci/log_analytics/models/log_analytics_source.rb', line 177

def endpoints
  @endpoints
end

#entity_typesArray<OCI::LogAnalytics::Models::LogAnalyticsSourceEntityType>

The entity types.



150
151
152
# File 'lib/oci/log_analytics/models/log_analytics_source.rb', line 150

def entity_types
  @entity_types
end

#event_typesArray<OCI::LogAnalytics::Models::EventType>

An array of event types.



167
168
169
# File 'lib/oci/log_analytics/models/log_analytics_source.rb', line 167

def event_types
  @event_types
end

#extended_field_definitionsArray<OCI::LogAnalytics::Models::LogAnalyticsSourceExtendedFieldDefinition>

The extended field definitions.



40
41
42
# File 'lib/oci/log_analytics/models/log_analytics_source.rb', line 40

def extended_field_definitions
  @extended_field_definitions
end

#functionsArray<OCI::LogAnalytics::Models::LogAnalyticsSourceFunction>

The source functions.



89
90
91
# File 'lib/oci/log_analytics/models/log_analytics_source.rb', line 89

def functions
  @functions
end

#is_auto_association_enabledBOOLEAN

A flag indicating whether or not the source is marked for auto-association.

Returns:

  • (BOOLEAN)


117
118
119
# File 'lib/oci/log_analytics/models/log_analytics_source.rb', line 117

def is_auto_association_enabled
  @is_auto_association_enabled
end

#is_auto_association_overrideBOOLEAN

A flag indicating whether or not the auto-association state should be overridden.

Returns:

  • (BOOLEAN)


122
123
124
# File 'lib/oci/log_analytics/models/log_analytics_source.rb', line 122

def is_auto_association_override
  @is_auto_association_override
end

#is_for_cloudBOOLEAN

A flag indicating whether or not this is a cloud source.

Returns:

  • (BOOLEAN)


45
46
47
# File 'lib/oci/log_analytics/models/log_analytics_source.rb', line 45

def is_for_cloud
  @is_for_cloud
end

#is_secure_contentBOOLEAN

A flag indicating whether or not the source content is secure.

Returns:

  • (BOOLEAN)


102
103
104
# File 'lib/oci/log_analytics/models/log_analytics_source.rb', line 102

def is_secure_content
  @is_secure_content
end

#is_systemBOOLEAN

The system flag. A value of false denotes a custom, or user defined object. A value of true denotes a built in object.

Returns:

  • (BOOLEAN)


108
109
110
# File 'lib/oci/log_analytics/models/log_analytics_source.rb', line 108

def is_system
  @is_system
end

#is_timezone_overrideBOOLEAN

A flag indicating whether or not the source has a time zone override.

Returns:

  • (BOOLEAN)


155
156
157
# File 'lib/oci/log_analytics/models/log_analytics_source.rb', line 155

def is_timezone_override
  @is_timezone_override
end

#label_conditionsArray<OCI::LogAnalytics::Models::LogAnalyticsSourceLabelCondition>

The label alert conditions.



20
21
22
# File 'lib/oci/log_analytics/models/log_analytics_source.rb', line 20

def label_conditions
  @label_conditions
end

#label_definitionsArray<OCI::LogAnalytics::Models::LogAnalyticsLabelDefinition>

The labels used by the source.



146
147
148
# File 'lib/oci/log_analytics/models/log_analytics_source.rb', line 146

def label_definitions
  @label_definitions
end

#labelsArray<OCI::LogAnalytics::Models::LogAnalyticsLabelView>

The labels associated with the source.



49
50
51
# File 'lib/oci/log_analytics/models/log_analytics_source.rb', line 49

def labels
  @labels
end

#lifecycle_stateString

The current state of the Log Analytics source.

Returns:

  • (String)


186
187
188
# File 'lib/oci/log_analytics/models/log_analytics_source.rb', line 186

def lifecycle_state
  @lifecycle_state
end

#metadata_fieldsArray<OCI::LogAnalytics::Models::LogAnalyticsSourceMetadataField>

The source metadata fields.



142
143
144
# File 'lib/oci/log_analytics/models/log_analytics_source.rb', line 142

def 
  @metadata_fields
end

#metric_definitionsArray<OCI::LogAnalytics::Models::LogAnalyticsMetric>

The metric definitions.



53
54
55
# File 'lib/oci/log_analytics/models/log_analytics_source.rb', line 53

def metric_definitions
  @metric_definitions
end

#metricsArray<OCI::LogAnalytics::Models::LogAnalyticsSourceMetric>

The metric source map.



57
58
59
# File 'lib/oci/log_analytics/models/log_analytics_source.rb', line 57

def metrics
  @metrics
end

#nameString

The source internal name.

Returns:

  • (String)


97
98
99
# File 'lib/oci/log_analytics/models/log_analytics_source.rb', line 97

def name
  @name
end

#oob_parsersArray<OCI::LogAnalytics::Models::LogAnalyticsParser>

The built in parsers associated with source.



61
62
63
# File 'lib/oci/log_analytics/models/log_analytics_source.rb', line 61

def oob_parsers
  @oob_parsers
end

#parametersArray<OCI::LogAnalytics::Models::LogAnalyticsParameter>

The source parameters.



65
66
67
# File 'lib/oci/log_analytics/models/log_analytics_source.rb', line 65

def parameters
  @parameters
end

#parsersArray<OCI::LogAnalytics::Models::LogAnalyticsParser>

The list of parsers used by the source.



112
113
114
# File 'lib/oci/log_analytics/models/log_analytics_source.rb', line 112

def parsers
  @parsers
end

#pattern_countInteger

The pattern count.

Returns:

  • (Integer)


69
70
71
# File 'lib/oci/log_analytics/models/log_analytics_source.rb', line 69

def pattern_count
  @pattern_count
end

#patternsArray<OCI::LogAnalytics::Models::LogAnalyticsSourcePattern>

The source patterns.



73
74
75
# File 'lib/oci/log_analytics/models/log_analytics_source.rb', line 73

def patterns
  @patterns
end

#rule_idInteger

The rule unique identifier.

Returns:

  • (Integer)


126
127
128
# File 'lib/oci/log_analytics/models/log_analytics_source.rb', line 126

def rule_id
  @rule_id
end

#source_idInteger

The source unique identifier.

Returns:

  • (Integer)


93
94
95
# File 'lib/oci/log_analytics/models/log_analytics_source.rb', line 93

def source_id
  @source_id
end

#source_propertiesArray<OCI::LogAnalytics::Models::LogAnalyticsProperty>

A list of source properties.



181
182
183
# File 'lib/oci/log_analytics/models/log_analytics_source.rb', line 181

def source_properties
  @source_properties
end

#time_updatedDateTime

The last updated date.

Returns:

  • (DateTime)


163
164
165
# File 'lib/oci/log_analytics/models/log_analytics_source.rb', line 163

def time_updated
  @time_updated
end

#type_display_nameString

The source type name.

Returns:

  • (String)


134
135
136
# File 'lib/oci/log_analytics/models/log_analytics_source.rb', line 134

def type_display_name
  @type_display_name
end

#type_nameString

The source type internal name.

Returns:

  • (String)


130
131
132
# File 'lib/oci/log_analytics/models/log_analytics_source.rb', line 130

def type_name
  @type_name
end

#user_parsersArray<OCI::LogAnalytics::Models::LogAnalyticsParser>

An array of custom parsers.



159
160
161
# File 'lib/oci/log_analytics/models/log_analytics_source.rb', line 159

def user_parsers
  @user_parsers
end

#warning_configInteger

The source warning configuration.

Returns:

  • (Integer)


138
139
140
# File 'lib/oci/log_analytics/models/log_analytics_source.rb', line 138

def warning_config
  @warning_config
end

Class Method Details

.attribute_mapObject

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



189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
# File 'lib/oci/log_analytics/models/log_analytics_source.rb', line 189

def self.attribute_map
  {
    # rubocop:disable Style/SymbolLiteral
    'label_conditions': :'labelConditions',
    'association_count': :'associationCount',
    'association_entity': :'associationEntity',
    'data_filter_definitions': :'dataFilterDefinitions',
    'database_credential': :'databaseCredential',
    'extended_field_definitions': :'extendedFieldDefinitions',
    'is_for_cloud': :'isForCloud',
    'labels': :'labels',
    'metric_definitions': :'metricDefinitions',
    'metrics': :'metrics',
    'oob_parsers': :'oobParsers',
    'parameters': :'parameters',
    'pattern_count': :'patternCount',
    'patterns': :'patterns',
    'description': :'description',
    'display_name': :'displayName',
    'edit_version': :'editVersion',
    'functions': :'functions',
    'source_id': :'sourceId',
    'name': :'name',
    'is_secure_content': :'isSecureContent',
    'is_system': :'isSystem',
    'parsers': :'parsers',
    'is_auto_association_enabled': :'isAutoAssociationEnabled',
    'is_auto_association_override': :'isAutoAssociationOverride',
    'rule_id': :'ruleId',
    'type_name': :'typeName',
    'type_display_name': :'typeDisplayName',
    'warning_config': :'warningConfig',
    'metadata_fields': :'metadataFields',
    'label_definitions': :'labelDefinitions',
    'entity_types': :'entityTypes',
    'is_timezone_override': :'isTimezoneOverride',
    'user_parsers': :'userParsers',
    'time_updated': :'timeUpdated',
    'event_types': :'eventTypes',
    'categories': :'categories',
    'endpoints': :'endpoints',
    'source_properties': :'sourceProperties',
    'lifecycle_state': :'lifecycleState'
    # rubocop:enable Style/SymbolLiteral
  }
end

.swagger_typesObject

Attribute type mapping.



237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
# File 'lib/oci/log_analytics/models/log_analytics_source.rb', line 237

def self.swagger_types
  {
    # rubocop:disable Style/SymbolLiteral
    'label_conditions': :'Array<OCI::LogAnalytics::Models::LogAnalyticsSourceLabelCondition>',
    'association_count': :'Integer',
    'association_entity': :'Array<OCI::LogAnalytics::Models::LogAnalyticsAssociation>',
    'data_filter_definitions': :'Array<OCI::LogAnalytics::Models::LogAnalyticsSourceDataFilter>',
    'database_credential': :'String',
    'extended_field_definitions': :'Array<OCI::LogAnalytics::Models::LogAnalyticsSourceExtendedFieldDefinition>',
    'is_for_cloud': :'BOOLEAN',
    'labels': :'Array<OCI::LogAnalytics::Models::LogAnalyticsLabelView>',
    'metric_definitions': :'Array<OCI::LogAnalytics::Models::LogAnalyticsMetric>',
    'metrics': :'Array<OCI::LogAnalytics::Models::LogAnalyticsSourceMetric>',
    'oob_parsers': :'Array<OCI::LogAnalytics::Models::LogAnalyticsParser>',
    'parameters': :'Array<OCI::LogAnalytics::Models::LogAnalyticsParameter>',
    'pattern_count': :'Integer',
    'patterns': :'Array<OCI::LogAnalytics::Models::LogAnalyticsSourcePattern>',
    'description': :'String',
    'display_name': :'String',
    'edit_version': :'Integer',
    'functions': :'Array<OCI::LogAnalytics::Models::LogAnalyticsSourceFunction>',
    'source_id': :'Integer',
    'name': :'String',
    'is_secure_content': :'BOOLEAN',
    'is_system': :'BOOLEAN',
    'parsers': :'Array<OCI::LogAnalytics::Models::LogAnalyticsParser>',
    'is_auto_association_enabled': :'BOOLEAN',
    'is_auto_association_override': :'BOOLEAN',
    'rule_id': :'Integer',
    'type_name': :'String',
    'type_display_name': :'String',
    'warning_config': :'Integer',
    'metadata_fields': :'Array<OCI::LogAnalytics::Models::LogAnalyticsSourceMetadataField>',
    'label_definitions': :'Array<OCI::LogAnalytics::Models::LogAnalyticsLabelDefinition>',
    'entity_types': :'Array<OCI::LogAnalytics::Models::LogAnalyticsSourceEntityType>',
    'is_timezone_override': :'BOOLEAN',
    'user_parsers': :'Array<OCI::LogAnalytics::Models::LogAnalyticsParser>',
    'time_updated': :'DateTime',
    'event_types': :'Array<OCI::LogAnalytics::Models::EventType>',
    'categories': :'Array<OCI::LogAnalytics::Models::LogAnalyticsCategory>',
    'endpoints': :'Array<OCI::LogAnalytics::Models::LogAnalyticsEndpoint>',
    'source_properties': :'Array<OCI::LogAnalytics::Models::LogAnalyticsProperty>',
    'lifecycle_state': :'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



559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
# File 'lib/oci/log_analytics/models/log_analytics_source.rb', line 559

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

  self.class == other.class &&
    label_conditions == other.label_conditions &&
    association_count == other.association_count &&
    association_entity == other.association_entity &&
    data_filter_definitions == other.data_filter_definitions &&
    database_credential == other.database_credential &&
    extended_field_definitions == other.extended_field_definitions &&
    is_for_cloud == other.is_for_cloud &&
    labels == other.labels &&
    metric_definitions == other.metric_definitions &&
    metrics == other.metrics &&
    oob_parsers == other.oob_parsers &&
    parameters == other.parameters &&
    pattern_count == other.pattern_count &&
    patterns == other.patterns &&
    description == other.description &&
    display_name == other.display_name &&
    edit_version == other.edit_version &&
    functions == other.functions &&
    source_id == other.source_id &&
    name == other.name &&
    is_secure_content == other.is_secure_content &&
    is_system == other.is_system &&
    parsers == other.parsers &&
    is_auto_association_enabled == other.is_auto_association_enabled &&
    is_auto_association_override == other.is_auto_association_override &&
    rule_id == other.rule_id &&
    type_name == other.type_name &&
    type_display_name == other.type_display_name &&
    warning_config == other.warning_config &&
     == other. &&
    label_definitions == other.label_definitions &&
    entity_types == other.entity_types &&
    is_timezone_override == other.is_timezone_override &&
    user_parsers == other.user_parsers &&
    time_updated == other.time_updated &&
    event_types == other.event_types &&
    categories == other.categories &&
    endpoints == other.endpoints &&
    source_properties == other.source_properties &&
    lifecycle_state == other.lifecycle_state
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



628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
# File 'lib/oci/log_analytics/models/log_analytics_source.rb', line 628

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


608
609
610
# File 'lib/oci/log_analytics/models/log_analytics_source.rb', line 608

def eql?(other)
  self == other
end

#hashFixnum

Calculates hash code according to all attributes.

Returns:

  • (Fixnum)

    Hash code



617
618
619
# File 'lib/oci/log_analytics/models/log_analytics_source.rb', line 617

def hash
  [label_conditions, association_count, association_entity, data_filter_definitions, database_credential, extended_field_definitions, is_for_cloud, labels, metric_definitions, metrics, oob_parsers, parameters, pattern_count, patterns, description, display_name, edit_version, functions, source_id, name, is_secure_content, is_system, parsers, is_auto_association_enabled, is_auto_association_override, rule_id, type_name, type_display_name, warning_config, , label_definitions, entity_types, is_timezone_override, user_parsers, time_updated, event_types, categories, endpoints, source_properties, lifecycle_state].hash
end

#to_hashHash

Returns the object in the form of hash

Returns:

  • (Hash)

    Returns the object in the form of hash



661
662
663
664
665
666
667
668
669
670
# File 'lib/oci/log_analytics/models/log_analytics_source.rb', line 661

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



655
656
657
# File 'lib/oci/log_analytics/models/log_analytics_source.rb', line 655

def to_s
  to_hash.to_s
end