Class: OCI::ManagementAgent::Models::ManagementAgentSummary
- Inherits:
-
Object
- Object
- OCI::ManagementAgent::Models::ManagementAgentSummary
- Defined in:
- lib/oci/management_agent/models/management_agent_summary.rb
Overview
The summary of the Management Agent inventory including the associated plugins.
Constant Summary collapse
- PLATFORM_TYPE_ENUM =
[ PLATFORM_TYPE_LINUX = 'LINUX'.freeze, PLATFORM_TYPE_WINDOWS = 'WINDOWS'.freeze, PLATFORM_TYPE_UNKNOWN_ENUM_VALUE = 'UNKNOWN_ENUM_VALUE'.freeze ].freeze
- AVAILABILITY_STATUS_ENUM =
[ AVAILABILITY_STATUS_ACTIVE = 'ACTIVE'.freeze, AVAILABILITY_STATUS_SILENT = 'SILENT'.freeze, AVAILABILITY_STATUS_NOT_AVAILABLE = 'NOT_AVAILABLE'.freeze, AVAILABILITY_STATUS_UNKNOWN_ENUM_VALUE = 'UNKNOWN_ENUM_VALUE'.freeze ].freeze
- LIFECYCLE_STATE_ENUM =
[ LIFECYCLE_STATE_CREATING = 'CREATING'.freeze, LIFECYCLE_STATE_UPDATING = 'UPDATING'.freeze, LIFECYCLE_STATE_ACTIVE = 'ACTIVE'.freeze, LIFECYCLE_STATE_INACTIVE = 'INACTIVE'.freeze, LIFECYCLE_STATE_TERMINATED = 'TERMINATED'.freeze, LIFECYCLE_STATE_DELETING = 'DELETING'.freeze, LIFECYCLE_STATE_DELETED = 'DELETED'.freeze, LIFECYCLE_STATE_FAILED = 'FAILED'.freeze, LIFECYCLE_STATE_UNKNOWN_ENUM_VALUE = 'UNKNOWN_ENUM_VALUE'.freeze ].freeze
Instance Attribute Summary collapse
-
#availability_status ⇒ String
The current availability status of managementAgent.
-
#compartment_id ⇒ String
[Required] Compartment Identifier.
-
#defined_tags ⇒ Hash<String, Hash<String, Object>>
Defined tags for this resource.
-
#display_name ⇒ String
Management Agent Name.
-
#freeform_tags ⇒ Hash<String, String>
Simple key-value pair that is applied without any predefined name, type or scope.
-
#host ⇒ String
Management Agent host machine name.
-
#id ⇒ String
[Required] agent identifier.
-
#install_key_id ⇒ String
agent install key identifier.
-
#is_agent_auto_upgradable ⇒ BOOLEAN
true if the agent can be upgraded automatically; false if it must be upgraded manually.
-
#lifecycle_details ⇒ String
A message describing the current state in more detail.
-
#lifecycle_state ⇒ String
The current state of managementAgent.
-
#platform_name ⇒ String
Platform Name.
-
#platform_type ⇒ String
Platform Type.
-
#platform_version ⇒ String
Platform Version.
-
#plugin_list ⇒ Array<OCI::ManagementAgent::Models::ManagementAgentPluginDetails>
list of managementAgentPlugins associated with the agent.
-
#time_created ⇒ DateTime
The time the Management Agent was created.
-
#time_last_heartbeat ⇒ DateTime
The time the Management Agent has last recorded its heartbeat.
-
#version ⇒ String
[Required] Management Agent Version.
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 = {}) ⇒ ManagementAgentSummary
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 = {}) ⇒ ManagementAgentSummary
Initializes the object
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 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 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 283 284 285 286 287 288 289 |
# File 'lib/oci/management_agent/models/management_agent_summary.rb', line 188 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.id = attributes[:'id'] if attributes[:'id'] self.install_key_id = attributes[:'installKeyId'] if attributes[:'installKeyId'] raise 'You cannot provide both :installKeyId and :install_key_id' if attributes.key?(:'installKeyId') && attributes.key?(:'install_key_id') self.install_key_id = attributes[:'install_key_id'] if attributes[:'install_key_id'] 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.platform_type = attributes[:'platformType'] if attributes[:'platformType'] raise 'You cannot provide both :platformType and :platform_type' if attributes.key?(:'platformType') && attributes.key?(:'platform_type') self.platform_type = attributes[:'platform_type'] if attributes[:'platform_type'] self.platform_name = attributes[:'platformName'] if attributes[:'platformName'] raise 'You cannot provide both :platformName and :platform_name' if attributes.key?(:'platformName') && attributes.key?(:'platform_name') self.platform_name = attributes[:'platform_name'] if attributes[:'platform_name'] self.platform_version = attributes[:'platformVersion'] if attributes[:'platformVersion'] raise 'You cannot provide both :platformVersion and :platform_version' if attributes.key?(:'platformVersion') && attributes.key?(:'platform_version') self.platform_version = attributes[:'platform_version'] if attributes[:'platform_version'] self.version = attributes[:'version'] if attributes[:'version'] self.is_agent_auto_upgradable = attributes[:'isAgentAutoUpgradable'] unless attributes[:'isAgentAutoUpgradable'].nil? raise 'You cannot provide both :isAgentAutoUpgradable and :is_agent_auto_upgradable' if attributes.key?(:'isAgentAutoUpgradable') && attributes.key?(:'is_agent_auto_upgradable') self.is_agent_auto_upgradable = attributes[:'is_agent_auto_upgradable'] unless attributes[:'is_agent_auto_upgradable'].nil? 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.host = attributes[:'host'] if attributes[:'host'] self.plugin_list = attributes[:'pluginList'] if attributes[:'pluginList'] raise 'You cannot provide both :pluginList and :plugin_list' if attributes.key?(:'pluginList') && attributes.key?(:'plugin_list') self.plugin_list = attributes[:'plugin_list'] if attributes[:'plugin_list'] self.compartment_id = attributes[:'compartmentId'] if attributes[:'compartmentId'] raise 'You cannot provide both :compartmentId and :compartment_id' if attributes.key?(:'compartmentId') && attributes.key?(:'compartment_id') self.compartment_id = attributes[:'compartment_id'] if attributes[:'compartment_id'] self.time_last_heartbeat = attributes[:'timeLastHeartbeat'] if attributes[:'timeLastHeartbeat'] raise 'You cannot provide both :timeLastHeartbeat and :time_last_heartbeat' if attributes.key?(:'timeLastHeartbeat') && attributes.key?(:'time_last_heartbeat') self.time_last_heartbeat = attributes[:'time_last_heartbeat'] if attributes[:'time_last_heartbeat'] self.availability_status = attributes[:'availabilityStatus'] if attributes[:'availabilityStatus'] raise 'You cannot provide both :availabilityStatus and :availability_status' if attributes.key?(:'availabilityStatus') && attributes.key?(:'availability_status') self.availability_status = attributes[:'availability_status'] if attributes[:'availability_status'] 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. = attributes[:'freeformTags'] if attributes[:'freeformTags'] raise 'You cannot provide both :freeformTags and :freeform_tags' if attributes.key?(:'freeformTags') && attributes.key?(:'freeform_tags') self. = attributes[:'freeform_tags'] if attributes[:'freeform_tags'] self. = attributes[:'definedTags'] if attributes[:'definedTags'] raise 'You cannot provide both :definedTags and :defined_tags' if attributes.key?(:'definedTags') && attributes.key?(:'defined_tags') self. = attributes[:'defined_tags'] if attributes[:'defined_tags'] end |
Instance Attribute Details
#availability_status ⇒ String
The current availability status of managementAgent
90 91 92 |
# File 'lib/oci/management_agent/models/management_agent_summary.rb', line 90 def availability_status @availability_status end |
#compartment_id ⇒ String
[Required] Compartment Identifier
82 83 84 |
# File 'lib/oci/management_agent/models/management_agent_summary.rb', line 82 def compartment_id @compartment_id end |
#defined_tags ⇒ Hash<String, Hash<String, Object>>
Defined tags for this resource. Each key is predefined and scoped to a namespace. Example: ‘{"bar-key": "value"}`
110 111 112 |
# File 'lib/oci/management_agent/models/management_agent_summary.rb', line 110 def end |
#display_name ⇒ String
Management Agent Name
46 47 48 |
# File 'lib/oci/management_agent/models/management_agent_summary.rb', line 46 def display_name @display_name end |
#freeform_tags ⇒ Hash<String, String>
Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. Example: ‘"value"`
104 105 106 |
# File 'lib/oci/management_agent/models/management_agent_summary.rb', line 104 def end |
#host ⇒ String
Management Agent host machine name
74 75 76 |
# File 'lib/oci/management_agent/models/management_agent_summary.rb', line 74 def host @host end |
#id ⇒ String
[Required] agent identifier
38 39 40 |
# File 'lib/oci/management_agent/models/management_agent_summary.rb', line 38 def id @id end |
#install_key_id ⇒ String
agent install key identifier
42 43 44 |
# File 'lib/oci/management_agent/models/management_agent_summary.rb', line 42 def install_key_id @install_key_id end |
#is_agent_auto_upgradable ⇒ BOOLEAN
true if the agent can be upgraded automatically; false if it must be upgraded manually. true is currently unsupported.
66 67 68 |
# File 'lib/oci/management_agent/models/management_agent_summary.rb', line 66 def is_agent_auto_upgradable @is_agent_auto_upgradable end |
#lifecycle_details ⇒ String
A message describing the current state in more detail. For example, can be used to provide actionable information for a resource in Failed state.
98 99 100 |
# File 'lib/oci/management_agent/models/management_agent_summary.rb', line 98 def lifecycle_details @lifecycle_details end |
#lifecycle_state ⇒ String
The current state of managementAgent
94 95 96 |
# File 'lib/oci/management_agent/models/management_agent_summary.rb', line 94 def lifecycle_state @lifecycle_state end |
#platform_name ⇒ String
Platform Name
54 55 56 |
# File 'lib/oci/management_agent/models/management_agent_summary.rb', line 54 def platform_name @platform_name end |
#platform_type ⇒ String
Platform Type
50 51 52 |
# File 'lib/oci/management_agent/models/management_agent_summary.rb', line 50 def platform_type @platform_type end |
#platform_version ⇒ String
Platform Version
58 59 60 |
# File 'lib/oci/management_agent/models/management_agent_summary.rb', line 58 def platform_version @platform_version end |
#plugin_list ⇒ Array<OCI::ManagementAgent::Models::ManagementAgentPluginDetails>
list of managementAgentPlugins associated with the agent
78 79 80 |
# File 'lib/oci/management_agent/models/management_agent_summary.rb', line 78 def plugin_list @plugin_list end |
#time_created ⇒ DateTime
The time the Management Agent was created. An RFC3339 formatted datetime string
70 71 72 |
# File 'lib/oci/management_agent/models/management_agent_summary.rb', line 70 def time_created @time_created end |
#time_last_heartbeat ⇒ DateTime
The time the Management Agent has last recorded its heartbeat. An RFC3339 formatted datetime string
86 87 88 |
# File 'lib/oci/management_agent/models/management_agent_summary.rb', line 86 def time_last_heartbeat @time_last_heartbeat end |
#version ⇒ String
[Required] Management Agent Version
62 63 64 |
# File 'lib/oci/management_agent/models/management_agent_summary.rb', line 62 def version @version end |
Class Method Details
.attribute_map ⇒ Object
Attribute mapping from ruby-style variable name to JSON key.
113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 |
# File 'lib/oci/management_agent/models/management_agent_summary.rb', line 113 def self.attribute_map { # rubocop:disable Style/SymbolLiteral 'id': :'id', 'install_key_id': :'installKeyId', 'display_name': :'displayName', 'platform_type': :'platformType', 'platform_name': :'platformName', 'platform_version': :'platformVersion', 'version': :'version', 'is_agent_auto_upgradable': :'isAgentAutoUpgradable', 'time_created': :'timeCreated', 'host': :'host', 'plugin_list': :'pluginList', 'compartment_id': :'compartmentId', 'time_last_heartbeat': :'timeLastHeartbeat', 'availability_status': :'availabilityStatus', 'lifecycle_state': :'lifecycleState', 'lifecycle_details': :'lifecycleDetails', 'freeform_tags': :'freeformTags', 'defined_tags': :'definedTags' # rubocop:enable Style/SymbolLiteral } end |
.swagger_types ⇒ Object
Attribute type mapping.
139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 |
# File 'lib/oci/management_agent/models/management_agent_summary.rb', line 139 def self.swagger_types { # rubocop:disable Style/SymbolLiteral 'id': :'String', 'install_key_id': :'String', 'display_name': :'String', 'platform_type': :'String', 'platform_name': :'String', 'platform_version': :'String', 'version': :'String', 'is_agent_auto_upgradable': :'BOOLEAN', 'time_created': :'DateTime', 'host': :'String', 'plugin_list': :'Array<OCI::ManagementAgent::Models::ManagementAgentPluginDetails>', 'compartment_id': :'String', 'time_last_heartbeat': :'DateTime', 'availability_status': :'String', 'lifecycle_state': :'String', 'lifecycle_details': :'String', 'freeform_tags': :'Hash<String, String>', 'defined_tags': :'Hash<String, Hash<String, Object>>' # rubocop:enable Style/SymbolLiteral } end |
Instance Method Details
#==(other) ⇒ Object
Checks equality by comparing each attribute.
337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 |
# File 'lib/oci/management_agent/models/management_agent_summary.rb', line 337 def ==(other) return true if equal?(other) self.class == other.class && id == other.id && install_key_id == other.install_key_id && display_name == other.display_name && platform_type == other.platform_type && platform_name == other.platform_name && platform_version == other.platform_version && version == other.version && is_agent_auto_upgradable == other.is_agent_auto_upgradable && time_created == other.time_created && host == other.host && plugin_list == other.plugin_list && compartment_id == other.compartment_id && time_last_heartbeat == other.time_last_heartbeat && availability_status == other.availability_status && lifecycle_state == other.lifecycle_state && lifecycle_details == other.lifecycle_details && == other. && == other. end |
#build_from_hash(attributes) ⇒ Object
Builds the object from hash
384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 |
# File 'lib/oci/management_agent/models/management_agent_summary.rb', line 384 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
364 365 366 |
# File 'lib/oci/management_agent/models/management_agent_summary.rb', line 364 def eql?(other) self == other end |
#hash ⇒ Fixnum
Calculates hash code according to all attributes.
373 374 375 |
# File 'lib/oci/management_agent/models/management_agent_summary.rb', line 373 def hash [id, install_key_id, display_name, platform_type, platform_name, platform_version, version, is_agent_auto_upgradable, time_created, host, plugin_list, compartment_id, time_last_heartbeat, availability_status, lifecycle_state, lifecycle_details, , ].hash end |
#to_hash ⇒ Hash
Returns the object in the form of hash
417 418 419 420 421 422 423 424 425 426 |
# File 'lib/oci/management_agent/models/management_agent_summary.rb', line 417 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
411 412 413 |
# File 'lib/oci/management_agent/models/management_agent_summary.rb', line 411 def to_s to_hash.to_s end |