Class: OCI::Core::Models::VirtualCircuit
- Inherits:
-
Object
- Object
- OCI::Core::Models::VirtualCircuit
- Defined in:
- lib/oci/core/models/virtual_circuit.rb
Constant Summary collapse
- BGP_MANAGEMENT_ENUM =
[BGP_MANAGEMENT_CUSTOMER_MANAGED = 'CUSTOMER_MANAGED', BGP_MANAGEMENT_PROVIDER_MANAGED = 'PROVIDER_MANAGED', BGP_MANAGEMENT_ORACLE_MANAGED = 'ORACLE_MANAGED', BGP_MANAGEMENT_UNKNOWN_ENUM_VALUE = 'UNKNOWN_ENUM_VALUE']
- BGP_SESSION_STATE_ENUM =
[BGP_SESSION_STATE_UP = 'UP', BGP_SESSION_STATE_DOWN = 'DOWN', BGP_SESSION_STATE_UNKNOWN_ENUM_VALUE = 'UNKNOWN_ENUM_VALUE']
- LIFECYCLE_STATE_ENUM =
[LIFECYCLE_STATE_PENDING_PROVIDER = 'PENDING_PROVIDER', LIFECYCLE_STATE_VERIFYING = 'VERIFYING', LIFECYCLE_STATE_PROVISIONING = 'PROVISIONING', LIFECYCLE_STATE_PROVISIONED = 'PROVISIONED', LIFECYCLE_STATE_FAILED = 'FAILED', LIFECYCLE_STATE_INACTIVE = 'INACTIVE', LIFECYCLE_STATE_TERMINATING = 'TERMINATING', LIFECYCLE_STATE_TERMINATED = 'TERMINATED', LIFECYCLE_STATE_UNKNOWN_ENUM_VALUE = 'UNKNOWN_ENUM_VALUE']
- PROVIDER_STATE_ENUM =
[PROVIDER_STATE_ACTIVE = 'ACTIVE', PROVIDER_STATE_INACTIVE = 'INACTIVE', PROVIDER_STATE_UNKNOWN_ENUM_VALUE = 'UNKNOWN_ENUM_VALUE']
- SERVICE_TYPE_ENUM =
[SERVICE_TYPE_COLOCATED = 'COLOCATED', SERVICE_TYPE_LAYER2 = 'LAYER2', SERVICE_TYPE_LAYER3 = 'LAYER3', SERVICE_TYPE_UNKNOWN_ENUM_VALUE = 'UNKNOWN_ENUM_VALUE']
- TYPE_ENUM =
[TYPE_PUBLIC = 'PUBLIC', TYPE_PRIVATE = 'PRIVATE', TYPE_UNKNOWN_ENUM_VALUE = 'UNKNOWN_ENUM_VALUE']
Instance Attribute Summary collapse
-
#bandwidth_shape_name ⇒ String
The provisioned data rate of the connection.
-
#bgp_management ⇒ String
BGP management option.
-
#bgp_session_state ⇒ String
The state of the BGP session associated with the virtual circuit.
-
#compartment_id ⇒ String
The OCID of the compartment containing the virtual circuit.
-
#cross_connect_mappings ⇒ Array<OCI::Core::Models::CrossConnectMapping>
An array of mappings, each containing properties for a cross-connect or cross-connect group that is associated with this virtual circuit.
-
#customer_bgp_asn ⇒ Integer
The BGP ASN of the network at the other end of the BGP session from Oracle.
-
#display_name ⇒ String
A user-friendly name.
-
#gateway_id ⇒ String
The OCID of the customer’s Drg that this virtual circuit uses.
-
#id ⇒ String
The virtual circuit’s Oracle ID (OCID).
-
#lifecycle_state ⇒ String
The virtual circuit’s current state.
-
#oracle_bgp_asn ⇒ Integer
The Oracle BGP ASN.
-
#provider_name ⇒ String
Deprecated.
-
#provider_service_id ⇒ String
The OCID of the service offered by the provider (if the customer is connecting via a provider).
-
#provider_service_name ⇒ String
Deprecated.
-
#provider_state ⇒ String
The provider’s state in relation to this virtual circuit (if the customer is connecting via a provider).
-
#public_prefixes ⇒ Array<String>
For a public virtual circuit.
-
#reference_comment ⇒ String
Provider-supplied reference information about this virtual circuit (if the customer is connecting via a provider).
-
#region ⇒ String
The Oracle Cloud Infrastructure region where this virtual circuit is located.
-
#service_type ⇒ String
Provider service type.
-
#time_created ⇒ DateTime
The date and time the virtual circuit was created, in the format defined by RFC3339.
-
#type ⇒ String
Whether the virtual circuit supports private or public peering.
Instance Method Summary collapse
-
#==(other_object) ⇒ Object
Checks equality by comparing each attribute.
-
#build_from_hash(attributes) ⇒ Object
Builds the object from hash.
- #eql?(other_object) ⇒ Boolean
-
#hash ⇒ Fixnum
Calculates hash code according to all attributes.
-
#initialize(attributes = {}) ⇒ VirtualCircuit
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 = {}) ⇒ VirtualCircuit
Initializes the object
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 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 |
# File 'lib/oci/core/models/virtual_circuit.rb', line 169 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} if attributes[:'bandwidthShapeName'] self.bandwidth_shape_name = attributes[:'bandwidthShapeName'] end if attributes[:'bgpManagement'] self.bgp_management = attributes[:'bgpManagement'] end if attributes[:'bgpSessionState'] self.bgp_session_state = attributes[:'bgpSessionState'] end if attributes[:'compartmentId'] self.compartment_id = attributes[:'compartmentId'] end if attributes[:'crossConnectMappings'] self.cross_connect_mappings = attributes[:'crossConnectMappings'] end if attributes[:'customerBgpAsn'] self.customer_bgp_asn = attributes[:'customerBgpAsn'] end if attributes[:'displayName'] self.display_name = attributes[:'displayName'] end if attributes[:'gatewayId'] self.gateway_id = attributes[:'gatewayId'] end if attributes[:'id'] self.id = attributes[:'id'] end if attributes[:'lifecycleState'] self.lifecycle_state = attributes[:'lifecycleState'] end if attributes[:'oracleBgpAsn'] self.oracle_bgp_asn = attributes[:'oracleBgpAsn'] end if attributes[:'providerName'] self.provider_name = attributes[:'providerName'] end if attributes[:'providerServiceId'] self.provider_service_id = attributes[:'providerServiceId'] end if attributes[:'providerServiceName'] self.provider_service_name = attributes[:'providerServiceName'] end if attributes[:'providerState'] self.provider_state = attributes[:'providerState'] end if attributes[:'publicPrefixes'] self.public_prefixes = attributes[:'publicPrefixes'] end if attributes[:'referenceComment'] self.reference_comment = attributes[:'referenceComment'] end if attributes[:'region'] self.region = attributes[:'region'] end if attributes[:'serviceType'] self.service_type = attributes[:'serviceType'] end if attributes[:'timeCreated'] self.time_created = attributes[:'timeCreated'] end if attributes[:'type'] self.type = attributes[:'type'] end end |
Instance Attribute Details
#bandwidth_shape_name ⇒ String
The provisioned data rate of the connection.
47 48 49 |
# File 'lib/oci/core/models/virtual_circuit.rb', line 47 def bandwidth_shape_name @bandwidth_shape_name end |
#bgp_management ⇒ String
BGP management option.
52 53 54 |
# File 'lib/oci/core/models/virtual_circuit.rb', line 52 def bgp_management @bgp_management end |
#bgp_session_state ⇒ String
The state of the BGP session associated with the virtual circuit.
56 57 58 |
# File 'lib/oci/core/models/virtual_circuit.rb', line 56 def bgp_session_state @bgp_session_state end |
#compartment_id ⇒ String
The OCID of the compartment containing the virtual circuit.
60 61 62 |
# File 'lib/oci/core/models/virtual_circuit.rb', line 60 def compartment_id @compartment_id end |
#cross_connect_mappings ⇒ Array<OCI::Core::Models::CrossConnectMapping>
An array of mappings, each containing properties for a cross-connect or cross-connect group that is associated with this virtual circuit.
67 68 69 |
# File 'lib/oci/core/models/virtual_circuit.rb', line 67 def cross_connect_mappings @cross_connect_mappings end |
#customer_bgp_asn ⇒ Integer
The BGP ASN of the network at the other end of the BGP session from Oracle. If the session is between the customer’s edge router and Oracle, the value is the customer’s ASN. If the BGP session is between the provider’s edge router and Oracle, the value is the provider’s ASN.
76 77 78 |
# File 'lib/oci/core/models/virtual_circuit.rb', line 76 def customer_bgp_asn @customer_bgp_asn end |
#display_name ⇒ String
A user-friendly name. Does not have to be unique, and it’s changeable. Avoid entering confidential information.
82 83 84 |
# File 'lib/oci/core/models/virtual_circuit.rb', line 82 def display_name @display_name end |
#gateway_id ⇒ String
The OCID of the customer’s Drg that this virtual circuit uses. Applicable only to private virtual circuits.
88 89 90 |
# File 'lib/oci/core/models/virtual_circuit.rb', line 88 def gateway_id @gateway_id end |
#id ⇒ String
The virtual circuit’s Oracle ID (OCID).
92 93 94 |
# File 'lib/oci/core/models/virtual_circuit.rb', line 92 def id @id end |
#lifecycle_state ⇒ String
The virtual circuit’s current state. For information about the different states, see [FastConnect Overview](docs.us-phoenix-1.oraclecloud.com/Content/Network/Concepts/fastconnect.htm).
99 100 101 |
# File 'lib/oci/core/models/virtual_circuit.rb', line 99 def lifecycle_state @lifecycle_state end |
#oracle_bgp_asn ⇒ Integer
The Oracle BGP ASN.
103 104 105 |
# File 'lib/oci/core/models/virtual_circuit.rb', line 103 def oracle_bgp_asn @oracle_bgp_asn end |
#provider_name ⇒ String
Deprecated. Instead use ‘providerServiceId`.
108 109 110 |
# File 'lib/oci/core/models/virtual_circuit.rb', line 108 def provider_name @provider_name end |
#provider_service_id ⇒ String
The OCID of the service offered by the provider (if the customer is connecting via a provider).
113 114 115 |
# File 'lib/oci/core/models/virtual_circuit.rb', line 113 def provider_service_id @provider_service_id end |
#provider_service_name ⇒ String
Deprecated. Instead use ‘providerServiceId`.
118 119 120 |
# File 'lib/oci/core/models/virtual_circuit.rb', line 118 def provider_service_name @provider_service_name end |
#provider_state ⇒ String
The provider’s state in relation to this virtual circuit (if the customer is connecting via a provider). ACTIVE means the provider has provisioned the virtual circuit from their end. INACTIVE means the provider has not yet provisioned the virtual circuit, or has de-provisioned it.
127 128 129 |
# File 'lib/oci/core/models/virtual_circuit.rb', line 127 def provider_state @provider_state end |
#public_prefixes ⇒ Array<String>
For a public virtual circuit. The public IP prefixes (CIDRs) the customer wants to advertise across the connection. Each prefix must be /24 or less specific.
133 134 135 |
# File 'lib/oci/core/models/virtual_circuit.rb', line 133 def public_prefixes @public_prefixes end |
#reference_comment ⇒ String
Provider-supplied reference information about this virtual circuit (if the customer is connecting via a provider).
139 140 141 |
# File 'lib/oci/core/models/virtual_circuit.rb', line 139 def reference_comment @reference_comment end |
#region ⇒ String
The Oracle Cloud Infrastructure region where this virtual circuit is located.
145 146 147 |
# File 'lib/oci/core/models/virtual_circuit.rb', line 145 def region @region end |
#service_type ⇒ String
Provider service type.
150 151 152 |
# File 'lib/oci/core/models/virtual_circuit.rb', line 150 def service_type @service_type end |
#time_created ⇒ DateTime
The date and time the virtual circuit was created, in the format defined by RFC3339.
Example: ‘2016-08-25T21:10:29.600Z`
158 159 160 |
# File 'lib/oci/core/models/virtual_circuit.rb', line 158 def time_created @time_created end |
#type ⇒ String
Whether the virtual circuit supports private or public peering. For more information, see [FastConnect Overview](docs.us-phoenix-1.oraclecloud.com/Content/Network/Concepts/fastconnect.htm).
164 165 166 |
# File 'lib/oci/core/models/virtual_circuit.rb', line 164 def type @type end |
Instance Method Details
#==(other_object) ⇒ Object
Checks equality by comparing each attribute.
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 |
# File 'lib/oci/core/models/virtual_circuit.rb', line 323 def ==(other_object) return true if self.equal?(other_object) self.class == other_object.class && bandwidth_shape_name == other_object.bandwidth_shape_name && bgp_management == other_object.bgp_management && bgp_session_state == other_object.bgp_session_state && compartment_id == other_object.compartment_id && cross_connect_mappings == other_object.cross_connect_mappings && customer_bgp_asn == other_object.customer_bgp_asn && display_name == other_object.display_name && gateway_id == other_object.gateway_id && id == other_object.id && lifecycle_state == other_object.lifecycle_state && oracle_bgp_asn == other_object.oracle_bgp_asn && provider_name == other_object.provider_name && provider_service_id == other_object.provider_service_id && provider_service_name == other_object.provider_service_name && provider_state == other_object.provider_state && public_prefixes == other_object.public_prefixes && reference_comment == other_object.reference_comment && region == other_object.region && service_type == other_object.service_type && time_created == other_object.time_created && type == other_object.type end |
#build_from_hash(attributes) ⇒ Object
Builds the object from hash
364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 |
# File 'lib/oci/core/models/virtual_circuit.rb', line 364 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) self.public_method("#{key}=").call(attributes[self.class.attribute_map[key]].map{ |v| OCI::Internal::Util.convert_to_type($1, v) } ) end elsif !attributes[self.class.attribute_map[key]].nil? self.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_object) ⇒ Boolean
351 352 353 |
# File 'lib/oci/core/models/virtual_circuit.rb', line 351 def eql?(other_object) self == other_object end |
#hash ⇒ Fixnum
Calculates hash code according to all attributes.
357 358 359 |
# File 'lib/oci/core/models/virtual_circuit.rb', line 357 def hash [bandwidth_shape_name, bgp_management, bgp_session_state, compartment_id, cross_connect_mappings, customer_bgp_asn, display_name, gateway_id, id, lifecycle_state, oracle_bgp_asn, provider_name, provider_service_id, provider_service_name, provider_state, public_prefixes, reference_comment, region, service_type, time_created, type].hash end |
#to_hash ⇒ Hash
Returns the object in the form of hash
389 390 391 392 393 394 395 396 397 |
# File 'lib/oci/core/models/virtual_circuit.rb', line 389 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
383 384 385 |
# File 'lib/oci/core/models/virtual_circuit.rb', line 383 def to_s to_hash.to_s end |