Class: OCI::VnMonitoring::Models::VirtualCircuitDrgAttachmentNetworkDetails

Inherits:
DrgAttachmentNetworkDetails show all
Defined in:
lib/oci/vn_monitoring/models/virtual_circuit_drg_attachment_network_details.rb

Overview

Specifies the virtual circuit attached to the DRG.

Constant Summary

Constants inherited from DrgAttachmentNetworkDetails

DrgAttachmentNetworkDetails::TYPE_ENUM

Instance Attribute Summary collapse

Attributes inherited from DrgAttachmentNetworkDetails

#id, #type

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from DrgAttachmentNetworkDetails

get_subtype

Constructor Details

#initialize(attributes = {}) ⇒ VirtualCircuitDrgAttachmentNetworkDetails

Initializes the object

Parameters:

  • attributes (Hash) (defaults to: {})

    Model attributes in the form of hash

Options Hash (attributes):

  • :id (String)

    The value to assign to the #id proprety

  • :is_ffab (BOOLEAN)

    The value to assign to the #is_ffab property

  • :is_edge_pop (BOOLEAN)

    The value to assign to the #is_edge_pop property

  • :import_route_target (String)

    The value to assign to the #import_route_target property

  • :export_route_target (String)

    The value to assign to the #export_route_target property

  • :mpls_label (Integer)

    The value to assign to the #mpls_label property

  • :regional_oci_asn (String)

    The value to assign to the #regional_oci_asn property

  • :region_name (String)

    The value to assign to the #region_name property

  • :common_export_rt (String)

    The value to assign to the #common_export_rt property

  • :common_import_rt (String)

    The value to assign to the #common_import_rt property

  • :is_ingress_disintermediation_enabled (BOOLEAN)

    The value to assign to the #is_ingress_disintermediation_enabled property

  • :is_route_unification_enabled (BOOLEAN)

    The value to assign to the #is_route_unification_enabled property

  • :transport_only_mode (BOOLEAN)

    The value to assign to the #transport_only_mode property



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
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
# File 'lib/oci/vn_monitoring/models/virtual_circuit_drg_attachment_network_details.rb', line 150

def initialize(attributes = {})
  return unless attributes.is_a?(Hash)

  attributes['type'] = 'VIRTUAL_CIRCUIT'

  super(attributes)

  # convert string to symbol for hash key
  attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }

  self.is_ffab = attributes[:'isFFAB'] unless attributes[:'isFFAB'].nil?
  self.is_ffab = false if is_ffab.nil? && !attributes.key?(:'isFFAB') # rubocop:disable Style/StringLiterals

  raise 'You cannot provide both :isFFAB and :is_ffab' if attributes.key?(:'isFFAB') && attributes.key?(:'is_ffab')

  self.is_ffab = attributes[:'is_ffab'] unless attributes[:'is_ffab'].nil?
  self.is_ffab = false if is_ffab.nil? && !attributes.key?(:'isFFAB') && !attributes.key?(:'is_ffab') # rubocop:disable Style/StringLiterals

  self.is_edge_pop = attributes[:'isEdgePop'] unless attributes[:'isEdgePop'].nil?
  self.is_edge_pop = false if is_edge_pop.nil? && !attributes.key?(:'isEdgePop') # rubocop:disable Style/StringLiterals

  raise 'You cannot provide both :isEdgePop and :is_edge_pop' if attributes.key?(:'isEdgePop') && attributes.key?(:'is_edge_pop')

  self.is_edge_pop = attributes[:'is_edge_pop'] unless attributes[:'is_edge_pop'].nil?
  self.is_edge_pop = false if is_edge_pop.nil? && !attributes.key?(:'isEdgePop') && !attributes.key?(:'is_edge_pop') # rubocop:disable Style/StringLiterals

  self.import_route_target = attributes[:'importRouteTarget'] if attributes[:'importRouteTarget']

  raise 'You cannot provide both :importRouteTarget and :import_route_target' if attributes.key?(:'importRouteTarget') && attributes.key?(:'import_route_target')

  self.import_route_target = attributes[:'import_route_target'] if attributes[:'import_route_target']

  self.export_route_target = attributes[:'exportRouteTarget'] if attributes[:'exportRouteTarget']

  raise 'You cannot provide both :exportRouteTarget and :export_route_target' if attributes.key?(:'exportRouteTarget') && attributes.key?(:'export_route_target')

  self.export_route_target = attributes[:'export_route_target'] if attributes[:'export_route_target']

  self.mpls_label = attributes[:'mplsLabel'] if attributes[:'mplsLabel']

  raise 'You cannot provide both :mplsLabel and :mpls_label' if attributes.key?(:'mplsLabel') && attributes.key?(:'mpls_label')

  self.mpls_label = attributes[:'mpls_label'] if attributes[:'mpls_label']

  self.regional_oci_asn = attributes[:'regionalOciAsn'] if attributes[:'regionalOciAsn']

  raise 'You cannot provide both :regionalOciAsn and :regional_oci_asn' if attributes.key?(:'regionalOciAsn') && attributes.key?(:'regional_oci_asn')

  self.regional_oci_asn = attributes[:'regional_oci_asn'] if attributes[:'regional_oci_asn']

  self.region_name = attributes[:'regionName'] if attributes[:'regionName']

  raise 'You cannot provide both :regionName and :region_name' if attributes.key?(:'regionName') && attributes.key?(:'region_name')

  self.region_name = attributes[:'region_name'] if attributes[:'region_name']

  self.common_export_rt = attributes[:'commonExportRT'] if attributes[:'commonExportRT']

  raise 'You cannot provide both :commonExportRT and :common_export_rt' if attributes.key?(:'commonExportRT') && attributes.key?(:'common_export_rt')

  self.common_export_rt = attributes[:'common_export_rt'] if attributes[:'common_export_rt']

  self.common_import_rt = attributes[:'commonImportRT'] if attributes[:'commonImportRT']

  raise 'You cannot provide both :commonImportRT and :common_import_rt' if attributes.key?(:'commonImportRT') && attributes.key?(:'common_import_rt')

  self.common_import_rt = attributes[:'common_import_rt'] if attributes[:'common_import_rt']

  self.is_ingress_disintermediation_enabled = attributes[:'isIngressDisintermediationEnabled'] unless attributes[:'isIngressDisintermediationEnabled'].nil?
  self.is_ingress_disintermediation_enabled = false if is_ingress_disintermediation_enabled.nil? && !attributes.key?(:'isIngressDisintermediationEnabled') # rubocop:disable Style/StringLiterals

  raise 'You cannot provide both :isIngressDisintermediationEnabled and :is_ingress_disintermediation_enabled' if attributes.key?(:'isIngressDisintermediationEnabled') && attributes.key?(:'is_ingress_disintermediation_enabled')

  self.is_ingress_disintermediation_enabled = attributes[:'is_ingress_disintermediation_enabled'] unless attributes[:'is_ingress_disintermediation_enabled'].nil?
  self.is_ingress_disintermediation_enabled = false if is_ingress_disintermediation_enabled.nil? && !attributes.key?(:'isIngressDisintermediationEnabled') && !attributes.key?(:'is_ingress_disintermediation_enabled') # rubocop:disable Style/StringLiterals

  self.is_route_unification_enabled = attributes[:'isRouteUnificationEnabled'] unless attributes[:'isRouteUnificationEnabled'].nil?
  self.is_route_unification_enabled = false if is_route_unification_enabled.nil? && !attributes.key?(:'isRouteUnificationEnabled') # rubocop:disable Style/StringLiterals

  raise 'You cannot provide both :isRouteUnificationEnabled and :is_route_unification_enabled' if attributes.key?(:'isRouteUnificationEnabled') && attributes.key?(:'is_route_unification_enabled')

  self.is_route_unification_enabled = attributes[:'is_route_unification_enabled'] unless attributes[:'is_route_unification_enabled'].nil?
  self.is_route_unification_enabled = false if is_route_unification_enabled.nil? && !attributes.key?(:'isRouteUnificationEnabled') && !attributes.key?(:'is_route_unification_enabled') # rubocop:disable Style/StringLiterals

  self.transport_only_mode = attributes[:'transportOnlyMode'] unless attributes[:'transportOnlyMode'].nil?
  self.transport_only_mode = false if transport_only_mode.nil? && !attributes.key?(:'transportOnlyMode') # rubocop:disable Style/StringLiterals

  raise 'You cannot provide both :transportOnlyMode and :transport_only_mode' if attributes.key?(:'transportOnlyMode') && attributes.key?(:'transport_only_mode')

  self.transport_only_mode = attributes[:'transport_only_mode'] unless attributes[:'transport_only_mode'].nil?
  self.transport_only_mode = false if transport_only_mode.nil? && !attributes.key?(:'transportOnlyMode') && !attributes.key?(:'transport_only_mode') # rubocop:disable Style/StringLiterals
end

Instance Attribute Details

#common_export_rtString

Common Export route target to use for the DRG Attachment instead of per-attachment route target. This is applicable to DRG attachments that are assigned to a DRG route table which is whitelisted for high throughput mode.

Returns:

  • (String)


57
58
59
# File 'lib/oci/vn_monitoring/models/virtual_circuit_drg_attachment_network_details.rb', line 57

def common_export_rt
  @common_export_rt
end

#common_import_rtString

Common Import route target to use for the DRG attachment instead of per-attachment import route target. This is applicable to DRG attachments that are assigned to a DRG route table which is whitelisted for high throughput mode.

Returns:

  • (String)


64
65
66
# File 'lib/oci/vn_monitoring/models/virtual_circuit_drg_attachment_network_details.rb', line 64

def common_import_rt
  @common_import_rt
end

#export_route_targetString

Routes which are exported to the attachment are exported to the route reflectors with the route target set to the value of the attachment's export route target.

Returns:

  • (String)


36
37
38
# File 'lib/oci/vn_monitoring/models/virtual_circuit_drg_attachment_network_details.rb', line 36

def export_route_target
  @export_route_target
end

#import_route_targetString

Routes which may be imported from the attachment (subject to import policy) appear in the route reflectors tagged with the attachment's import route target.

Returns:

  • (String)


30
31
32
# File 'lib/oci/vn_monitoring/models/virtual_circuit_drg_attachment_network_details.rb', line 30

def import_route_target
  @import_route_target
end

#is_edge_popBOOLEAN

This indicates whether FastConnect extends through an edge POP region.

Example: true

Returns:

  • (BOOLEAN)


24
25
26
# File 'lib/oci/vn_monitoring/models/virtual_circuit_drg_attachment_network_details.rb', line 24

def is_edge_pop
  @is_edge_pop
end

#is_ffabBOOLEAN

Whether the Fast Connect is an FFAB VirtualCircuit.

Example: true

Returns:

  • (BOOLEAN)


17
18
19
# File 'lib/oci/vn_monitoring/models/virtual_circuit_drg_attachment_network_details.rb', line 17

def is_ffab
  @is_ffab
end

#is_ingress_disintermediation_enabledBOOLEAN

This indicates whether the DRG route table associated with the DRG attachment is whitelisted for High Throughput mode.

Example: true

Returns:

  • (BOOLEAN)


71
72
73
# File 'lib/oci/vn_monitoring/models/virtual_circuit_drg_attachment_network_details.rb', line 71

def is_ingress_disintermediation_enabled
  @is_ingress_disintermediation_enabled
end

#is_route_unification_enabledBOOLEAN

This indicates whether the DRG route table associated with the DRG attachment is whitelisted for route unification.

Example: true

Returns:

  • (BOOLEAN)


78
79
80
# File 'lib/oci/vn_monitoring/models/virtual_circuit_drg_attachment_network_details.rb', line 78

def is_route_unification_enabled
  @is_route_unification_enabled
end

#mpls_labelInteger

The MPLS label of the DRG attachment.

Returns:

  • (Integer)


40
41
42
# File 'lib/oci/vn_monitoring/models/virtual_circuit_drg_attachment_network_details.rb', line 40

def mpls_label
  @mpls_label
end

#region_nameString

The Oracle Cloud Infrastructure region name.

Returns:

  • (String)


50
51
52
# File 'lib/oci/vn_monitoring/models/virtual_circuit_drg_attachment_network_details.rb', line 50

def region_name
  @region_name
end

#regional_oci_asnString

The BGP ASN to use for the IPSec connection's route target.

Returns:

  • (String)


45
46
47
# File 'lib/oci/vn_monitoring/models/virtual_circuit_drg_attachment_network_details.rb', line 45

def regional_oci_asn
  @regional_oci_asn
end

#transport_only_modeBOOLEAN

Boolean flag that determines wether all traffic over the virtual circuits is encrypted.

Example: true

Returns:

  • (BOOLEAN)


85
86
87
# File 'lib/oci/vn_monitoring/models/virtual_circuit_drg_attachment_network_details.rb', line 85

def transport_only_mode
  @transport_only_mode
end

Class Method Details

.attribute_mapObject

Attribute mapping from ruby-style variable name to JSON key.



88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
# File 'lib/oci/vn_monitoring/models/virtual_circuit_drg_attachment_network_details.rb', line 88

def self.attribute_map
  {
    # rubocop:disable Style/SymbolLiteral
    'type': :'type',
    'id': :'id',
    'is_ffab': :'isFFAB',
    'is_edge_pop': :'isEdgePop',
    'import_route_target': :'importRouteTarget',
    'export_route_target': :'exportRouteTarget',
    'mpls_label': :'mplsLabel',
    'regional_oci_asn': :'regionalOciAsn',
    'region_name': :'regionName',
    'common_export_rt': :'commonExportRT',
    'common_import_rt': :'commonImportRT',
    'is_ingress_disintermediation_enabled': :'isIngressDisintermediationEnabled',
    'is_route_unification_enabled': :'isRouteUnificationEnabled',
    'transport_only_mode': :'transportOnlyMode'
    # rubocop:enable Style/SymbolLiteral
  }
end

.swagger_typesObject

Attribute type mapping.



110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
# File 'lib/oci/vn_monitoring/models/virtual_circuit_drg_attachment_network_details.rb', line 110

def self.swagger_types
  {
    # rubocop:disable Style/SymbolLiteral
    'type': :'String',
    'id': :'String',
    'is_ffab': :'BOOLEAN',
    'is_edge_pop': :'BOOLEAN',
    'import_route_target': :'String',
    'export_route_target': :'String',
    'mpls_label': :'Integer',
    'regional_oci_asn': :'String',
    'region_name': :'String',
    'common_export_rt': :'String',
    'common_import_rt': :'String',
    'is_ingress_disintermediation_enabled': :'BOOLEAN',
    'is_route_unification_enabled': :'BOOLEAN',
    'transport_only_mode': :'BOOLEAN'
    # rubocop:enable Style/SymbolLiteral
  }
end

Instance Method Details

#==(other) ⇒ Object

Checks equality by comparing each attribute.

Parameters:

  • other (Object)

    the other object to be compared



250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
# File 'lib/oci/vn_monitoring/models/virtual_circuit_drg_attachment_network_details.rb', line 250

def ==(other)
  return true if equal?(other)

  self.class == other.class &&
    type == other.type &&
    id == other.id &&
    is_ffab == other.is_ffab &&
    is_edge_pop == other.is_edge_pop &&
    import_route_target == other.import_route_target &&
    export_route_target == other.export_route_target &&
    mpls_label == other.mpls_label &&
    regional_oci_asn == other.regional_oci_asn &&
    region_name == other.region_name &&
    common_export_rt == other.common_export_rt &&
    common_import_rt == other.common_import_rt &&
    is_ingress_disintermediation_enabled == other.is_ingress_disintermediation_enabled &&
    is_route_unification_enabled == other.is_route_unification_enabled &&
    transport_only_mode == other.transport_only_mode
end

#build_from_hash(attributes) ⇒ Object

Builds the object from hash

Parameters:

  • attributes (Hash)

    Model attributes in the form of hash

Returns:

  • (Object)

    Returns the model itself



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/vn_monitoring/models/virtual_circuit_drg_attachment_network_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

Parameters:

  • other (Object)

    the other object to be compared

Returns:

  • (Boolean)

See Also:

  • `==` method


273
274
275
# File 'lib/oci/vn_monitoring/models/virtual_circuit_drg_attachment_network_details.rb', line 273

def eql?(other)
  self == other
end

#hashFixnum

Calculates hash code according to all attributes.

Returns:

  • (Fixnum)

    Hash code



282
283
284
# File 'lib/oci/vn_monitoring/models/virtual_circuit_drg_attachment_network_details.rb', line 282

def hash
  [type, id, is_ffab, is_edge_pop, import_route_target, export_route_target, mpls_label, regional_oci_asn, region_name, common_export_rt, common_import_rt, is_ingress_disintermediation_enabled, is_route_unification_enabled, transport_only_mode].hash
end

#to_hashHash

Returns the object in the form of hash

Returns:

  • (Hash)

    Returns the object in the form of hash



326
327
328
329
330
331
332
333
334
335
# File 'lib/oci/vn_monitoring/models/virtual_circuit_drg_attachment_network_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_sString

Returns the string representation of the object

Returns:

  • (String)

    String presentation of the object



320
321
322
# File 'lib/oci/vn_monitoring/models/virtual_circuit_drg_attachment_network_details.rb', line 320

def to_s
  to_hash.to_s
end