Class: Google::Apis::ApihubV1::GoogleCloudApihubV1ConfigVariableTemplate

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

Overview

ConfigVariableTemplate represents a configuration variable template present in a Plugin Config.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ GoogleCloudApihubV1ConfigVariableTemplate

Returns a new instance of GoogleCloudApihubV1ConfigVariableTemplate.



1335
1336
1337
# File 'lib/google/apis/apihub_v1/classes.rb', line 1335

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

Instance Attribute Details

#descriptionString

Optional. Description. Corresponds to the JSON property description

Returns:

  • (String)


1299
1300
1301
# File 'lib/google/apis/apihub_v1/classes.rb', line 1299

def description
  @description
end

#enum_optionsArray<Google::Apis::ApihubV1::GoogleCloudApihubV1ConfigValueOption>

Optional. Enum options. To be populated if ValueType is ENUM. Corresponds to the JSON property enumOptions



1304
1305
1306
# File 'lib/google/apis/apihub_v1/classes.rb', line 1304

def enum_options
  @enum_options
end

#idString

Required. ID of the config variable. Must be unique within the configuration. Corresponds to the JSON property id

Returns:

  • (String)


1309
1310
1311
# File 'lib/google/apis/apihub_v1/classes.rb', line 1309

def id
  @id
end

#multi_select_optionsArray<Google::Apis::ApihubV1::GoogleCloudApihubV1ConfigValueOption>

Optional. Multi select options. To be populated if ValueType is MULTI_SELECT. Corresponds to the JSON property multiSelectOptions



1315
1316
1317
# File 'lib/google/apis/apihub_v1/classes.rb', line 1315

def multi_select_options
  @multi_select_options
end

#requiredBoolean Also known as: required?

Optional. Flag represents that this ConfigVariable must be provided for a PluginInstance. Corresponds to the JSON property required

Returns:

  • (Boolean)


1321
1322
1323
# File 'lib/google/apis/apihub_v1/classes.rb', line 1321

def required
  @required
end

#validation_regexString

Optional. Regular expression in RE2 syntax used for validating the value of a ConfigVariable. Corresponds to the JSON property validationRegex

Returns:

  • (String)


1328
1329
1330
# File 'lib/google/apis/apihub_v1/classes.rb', line 1328

def validation_regex
  @validation_regex
end

#value_typeString

Required. Type of the parameter: string, int, bool etc. Corresponds to the JSON property valueType

Returns:

  • (String)


1333
1334
1335
# File 'lib/google/apis/apihub_v1/classes.rb', line 1333

def value_type
  @value_type
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



1340
1341
1342
1343
1344
1345
1346
1347
1348
# File 'lib/google/apis/apihub_v1/classes.rb', line 1340

def update!(**args)
  @description = args[:description] if args.key?(:description)
  @enum_options = args[:enum_options] if args.key?(:enum_options)
  @id = args[:id] if args.key?(:id)
  @multi_select_options = args[:multi_select_options] if args.key?(:multi_select_options)
  @required = args[:required] if args.key?(:required)
  @validation_regex = args[:validation_regex] if args.key?(:validation_regex)
  @value_type = args[:value_type] if args.key?(:value_type)
end