Method: OCI::DataIntegration::Models::TaskFromSQLTaskDetails#initialize

Defined in:
lib/oci/data_integration/models/task_from_sql_task_details.rb

#initialize(attributes = {}) ⇒ TaskFromSQLTaskDetails

Initializes the object

Parameters:

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

    Model attributes in the form of hash

Options Hash (attributes):



110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
# File 'lib/oci/data_integration/models/task_from_sql_task_details.rb', line 110

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

  attributes['modelType'] = 'SQL_TASK'

  super(attributes)

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

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

  self.sql_script_type = attributes[:'sqlScriptType'] if attributes[:'sqlScriptType']

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

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

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