Class: Google::Apis::DatacatalogV1beta1::GoogleCloudDatacatalogV1beta1TagTemplate

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

Overview

A tag template defines a tag, which can have one or more typed fields. The template is used to create and attach the tag to GCP resources. Tag template roles provide permissions to create, edit, and use the template. See, for example, the TagTemplate User role, which includes permission to use the tag template to tag resources.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ GoogleCloudDatacatalogV1beta1TagTemplate

Returns a new instance of GoogleCloudDatacatalogV1beta1TagTemplate.



1447
1448
1449
# File 'generated/google/apis/datacatalog_v1beta1/classes.rb', line 1447

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

Instance Attribute Details

#display_nameString

The display name for this template. Defaults to an empty string. Corresponds to the JSON property displayName

Returns:

  • (String)


1426
1427
1428
# File 'generated/google/apis/datacatalog_v1beta1/classes.rb', line 1426

def display_name
  @display_name
end

#fieldsHash<String,Google::Apis::DatacatalogV1beta1::GoogleCloudDatacatalogV1beta1TagTemplateField>

Required. Map of tag template field IDs to the settings for the field. This map is an exhaustive list of the allowed fields. This map must contain at least one field and at most 500 fields. The keys to this map are tag template field IDs. Field IDs can contain letters (both uppercase and lowercase), numbers (0-9) and underscores (_). Field IDs must be at least 1 character long and at most 64 characters long. Field IDs must start with a letter or underscore. Corresponds to the JSON property fields



1437
1438
1439
# File 'generated/google/apis/datacatalog_v1beta1/classes.rb', line 1437

def fields
  @fields
end

#nameString

The resource name of the tag template in URL format. Example: * projects/ project_id/locations/location/tagTemplates/tag_template_id Note that this TagTemplate and its child resources may not actually be stored in the location in this name. Corresponds to the JSON property name

Returns:

  • (String)


1445
1446
1447
# File 'generated/google/apis/datacatalog_v1beta1/classes.rb', line 1445

def name
  @name
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



1452
1453
1454
1455
1456
# File 'generated/google/apis/datacatalog_v1beta1/classes.rb', line 1452

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