Class: Google::Apis::BackupdrV1::LabelKeyValPair

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

Message for a label key-value pair.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ LabelKeyValPair

Returns a new instance of LabelKeyValPair.



4226
4227
4228
# File 'lib/google/apis/backupdr_v1/classes.rb', line 4226

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

Instance Attribute Details

#keyString

Key of the label. The key must follow the format: \\pLl\\pLo0,62. This means the key must start with a lowercase letter or a lowercase international character, followed by zero or more lowercase letters, lowercase international characters, numbers, underscores, or dashes. The key must be at most 63 characters long. International characters are allowed. Corresponds to the JSON property key

Returns:

  • (String)


4216
4217
4218
# File 'lib/google/apis/backupdr_v1/classes.rb', line 4216

def key
  @key
end

#valueString

Value of the label. The value must follow the format: [\\pLl\\pLo\\pN_-] 1,63`. This means the value must be one or more lowercase letters, lowercase international characters, numbers, underscores, or dashes. The value must be at most 63 characters long. International characters are allowed. Corresponds to the JSON propertyvalue`

Returns:

  • (String)


4224
4225
4226
# File 'lib/google/apis/backupdr_v1/classes.rb', line 4224

def value
  @value
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



4231
4232
4233
4234
# File 'lib/google/apis/backupdr_v1/classes.rb', line 4231

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