Class: OCI::DatabaseManagement::Models::SqlTuningSetSummary
- Inherits:
-
Object
- Object
- OCI::DatabaseManagement::Models::SqlTuningSetSummary
- Defined in:
- lib/oci/database_management/models/sql_tuning_set_summary.rb
Overview
The summary information of a SQL tuning set.
Constant Summary collapse
- STATUS_ENUM =
[ STATUS_DISABLED = 'DISABLED'.freeze, STATUS_RETRY_SCHEDULED = 'RETRY_SCHEDULED'.freeze, STATUS_SCHEDULED = 'SCHEDULED'.freeze, STATUS_BLOCKED = 'BLOCKED'.freeze, STATUS_RUNNING = 'RUNNING'.freeze, STATUS_COMPLETED = 'COMPLETED'.freeze, STATUS_BROKEN = 'BROKEN'.freeze, STATUS_FAILED = 'FAILED'.freeze, STATUS_REMOTE = 'REMOTE'.freeze, STATUS_RESOURCE_UNAVAILABLE = 'RESOURCE_UNAVAILABLE'.freeze, STATUS_SUCCEEDED = 'SUCCEEDED'.freeze, STATUS_CHAIN_STALLED = 'CHAIN_STALLED'.freeze, STATUS_UNKNOWN_ENUM_VALUE = 'UNKNOWN_ENUM_VALUE'.freeze ].freeze
Instance Attribute Summary collapse
-
#description ⇒ String
The description of the SQL tuning set.
-
#error_message ⇒ String
Latest execution error of the plsql that was submitted as a scheduler job.
-
#id ⇒ Integer
The unique Sql tuning set identifier.
-
#name ⇒ String
[Required] The name of the SQL tuning set.
-
#owner ⇒ String
[Required] The owner of the SQL tuning set.
-
#scheduled_job_name ⇒ String
Name of the Sql tuning set scheduler job.
-
#statement_counts ⇒ Integer
The number of SQL statements in the SQL tuning set.
-
#status ⇒ String
Current status of the Sql tuning set.
-
#time_created ⇒ DateTime
The created time of the Sql tuning set.
-
#time_last_modified ⇒ DateTime
Last modified time of the Sql tuning set.
Class Method Summary collapse
-
.attribute_map ⇒ Object
Attribute mapping from ruby-style variable name to JSON key.
-
.swagger_types ⇒ Object
Attribute type mapping.
Instance Method Summary collapse
-
#==(other) ⇒ Object
Checks equality by comparing each attribute.
-
#build_from_hash(attributes) ⇒ Object
Builds the object from hash.
- #eql?(other) ⇒ Boolean
-
#hash ⇒ Fixnum
Calculates hash code according to all attributes.
-
#initialize(attributes = {}) ⇒ SqlTuningSetSummary
constructor
Initializes the object.
-
#to_hash ⇒ Hash
Returns the object in the form of hash.
-
#to_s ⇒ String
Returns the string representation of the object.
Constructor Details
#initialize(attributes = {}) ⇒ SqlTuningSetSummary
Initializes the object
120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 |
# File 'lib/oci/database_management/models/sql_tuning_set_summary.rb', line 120 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.name = attributes[:'name'] if attributes[:'name'] self.owner = attributes[:'owner'] if attributes[:'owner'] self.description = attributes[:'description'] if attributes[:'description'] self.statement_counts = attributes[:'statementCounts'] if attributes[:'statementCounts'] raise 'You cannot provide both :statementCounts and :statement_counts' if attributes.key?(:'statementCounts') && attributes.key?(:'statement_counts') self.statement_counts = attributes[:'statement_counts'] if attributes[:'statement_counts'] self.id = attributes[:'id'] if attributes[:'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_last_modified = attributes[:'timeLastModified'] if attributes[:'timeLastModified'] raise 'You cannot provide both :timeLastModified and :time_last_modified' if attributes.key?(:'timeLastModified') && attributes.key?(:'time_last_modified') self.time_last_modified = attributes[:'time_last_modified'] if attributes[:'time_last_modified'] self.status = attributes[:'status'] if attributes[:'status'] self.scheduled_job_name = attributes[:'scheduledJobName'] if attributes[:'scheduledJobName'] raise 'You cannot provide both :scheduledJobName and :scheduled_job_name' if attributes.key?(:'scheduledJobName') && attributes.key?(:'scheduled_job_name') self.scheduled_job_name = attributes[:'scheduled_job_name'] if attributes[:'scheduled_job_name'] self. = attributes[:'errorMessage'] if attributes[:'errorMessage'] raise 'You cannot provide both :errorMessage and :error_message' if attributes.key?(:'errorMessage') && attributes.key?(:'error_message') self. = attributes[:'error_message'] if attributes[:'error_message'] end |
Instance Attribute Details
#description ⇒ String
The description of the SQL tuning set.
38 39 40 |
# File 'lib/oci/database_management/models/sql_tuning_set_summary.rb', line 38 def description @description end |
#error_message ⇒ String
Latest execution error of the plsql that was submitted as a scheduler job.
66 67 68 |
# File 'lib/oci/database_management/models/sql_tuning_set_summary.rb', line 66 def @error_message end |
#id ⇒ Integer
The unique Sql tuning set identifier. This is not OCID.
46 47 48 |
# File 'lib/oci/database_management/models/sql_tuning_set_summary.rb', line 46 def id @id end |
#name ⇒ String
[Required] The name of the SQL tuning set.
30 31 32 |
# File 'lib/oci/database_management/models/sql_tuning_set_summary.rb', line 30 def name @name end |
#owner ⇒ String
[Required] The owner of the SQL tuning set.
34 35 36 |
# File 'lib/oci/database_management/models/sql_tuning_set_summary.rb', line 34 def owner @owner end |
#scheduled_job_name ⇒ String
Name of the Sql tuning set scheduler job.
62 63 64 |
# File 'lib/oci/database_management/models/sql_tuning_set_summary.rb', line 62 def scheduled_job_name @scheduled_job_name end |
#statement_counts ⇒ Integer
The number of SQL statements in the SQL tuning set.
42 43 44 |
# File 'lib/oci/database_management/models/sql_tuning_set_summary.rb', line 42 def statement_counts @statement_counts end |
#status ⇒ String
Current status of the Sql tuning set.
58 59 60 |
# File 'lib/oci/database_management/models/sql_tuning_set_summary.rb', line 58 def status @status end |
#time_created ⇒ DateTime
The created time of the Sql tuning set.
50 51 52 |
# File 'lib/oci/database_management/models/sql_tuning_set_summary.rb', line 50 def time_created @time_created end |
#time_last_modified ⇒ DateTime
Last modified time of the Sql tuning set.
54 55 56 |
# File 'lib/oci/database_management/models/sql_tuning_set_summary.rb', line 54 def time_last_modified @time_last_modified end |
Class Method Details
.attribute_map ⇒ Object
Attribute mapping from ruby-style variable name to JSON key.
69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 |
# File 'lib/oci/database_management/models/sql_tuning_set_summary.rb', line 69 def self.attribute_map { # rubocop:disable Style/SymbolLiteral 'name': :'name', 'owner': :'owner', 'description': :'description', 'statement_counts': :'statementCounts', 'id': :'id', 'time_created': :'timeCreated', 'time_last_modified': :'timeLastModified', 'status': :'status', 'scheduled_job_name': :'scheduledJobName', 'error_message': :'errorMessage' # rubocop:enable Style/SymbolLiteral } end |
.swagger_types ⇒ Object
Attribute type mapping.
87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 |
# File 'lib/oci/database_management/models/sql_tuning_set_summary.rb', line 87 def self.swagger_types { # rubocop:disable Style/SymbolLiteral 'name': :'String', 'owner': :'String', 'description': :'String', 'statement_counts': :'Integer', 'id': :'Integer', 'time_created': :'DateTime', 'time_last_modified': :'DateTime', 'status': :'String', 'scheduled_job_name': :'String', 'error_message': :'String' # rubocop:enable Style/SymbolLiteral } end |
Instance Method Details
#==(other) ⇒ Object
Checks equality by comparing each attribute.
187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 |
# File 'lib/oci/database_management/models/sql_tuning_set_summary.rb', line 187 def ==(other) return true if equal?(other) self.class == other.class && name == other.name && owner == other.owner && description == other.description && statement_counts == other.statement_counts && id == other.id && time_created == other.time_created && time_last_modified == other.time_last_modified && status == other.status && scheduled_job_name == other.scheduled_job_name && == other. end |
#build_from_hash(attributes) ⇒ Object
Builds the object from hash
226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 |
# File 'lib/oci/database_management/models/sql_tuning_set_summary.rb', line 226 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
206 207 208 |
# File 'lib/oci/database_management/models/sql_tuning_set_summary.rb', line 206 def eql?(other) self == other end |
#hash ⇒ Fixnum
Calculates hash code according to all attributes.
215 216 217 |
# File 'lib/oci/database_management/models/sql_tuning_set_summary.rb', line 215 def hash [name, owner, description, statement_counts, id, time_created, time_last_modified, status, scheduled_job_name, ].hash end |
#to_hash ⇒ Hash
Returns the object in the form of hash
259 260 261 262 263 264 265 266 267 268 |
# File 'lib/oci/database_management/models/sql_tuning_set_summary.rb', line 259 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_s ⇒ String
Returns the string representation of the object
253 254 255 |
# File 'lib/oci/database_management/models/sql_tuning_set_summary.rb', line 253 def to_s to_hash.to_s end |