Class: OCI::Jms::Models::RequestSummarizedManagedInstanceUsageDetails
- Inherits:
-
Object
- Object
- OCI::Jms::Models::RequestSummarizedManagedInstanceUsageDetails
- Defined in:
- lib/oci/jms/models/request_summarized_managed_instance_usage_details.rb
Overview
Parameters for filtering managed instances.
Constant Summary collapse
- MANAGED_INSTANCE_TYPE_ENUM =
[ MANAGED_INSTANCE_TYPE_ORACLE_MANAGEMENT_AGENT = 'ORACLE_MANAGEMENT_AGENT'.freeze ].freeze
- SORT_ORDER_ENUM =
[ SORT_ORDER_ASC = 'ASC'.freeze, SORT_ORDER_DESC = 'DESC'.freeze ].freeze
- SORT_BY_ENUM =
[ SORT_BY_TIME_FIRST_SEEN = 'timeFirstSeen'.freeze, SORT_BY_TIME_LAST_SEEN = 'timeLastSeen'.freeze, SORT_BY_APPROXIMATE_JRE_COUNT = 'approximateJreCount'.freeze, SORT_BY_APPROXIMATE_INSTALLATION_COUNT = 'approximateInstallationCount'.freeze, SORT_BY_APPROXIMATE_APPLICATION_COUNT = 'approximateApplicationCount'.freeze ].freeze
Instance Attribute Summary collapse
-
#application_id ⇒ String
The ID of the related application.
-
#fields ⇒ Array<OCI::Jms::Models::SummarizeManagedInstanceUsageFields>
Additional fields to include into the returned model on top of the required ones.
-
#installation_path ⇒ String
The installation path of the related installation.
-
#jre_distribution ⇒ String
The distribution of the related Java Runtime.
-
#jre_vendor ⇒ String
The vendor of the related Java Runtime.
-
#jre_version ⇒ String
The version of the related Java Runtime.
-
#managed_instance_id ⇒ String
The ID of the managed instance.
-
#managed_instance_type ⇒ String
type of the managed instance.
-
#sort_by ⇒ String
The field to sort managed instance views.
-
#sort_order ⇒ String
The sort order to use, either ‘asc’ or ‘desc’.
-
#time_end ⇒ DateTime
The end of the time period during which resources are searched (formatted according to RFC3339).
-
#time_start ⇒ DateTime
The start of the time period during which resources are searched (formatted according to RFC3339).
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 = {}) ⇒ RequestSummarizedManagedInstanceUsageDetails
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 = {}) ⇒ RequestSummarizedManagedInstanceUsageDetails
Initializes the object
142 143 144 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 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 209 210 211 212 213 214 215 216 217 218 219 |
# File 'lib/oci/jms/models/request_summarized_managed_instance_usage_details.rb', line 142 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.time_start = attributes[:'timeStart'] if attributes[:'timeStart'] raise 'You cannot provide both :timeStart and :time_start' if attributes.key?(:'timeStart') && attributes.key?(:'time_start') self.time_start = attributes[:'time_start'] if attributes[:'time_start'] self.time_end = attributes[:'timeEnd'] if attributes[:'timeEnd'] raise 'You cannot provide both :timeEnd and :time_end' if attributes.key?(:'timeEnd') && attributes.key?(:'time_end') self.time_end = attributes[:'time_end'] if attributes[:'time_end'] self.installation_path = attributes[:'installationPath'] if attributes[:'installationPath'] raise 'You cannot provide both :installationPath and :installation_path' if attributes.key?(:'installationPath') && attributes.key?(:'installation_path') self.installation_path = attributes[:'installation_path'] if attributes[:'installation_path'] self.jre_vendor = attributes[:'jreVendor'] if attributes[:'jreVendor'] raise 'You cannot provide both :jreVendor and :jre_vendor' if attributes.key?(:'jreVendor') && attributes.key?(:'jre_vendor') self.jre_vendor = attributes[:'jre_vendor'] if attributes[:'jre_vendor'] self.jre_distribution = attributes[:'jreDistribution'] if attributes[:'jreDistribution'] raise 'You cannot provide both :jreDistribution and :jre_distribution' if attributes.key?(:'jreDistribution') && attributes.key?(:'jre_distribution') self.jre_distribution = attributes[:'jre_distribution'] if attributes[:'jre_distribution'] self.jre_version = attributes[:'jreVersion'] if attributes[:'jreVersion'] raise 'You cannot provide both :jreVersion and :jre_version' if attributes.key?(:'jreVersion') && attributes.key?(:'jre_version') self.jre_version = attributes[:'jre_version'] if attributes[:'jre_version'] self.application_id = attributes[:'applicationId'] if attributes[:'applicationId'] raise 'You cannot provide both :applicationId and :application_id' if attributes.key?(:'applicationId') && attributes.key?(:'application_id') self.application_id = attributes[:'application_id'] if attributes[:'application_id'] self.managed_instance_id = attributes[:'managedInstanceId'] if attributes[:'managedInstanceId'] raise 'You cannot provide both :managedInstanceId and :managed_instance_id' if attributes.key?(:'managedInstanceId') && attributes.key?(:'managed_instance_id') self.managed_instance_id = attributes[:'managed_instance_id'] if attributes[:'managed_instance_id'] self.managed_instance_type = attributes[:'managedInstanceType'] if attributes[:'managedInstanceType'] raise 'You cannot provide both :managedInstanceType and :managed_instance_type' if attributes.key?(:'managedInstanceType') && attributes.key?(:'managed_instance_type') self.managed_instance_type = attributes[:'managed_instance_type'] if attributes[:'managed_instance_type'] self.sort_order = attributes[:'sortOrder'] if attributes[:'sortOrder'] self.sort_order = "ASC" if sort_order.nil? && !attributes.key?(:'sortOrder') # rubocop:disable Style/StringLiterals raise 'You cannot provide both :sortOrder and :sort_order' if attributes.key?(:'sortOrder') && attributes.key?(:'sort_order') self.sort_order = attributes[:'sort_order'] if attributes[:'sort_order'] self.sort_order = "ASC" if sort_order.nil? && !attributes.key?(:'sortOrder') && !attributes.key?(:'sort_order') # rubocop:disable Style/StringLiterals self.sort_by = attributes[:'sortBy'] if attributes[:'sortBy'] self.sort_by = "timeLastSeen" if sort_by.nil? && !attributes.key?(:'sortBy') # rubocop:disable Style/StringLiterals raise 'You cannot provide both :sortBy and :sort_by' if attributes.key?(:'sortBy') && attributes.key?(:'sort_by') self.sort_by = attributes[:'sort_by'] if attributes[:'sort_by'] self.sort_by = "timeLastSeen" if sort_by.nil? && !attributes.key?(:'sortBy') && !attributes.key?(:'sort_by') # rubocop:disable Style/StringLiterals self.fields = attributes[:'fields'] if attributes[:'fields'] end |
Instance Attribute Details
#application_id ⇒ String
The ID of the related application.
55 56 57 |
# File 'lib/oci/jms/models/request_summarized_managed_instance_usage_details.rb', line 55 def application_id @application_id end |
#fields ⇒ Array<OCI::Jms::Models::SummarizeManagedInstanceUsageFields>
Additional fields to include into the returned model on top of the required ones. This parameter can also include ‘approximateJreCount’, ‘approximateInstallationCount’ and ‘approximateApplicationCount’. For example ‘approximateJreCount,approximateInstallationCount’.
82 83 84 |
# File 'lib/oci/jms/models/request_summarized_managed_instance_usage_details.rb', line 82 def fields @fields end |
#installation_path ⇒ String
The installation path of the related installation.
39 40 41 |
# File 'lib/oci/jms/models/request_summarized_managed_instance_usage_details.rb', line 39 def installation_path @installation_path end |
#jre_distribution ⇒ String
The distribution of the related Java Runtime.
47 48 49 |
# File 'lib/oci/jms/models/request_summarized_managed_instance_usage_details.rb', line 47 def jre_distribution @jre_distribution end |
#jre_vendor ⇒ String
The vendor of the related Java Runtime.
43 44 45 |
# File 'lib/oci/jms/models/request_summarized_managed_instance_usage_details.rb', line 43 def jre_vendor @jre_vendor end |
#jre_version ⇒ String
The version of the related Java Runtime.
51 52 53 |
# File 'lib/oci/jms/models/request_summarized_managed_instance_usage_details.rb', line 51 def jre_version @jre_version end |
#managed_instance_id ⇒ String
The ID of the managed instance.
59 60 61 |
# File 'lib/oci/jms/models/request_summarized_managed_instance_usage_details.rb', line 59 def managed_instance_id @managed_instance_id end |
#managed_instance_type ⇒ String
type of the managed instance
63 64 65 |
# File 'lib/oci/jms/models/request_summarized_managed_instance_usage_details.rb', line 63 def managed_instance_type @managed_instance_type end |
#sort_by ⇒ String
The field to sort managed instance views. Only one sort order may be provided. Default order for timeFirstSeen, timeLastSeen, approximateJreCount_, approximateInstallationCount and approximateApplicationCount is descending. If no value is specified timeLastSeen is default.
75 76 77 |
# File 'lib/oci/jms/models/request_summarized_managed_instance_usage_details.rb', line 75 def sort_by @sort_by end |
#sort_order ⇒ String
The sort order to use, either ‘asc’ or ‘desc’.
67 68 69 |
# File 'lib/oci/jms/models/request_summarized_managed_instance_usage_details.rb', line 67 def sort_order @sort_order end |
#time_end ⇒ DateTime
The end of the time period during which resources are searched (formatted according to RFC3339). Defaults to current time.
35 36 37 |
# File 'lib/oci/jms/models/request_summarized_managed_instance_usage_details.rb', line 35 def time_end @time_end end |
#time_start ⇒ DateTime
The start of the time period during which resources are searched (formatted according to RFC3339). Defaults to current time minus seven days.
30 31 32 |
# File 'lib/oci/jms/models/request_summarized_managed_instance_usage_details.rb', line 30 def time_start @time_start end |
Class Method Details
.attribute_map ⇒ Object
Attribute mapping from ruby-style variable name to JSON key.
85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 |
# File 'lib/oci/jms/models/request_summarized_managed_instance_usage_details.rb', line 85 def self.attribute_map { # rubocop:disable Style/SymbolLiteral 'time_start': :'timeStart', 'time_end': :'timeEnd', 'installation_path': :'installationPath', 'jre_vendor': :'jreVendor', 'jre_distribution': :'jreDistribution', 'jre_version': :'jreVersion', 'application_id': :'applicationId', 'managed_instance_id': :'managedInstanceId', 'managed_instance_type': :'managedInstanceType', 'sort_order': :'sortOrder', 'sort_by': :'sortBy', 'fields': :'fields' # rubocop:enable Style/SymbolLiteral } end |
.swagger_types ⇒ Object
Attribute type mapping.
105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 |
# File 'lib/oci/jms/models/request_summarized_managed_instance_usage_details.rb', line 105 def self.swagger_types { # rubocop:disable Style/SymbolLiteral 'time_start': :'DateTime', 'time_end': :'DateTime', 'installation_path': :'String', 'jre_vendor': :'String', 'jre_distribution': :'String', 'jre_version': :'String', 'application_id': :'String', 'managed_instance_id': :'String', 'managed_instance_type': :'String', 'sort_order': :'String', 'sort_by': :'String', 'fields': :'Array<OCI::Jms::Models::SummarizeManagedInstanceUsageFields>' # rubocop:enable Style/SymbolLiteral } end |
Instance Method Details
#==(other) ⇒ Object
Checks equality by comparing each attribute.
252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 |
# File 'lib/oci/jms/models/request_summarized_managed_instance_usage_details.rb', line 252 def ==(other) return true if equal?(other) self.class == other.class && time_start == other.time_start && time_end == other.time_end && installation_path == other.installation_path && jre_vendor == other.jre_vendor && jre_distribution == other.jre_distribution && jre_version == other.jre_version && application_id == other.application_id && managed_instance_id == other.managed_instance_id && managed_instance_type == other.managed_instance_type && sort_order == other.sort_order && sort_by == other.sort_by && fields == other.fields end |
#build_from_hash(attributes) ⇒ Object
Builds the object from hash
293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 |
# File 'lib/oci/jms/models/request_summarized_managed_instance_usage_details.rb', line 293 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
273 274 275 |
# File 'lib/oci/jms/models/request_summarized_managed_instance_usage_details.rb', line 273 def eql?(other) self == other end |
#hash ⇒ Fixnum
Calculates hash code according to all attributes.
282 283 284 |
# File 'lib/oci/jms/models/request_summarized_managed_instance_usage_details.rb', line 282 def hash [time_start, time_end, installation_path, jre_vendor, jre_distribution, jre_version, application_id, managed_instance_id, managed_instance_type, sort_order, sort_by, fields].hash end |
#to_hash ⇒ Hash
Returns the object in the form of hash
326 327 328 329 330 331 332 333 334 335 |
# File 'lib/oci/jms/models/request_summarized_managed_instance_usage_details.rb', line 326 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
320 321 322 |
# File 'lib/oci/jms/models/request_summarized_managed_instance_usage_details.rb', line 320 def to_s to_hash.to_s end |