Class: Google::Apis::ComputeV1::NetworksAddPeeringRequest

Inherits:
Object
  • Object
show all
Includes:
Google::Apis::Core::Hashable, Google::Apis::Core::JsonObjectSupport
Defined in:
lib/google/apis/compute_v1/classes.rb,
lib/google/apis/compute_v1/representations.rb,
lib/google/apis/compute_v1/representations.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ NetworksAddPeeringRequest

Returns a new instance of NetworksAddPeeringRequest.



37818
37819
37820
# File 'lib/google/apis/compute_v1/classes.rb', line 37818

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#auto_create_routesBoolean Also known as: auto_create_routes?

This field will be deprecated soon. Useexchange_subnet_routes in network_peering instead. Indicates whether full mesh connectivity is created and managed automatically between peered networks. Currently this field should always be true since Google Compute Engine will automatically create and manage subnetwork routes between two networks when peering state isACTIVE. Corresponds to the JSON property autoCreateRoutes

Returns:

  • (Boolean)


37795
37796
37797
# File 'lib/google/apis/compute_v1/classes.rb', line 37795

def auto_create_routes
  @auto_create_routes
end

#nameString

Name of the peering, which should conform to RFC1035. Corresponds to the JSON property name

Returns:

  • (String)


37801
37802
37803
# File 'lib/google/apis/compute_v1/classes.rb', line 37801

def name
  @name
end

#network_peeringGoogle::Apis::ComputeV1::NetworkPeering

A network peering attached to a network resource. The message includes the peering name, peer network, peering state, and a flag indicating whether Google Compute Engine should automatically create routes for the peering. Corresponds to the JSON property networkPeering



37808
37809
37810
# File 'lib/google/apis/compute_v1/classes.rb', line 37808

def network_peering
  @network_peering
end

#peer_networkString

URL of the peer network. It can be either full URL or partial URL. The peer network may belong to a different project. If the partial URL does not contain project, it is assumed that the peer network is in the same project as the current network. Corresponds to the JSON property peerNetwork

Returns:

  • (String)


37816
37817
37818
# File 'lib/google/apis/compute_v1/classes.rb', line 37816

def peer_network
  @peer_network
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



37823
37824
37825
37826
37827
37828
# File 'lib/google/apis/compute_v1/classes.rb', line 37823

def update!(**args)
  @auto_create_routes = args[:auto_create_routes] if args.key?(:auto_create_routes)
  @name = args[:name] if args.key?(:name)
  @network_peering = args[:network_peering] if args.key?(:network_peering)
  @peer_network = args[:peer_network] if args.key?(:peer_network)
end