Class: Google::Apis::BackupdrV1::NodeAffinity

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

Overview

Node Affinity: the configuration of desired nodes onto which this Instance could be scheduled.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ NodeAffinity

Returns a new instance of NodeAffinity.



5018
5019
5020
# File 'lib/google/apis/backupdr_v1/classes.rb', line 5018

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

Instance Attribute Details

#keyString

Optional. Corresponds to the label key of Node resource. Corresponds to the JSON property key

Returns:

  • (String)


5006
5007
5008
# File 'lib/google/apis/backupdr_v1/classes.rb', line 5006

def key
  @key
end

#operatorString

Optional. Defines the operation of node selection. Corresponds to the JSON property operator

Returns:

  • (String)


5011
5012
5013
# File 'lib/google/apis/backupdr_v1/classes.rb', line 5011

def operator
  @operator
end

#valuesArray<String>

Optional. Corresponds to the label values of Node resource. Corresponds to the JSON property values

Returns:

  • (Array<String>)


5016
5017
5018
# File 'lib/google/apis/backupdr_v1/classes.rb', line 5016

def values
  @values
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



5023
5024
5025
5026
5027
# File 'lib/google/apis/backupdr_v1/classes.rb', line 5023

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