Class: OCI::Core::Models::Vtap
- Inherits:
-
Object
- Object
- OCI::Core::Models::Vtap
- Defined in:
- lib/oci/core/models/vtap.rb
Overview
A virtual test access point (VTAP) provides a way to mirror all traffic from a designated source to a selected target in order to facilitate troubleshooting, security analysis, and data monitoring. A VTAP is functionally similar to a test access point (TAP) you might deploy in your on-premises network.
A *CaptureFilter* contains a set of *capture_filter_rule_details* governing what traffic a VTAP mirrors.
Constant Summary collapse
- LIFECYCLE_STATE_ENUM =
[ LIFECYCLE_STATE_PROVISIONING = 'PROVISIONING'.freeze, LIFECYCLE_STATE_AVAILABLE = 'AVAILABLE'.freeze, LIFECYCLE_STATE_UPDATING = 'UPDATING'.freeze, LIFECYCLE_STATE_TERMINATING = 'TERMINATING'.freeze, LIFECYCLE_STATE_TERMINATED = 'TERMINATED'.freeze, LIFECYCLE_STATE_UNKNOWN_ENUM_VALUE = 'UNKNOWN_ENUM_VALUE'.freeze ].freeze
- LIFECYCLE_STATE_DETAILS_ENUM =
[ LIFECYCLE_STATE_DETAILS_RUNNING = 'RUNNING'.freeze, LIFECYCLE_STATE_DETAILS_STOPPED = 'STOPPED'.freeze, LIFECYCLE_STATE_DETAILS_UNKNOWN_ENUM_VALUE = 'UNKNOWN_ENUM_VALUE'.freeze ].freeze
- ENCAPSULATION_PROTOCOL_ENUM =
[ ENCAPSULATION_PROTOCOL_VXLAN = 'VXLAN'.freeze, ENCAPSULATION_PROTOCOL_UNKNOWN_ENUM_VALUE = 'UNKNOWN_ENUM_VALUE'.freeze ].freeze
- SOURCE_TYPE_ENUM =
[ SOURCE_TYPE_VNIC = 'VNIC'.freeze, SOURCE_TYPE_SUBNET = 'SUBNET'.freeze, SOURCE_TYPE_LOAD_BALANCER = 'LOAD_BALANCER'.freeze, SOURCE_TYPE_DB_SYSTEM = 'DB_SYSTEM'.freeze, SOURCE_TYPE_EXADATA_VM_CLUSTER = 'EXADATA_VM_CLUSTER'.freeze, SOURCE_TYPE_AUTONOMOUS_DATA_WAREHOUSE = 'AUTONOMOUS_DATA_WAREHOUSE'.freeze, SOURCE_TYPE_UNKNOWN_ENUM_VALUE = 'UNKNOWN_ENUM_VALUE'.freeze ].freeze
- TRAFFIC_MODE_ENUM =
[ TRAFFIC_MODE_DEFAULT = 'DEFAULT'.freeze, TRAFFIC_MODE_PRIORITY = 'PRIORITY'.freeze, TRAFFIC_MODE_UNKNOWN_ENUM_VALUE = 'UNKNOWN_ENUM_VALUE'.freeze ].freeze
- TARGET_TYPE_ENUM =
[ TARGET_TYPE_VNIC = 'VNIC'.freeze, TARGET_TYPE_NETWORK_LOAD_BALANCER = 'NETWORK_LOAD_BALANCER'.freeze, TARGET_TYPE_IP_ADDRESS = 'IP_ADDRESS'.freeze, TARGET_TYPE_UNKNOWN_ENUM_VALUE = 'UNKNOWN_ENUM_VALUE'.freeze ].freeze
Instance Attribute Summary collapse
-
#capture_filter_id ⇒ String
**[Required]** The capture filter's Oracle ID ([OCID](docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm)).
-
#compartment_id ⇒ String
**[Required]** The [OCID](docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment containing the `Vtap` resource.
-
#defined_tags ⇒ Hash<String, Hash<String, Object>>
Defined tags for this resource.
-
#display_name ⇒ String
A user-friendly name.
-
#encapsulation_protocol ⇒ String
Defines an encapsulation header type for the VTAP's mirrored traffic.
-
#freeform_tags ⇒ Hash<String, String>
Free-form tags for this resource.
-
#id ⇒ String
**[Required]** The VTAP's Oracle ID ([OCID](docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm)).
-
#is_vtap_enabled ⇒ BOOLEAN
Used to start or stop a `Vtap` resource.
-
#lifecycle_state ⇒ String
**[Required]** The VTAP's administrative lifecycle state.
-
#lifecycle_state_details ⇒ String
The VTAP's current running state.
-
#max_packet_size ⇒ Integer
The maximum size of the packets to be included in the filter.
-
#source_id ⇒ String
**[Required]** The [OCID](docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the source point where packets are captured.
-
#source_private_endpoint_ip ⇒ String
The IP Address of the source private endpoint.
-
#source_private_endpoint_subnet_id ⇒ String
The [OCID](docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the subnet that source private endpoint belongs to.
-
#source_type ⇒ String
The source type for the VTAP.
-
#target_id ⇒ String
The [OCID](docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the destination resource where mirrored packets are sent.
-
#target_ip ⇒ String
The IP address of the destination resource where mirrored packets are sent.
-
#target_type ⇒ String
The target type for the VTAP.
-
#time_created ⇒ DateTime
The date and time the VTAP was created, in the format defined by [RFC3339](tools.ietf.org/html/rfc3339).
-
#traffic_mode ⇒ String
Used to control the priority of traffic.
-
#vcn_id ⇒ String
**[Required]** The [OCID](docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the VCN containing the `Vtap` resource.
-
#vxlan_network_identifier ⇒ Integer
The virtual extensible LAN (VXLAN) network identifier (or VXLAN segment ID) that uniquely identifies the VXLAN.
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 = {}) ⇒ Vtap
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 = {}) ⇒ Vtap
Initializes the object
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 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 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 |
# File 'lib/oci/core/models/vtap.rb', line 261 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.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.vcn_id = attributes[:'vcnId'] if attributes[:'vcnId'] raise 'You cannot provide both :vcnId and :vcn_id' if attributes.key?(:'vcnId') && attributes.key?(:'vcn_id') self.vcn_id = attributes[:'vcn_id'] if attributes[:'vcn_id'] 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'] 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. = 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.id = attributes[:'id'] if attributes[:'id'] 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_state_details = attributes[:'lifecycleStateDetails'] if attributes[:'lifecycleStateDetails'] raise 'You cannot provide both :lifecycleStateDetails and :lifecycle_state_details' if attributes.key?(:'lifecycleStateDetails') && attributes.key?(:'lifecycle_state_details') self.lifecycle_state_details = attributes[:'lifecycle_state_details'] if attributes[:'lifecycle_state_details'] 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.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.target_id = attributes[:'targetId'] if attributes[:'targetId'] raise 'You cannot provide both :targetId and :target_id' if attributes.key?(:'targetId') && attributes.key?(:'target_id') self.target_id = attributes[:'target_id'] if attributes[:'target_id'] self.target_ip = attributes[:'targetIp'] if attributes[:'targetIp'] raise 'You cannot provide both :targetIp and :target_ip' if attributes.key?(:'targetIp') && attributes.key?(:'target_ip') self.target_ip = attributes[:'target_ip'] if attributes[:'target_ip'] self.capture_filter_id = attributes[:'captureFilterId'] if attributes[:'captureFilterId'] raise 'You cannot provide both :captureFilterId and :capture_filter_id' if attributes.key?(:'captureFilterId') && attributes.key?(:'capture_filter_id') self.capture_filter_id = attributes[:'capture_filter_id'] if attributes[:'capture_filter_id'] self.encapsulation_protocol = attributes[:'encapsulationProtocol'] if attributes[:'encapsulationProtocol'] raise 'You cannot provide both :encapsulationProtocol and :encapsulation_protocol' if attributes.key?(:'encapsulationProtocol') && attributes.key?(:'encapsulation_protocol') self.encapsulation_protocol = attributes[:'encapsulation_protocol'] if attributes[:'encapsulation_protocol'] self.vxlan_network_identifier = attributes[:'vxlanNetworkIdentifier'] if attributes[:'vxlanNetworkIdentifier'] raise 'You cannot provide both :vxlanNetworkIdentifier and :vxlan_network_identifier' if attributes.key?(:'vxlanNetworkIdentifier') && attributes.key?(:'vxlan_network_identifier') self.vxlan_network_identifier = attributes[:'vxlan_network_identifier'] if attributes[:'vxlan_network_identifier'] self.is_vtap_enabled = attributes[:'isVtapEnabled'] unless attributes[:'isVtapEnabled'].nil? self.is_vtap_enabled = false if is_vtap_enabled.nil? && !attributes.key?(:'isVtapEnabled') # rubocop:disable Style/StringLiterals raise 'You cannot provide both :isVtapEnabled and :is_vtap_enabled' if attributes.key?(:'isVtapEnabled') && attributes.key?(:'is_vtap_enabled') self.is_vtap_enabled = attributes[:'is_vtap_enabled'] unless attributes[:'is_vtap_enabled'].nil? self.is_vtap_enabled = false if is_vtap_enabled.nil? && !attributes.key?(:'isVtapEnabled') && !attributes.key?(:'is_vtap_enabled') # rubocop:disable Style/StringLiterals self.source_type = attributes[:'sourceType'] if attributes[:'sourceType'] raise 'You cannot provide both :sourceType and :source_type' if attributes.key?(:'sourceType') && attributes.key?(:'source_type') self.source_type = attributes[:'source_type'] if attributes[:'source_type'] self.traffic_mode = attributes[:'trafficMode'] if attributes[:'trafficMode'] self.traffic_mode = "DEFAULT" if traffic_mode.nil? && !attributes.key?(:'trafficMode') # rubocop:disable Style/StringLiterals raise 'You cannot provide both :trafficMode and :traffic_mode' if attributes.key?(:'trafficMode') && attributes.key?(:'traffic_mode') self.traffic_mode = attributes[:'traffic_mode'] if attributes[:'traffic_mode'] self.traffic_mode = "DEFAULT" if traffic_mode.nil? && !attributes.key?(:'trafficMode') && !attributes.key?(:'traffic_mode') # rubocop:disable Style/StringLiterals self.max_packet_size = attributes[:'maxPacketSize'] if attributes[:'maxPacketSize'] raise 'You cannot provide both :maxPacketSize and :max_packet_size' if attributes.key?(:'maxPacketSize') && attributes.key?(:'max_packet_size') self.max_packet_size = attributes[:'max_packet_size'] if attributes[:'max_packet_size'] self.target_type = attributes[:'targetType'] if attributes[:'targetType'] raise 'You cannot provide both :targetType and :target_type' if attributes.key?(:'targetType') && attributes.key?(:'target_type') self.target_type = attributes[:'target_type'] if attributes[:'target_type'] self.source_private_endpoint_ip = attributes[:'sourcePrivateEndpointIp'] if attributes[:'sourcePrivateEndpointIp'] raise 'You cannot provide both :sourcePrivateEndpointIp and :source_private_endpoint_ip' if attributes.key?(:'sourcePrivateEndpointIp') && attributes.key?(:'source_private_endpoint_ip') self.source_private_endpoint_ip = attributes[:'source_private_endpoint_ip'] if attributes[:'source_private_endpoint_ip'] self.source_private_endpoint_subnet_id = attributes[:'sourcePrivateEndpointSubnetId'] if attributes[:'sourcePrivateEndpointSubnetId'] raise 'You cannot provide both :sourcePrivateEndpointSubnetId and :source_private_endpoint_subnet_id' if attributes.key?(:'sourcePrivateEndpointSubnetId') && attributes.key?(:'source_private_endpoint_subnet_id') self.source_private_endpoint_subnet_id = attributes[:'source_private_endpoint_subnet_id'] if attributes[:'source_private_endpoint_subnet_id'] end |
Instance Attribute Details
#capture_filter_id ⇒ String
**[Required]** The capture filter's Oracle ID ([OCID](docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm)).
125 126 127 |
# File 'lib/oci/core/models/vtap.rb', line 125 def capture_filter_id @capture_filter_id end |
#compartment_id ⇒ String
**[Required]** The [OCID](docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the compartment containing the `Vtap` resource.
60 61 62 |
# File 'lib/oci/core/models/vtap.rb', line 60 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. For more information, see [Resource Tags](docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm).
Example: `{"CostCenter": "42"}`
72 73 74 |
# File 'lib/oci/core/models/vtap.rb', line 72 def @defined_tags end |
#display_name ⇒ String
A user-friendly name. Does not have to be unique, and it's changeable. Avoid entering confidential information.
78 79 80 |
# File 'lib/oci/core/models/vtap.rb', line 78 def display_name @display_name end |
#encapsulation_protocol ⇒ String
Defines an encapsulation header type for the VTAP's mirrored traffic.
130 131 132 |
# File 'lib/oci/core/models/vtap.rb', line 130 def encapsulation_protocol @encapsulation_protocol end |
#freeform_tags ⇒ Hash<String, String>
Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see [Resource Tags](docs.cloud.oracle.com/iaas/Content/General/Concepts/resourcetags.htm).
Example: `"Finance"`
86 87 88 |
# File 'lib/oci/core/models/vtap.rb', line 86 def @freeform_tags end |
#id ⇒ String
**[Required]** The VTAP's Oracle ID ([OCID](docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm)).
90 91 92 |
# File 'lib/oci/core/models/vtap.rb', line 90 def id @id end |
#is_vtap_enabled ⇒ BOOLEAN
Used to start or stop a `Vtap` resource.
-
`TRUE` directs the VTAP to start mirroring traffic.
-
`FALSE` (Default) directs the VTAP to stop mirroring traffic.
143 144 145 |
# File 'lib/oci/core/models/vtap.rb', line 143 def is_vtap_enabled @is_vtap_enabled end |
#lifecycle_state ⇒ String
**[Required]** The VTAP's administrative lifecycle state.
94 95 96 |
# File 'lib/oci/core/models/vtap.rb', line 94 def lifecycle_state @lifecycle_state end |
#lifecycle_state_details ⇒ String
The VTAP's current running state.
98 99 100 |
# File 'lib/oci/core/models/vtap.rb', line 98 def lifecycle_state_details @lifecycle_state_details end |
#max_packet_size ⇒ Integer
The maximum size of the packets to be included in the filter.
156 157 158 |
# File 'lib/oci/core/models/vtap.rb', line 156 def max_packet_size @max_packet_size end |
#source_id ⇒ String
**[Required]** The [OCID](docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the source point where packets are captured.
110 111 112 |
# File 'lib/oci/core/models/vtap.rb', line 110 def source_id @source_id end |
#source_private_endpoint_ip ⇒ String
The IP Address of the source private endpoint.
166 167 168 |
# File 'lib/oci/core/models/vtap.rb', line 166 def source_private_endpoint_ip @source_private_endpoint_ip end |
#source_private_endpoint_subnet_id ⇒ String
The [OCID](docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the subnet that source private endpoint belongs to.
171 172 173 |
# File 'lib/oci/core/models/vtap.rb', line 171 def source_private_endpoint_subnet_id @source_private_endpoint_subnet_id end |
#source_type ⇒ String
The source type for the VTAP.
148 149 150 |
# File 'lib/oci/core/models/vtap.rb', line 148 def source_type @source_type end |
#target_id ⇒ String
The [OCID](docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the destination resource where mirrored packets are sent.
115 116 117 |
# File 'lib/oci/core/models/vtap.rb', line 115 def target_id @target_id end |
#target_ip ⇒ String
The IP address of the destination resource where mirrored packets are sent.
120 121 122 |
# File 'lib/oci/core/models/vtap.rb', line 120 def target_ip @target_ip end |
#target_type ⇒ String
The target type for the VTAP.
161 162 163 |
# File 'lib/oci/core/models/vtap.rb', line 161 def target_type @target_type end |
#time_created ⇒ DateTime
The date and time the VTAP was created, in the format defined by [RFC3339](tools.ietf.org/html/rfc3339).
Example: `2020-08-25T21:10:29.600Z`
105 106 107 |
# File 'lib/oci/core/models/vtap.rb', line 105 def time_created @time_created end |
#traffic_mode ⇒ String
Used to control the priority of traffic. It is an optional field. If it not passed, the value is DEFAULT
152 153 154 |
# File 'lib/oci/core/models/vtap.rb', line 152 def traffic_mode @traffic_mode end |
#vcn_id ⇒ String
**[Required]** The [OCID](docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the VCN containing the `Vtap` resource.
64 65 66 |
# File 'lib/oci/core/models/vtap.rb', line 64 def vcn_id @vcn_id end |
#vxlan_network_identifier ⇒ Integer
The virtual extensible LAN (VXLAN) network identifier (or VXLAN segment ID) that uniquely identifies the VXLAN.
135 136 137 |
# File 'lib/oci/core/models/vtap.rb', line 135 def vxlan_network_identifier @vxlan_network_identifier end |
Class Method Details
.attribute_map ⇒ Object
Attribute mapping from ruby-style variable name to JSON key.
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 |
# File 'lib/oci/core/models/vtap.rb', line 174 def self.attribute_map { # rubocop:disable Style/SymbolLiteral 'compartment_id': :'compartmentId', 'vcn_id': :'vcnId', 'defined_tags': :'definedTags', 'display_name': :'displayName', 'freeform_tags': :'freeformTags', 'id': :'id', 'lifecycle_state': :'lifecycleState', 'lifecycle_state_details': :'lifecycleStateDetails', 'time_created': :'timeCreated', 'source_id': :'sourceId', 'target_id': :'targetId', 'target_ip': :'targetIp', 'capture_filter_id': :'captureFilterId', 'encapsulation_protocol': :'encapsulationProtocol', 'vxlan_network_identifier': :'vxlanNetworkIdentifier', 'is_vtap_enabled': :'isVtapEnabled', 'source_type': :'sourceType', 'traffic_mode': :'trafficMode', 'max_packet_size': :'maxPacketSize', 'target_type': :'targetType', 'source_private_endpoint_ip': :'sourcePrivateEndpointIp', 'source_private_endpoint_subnet_id': :'sourcePrivateEndpointSubnetId' # rubocop:enable Style/SymbolLiteral } end |
.swagger_types ⇒ Object
Attribute type mapping.
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 |
# File 'lib/oci/core/models/vtap.rb', line 204 def self.swagger_types { # rubocop:disable Style/SymbolLiteral 'compartment_id': :'String', 'vcn_id': :'String', 'defined_tags': :'Hash<String, Hash<String, Object>>', 'display_name': :'String', 'freeform_tags': :'Hash<String, String>', 'id': :'String', 'lifecycle_state': :'String', 'lifecycle_state_details': :'String', 'time_created': :'DateTime', 'source_id': :'String', 'target_id': :'String', 'target_ip': :'String', 'capture_filter_id': :'String', 'encapsulation_protocol': :'String', 'vxlan_network_identifier': :'Integer', 'is_vtap_enabled': :'BOOLEAN', 'source_type': :'String', 'traffic_mode': :'String', 'max_packet_size': :'Integer', 'target_type': :'String', 'source_private_endpoint_ip': :'String', 'source_private_endpoint_subnet_id': :'String' # rubocop:enable Style/SymbolLiteral } end |
Instance Method Details
#==(other) ⇒ Object
Checks equality by comparing each attribute.
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 |
# File 'lib/oci/core/models/vtap.rb', line 485 def ==(other) return true if equal?(other) self.class == other.class && compartment_id == other.compartment_id && vcn_id == other.vcn_id && == other. && display_name == other.display_name && == other. && id == other.id && lifecycle_state == other.lifecycle_state && lifecycle_state_details == other.lifecycle_state_details && time_created == other.time_created && source_id == other.source_id && target_id == other.target_id && target_ip == other.target_ip && capture_filter_id == other.capture_filter_id && encapsulation_protocol == other.encapsulation_protocol && vxlan_network_identifier == other.vxlan_network_identifier && is_vtap_enabled == other.is_vtap_enabled && source_type == other.source_type && traffic_mode == other.traffic_mode && max_packet_size == other.max_packet_size && target_type == other.target_type && source_private_endpoint_ip == other.source_private_endpoint_ip && source_private_endpoint_subnet_id == other.source_private_endpoint_subnet_id end |
#build_from_hash(attributes) ⇒ Object
Builds the object from hash
536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 |
# File 'lib/oci/core/models/vtap.rb', line 536 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
516 517 518 |
# File 'lib/oci/core/models/vtap.rb', line 516 def eql?(other) self == other end |
#hash ⇒ Fixnum
Calculates hash code according to all attributes.
525 526 527 |
# File 'lib/oci/core/models/vtap.rb', line 525 def hash [compartment_id, vcn_id, , display_name, , id, lifecycle_state, lifecycle_state_details, time_created, source_id, target_id, target_ip, capture_filter_id, encapsulation_protocol, vxlan_network_identifier, is_vtap_enabled, source_type, traffic_mode, max_packet_size, target_type, source_private_endpoint_ip, source_private_endpoint_subnet_id].hash end |
#to_hash ⇒ Hash
Returns the object in the form of hash
569 570 571 572 573 574 575 576 577 578 |
# File 'lib/oci/core/models/vtap.rb', line 569 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
563 564 565 |
# File 'lib/oci/core/models/vtap.rb', line 563 def to_s to_hash.to_s end |