Class: Google::Apis::HypercomputeclusterV1::NetworkResourceConfig

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

Overview

Describes how a network resource should be initialized. Each network resource can either be imported from an existing Google Cloud resource or initialized when the cluster is created.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ NetworkResourceConfig

Returns a new instance of NetworkResourceConfig.



1069
1070
1071
# File 'lib/google/apis/hypercomputecluster_v1/classes.rb', line 1069

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

Instance Attribute Details

#existing_networkGoogle::Apis::HypercomputeclusterV1::ExistingNetworkConfig

When set in a NetworkResourceConfig, indicates that an existing network should be imported. Corresponds to the JSON property existingNetwork



1061
1062
1063
# File 'lib/google/apis/hypercomputecluster_v1/classes.rb', line 1061

def existing_network
  @existing_network
end

#new_networkGoogle::Apis::HypercomputeclusterV1::NewNetworkConfig

When set in a NetworkResourceConfig, indicates that a new network should be created. Corresponds to the JSON property newNetwork



1067
1068
1069
# File 'lib/google/apis/hypercomputecluster_v1/classes.rb', line 1067

def new_network
  @new_network
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



1074
1075
1076
1077
# File 'lib/google/apis/hypercomputecluster_v1/classes.rb', line 1074

def update!(**args)
  @existing_network = args[:existing_network] if args.key?(:existing_network)
  @new_network = args[:new_network] if args.key?(:new_network)
end