Class: Google::Apis::MybusinessV3::AttributeMetadata

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

Overview

Metadata for an attribute. Contains display information for the attribute, including a localised name and a heading for grouping related attributes together.

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from Core::JsonObjectSupport

#to_json

Methods included from Core::Hashable

process_value, #to_h

Constructor Details

#initialize(**args) ⇒ AttributeMetadata

Returns a new instance of AttributeMetadata



1822
1823
1824
# File 'generated/google/apis/mybusiness_v3/classes.rb', line 1822

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

Instance Attribute Details

#attribute_idString

The id of the attribute. Corresponds to the JSON property attributeId

Returns:

  • (String)


1787
1788
1789
# File 'generated/google/apis/mybusiness_v3/classes.rb', line 1787

def attribute_id
  @attribute_id
end

#display_nameString

The localised display name for the attribute, if available, otherwise the English display name. Corresponds to the JSON property displayName

Returns:

  • (String)


1799
1800
1801
# File 'generated/google/apis/mybusiness_v3/classes.rb', line 1799

def display_name
  @display_name
end

#group_display_nameString

The localised display name of the group that contains this attribute, if available, otherwise the English group name. Related attributes are collected into group and should be displayed together under the heading given here. Corresponds to the JSON property groupDisplayName

Returns:

  • (String)


1807
1808
1809
# File 'generated/google/apis/mybusiness_v3/classes.rb', line 1807

def group_display_name
  @group_display_name
end

#is_repeatableBoolean Also known as: is_repeatable?

If true, the attribute supports multiple values. If false only a single value should be provided. Corresponds to the JSON property isRepeatable

Returns:

  • (Boolean)


1813
1814
1815
# File 'generated/google/apis/mybusiness_v3/classes.rb', line 1813

def is_repeatable
  @is_repeatable
end

#value_metadataArray<Google::Apis::MybusinessV3::AttributeValueMetadata>

For some types of attributes (e.g. enums) a list of supported values and corresponding display names for those values is provided. Corresponds to the JSON property valueMetadata



1820
1821
1822
# File 'generated/google/apis/mybusiness_v3/classes.rb', line 1820

def 
  @value_metadata
end

#value_typeString

The value type for the attribute. Values set and retrieved should be expected to be of this type. Corresponds to the JSON property valueType

Returns:

  • (String)


1793
1794
1795
# File 'generated/google/apis/mybusiness_v3/classes.rb', line 1793

def value_type
  @value_type
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



1827
1828
1829
1830
1831
1832
1833
1834
# File 'generated/google/apis/mybusiness_v3/classes.rb', line 1827

def update!(**args)
  @attribute_id = args[:attribute_id] if args.key?(:attribute_id)
  @value_type = args[:value_type] if args.key?(:value_type)
  @display_name = args[:display_name] if args.key?(:display_name)
  @group_display_name = args[:group_display_name] if args.key?(:group_display_name)
  @is_repeatable = args[:is_repeatable] if args.key?(:is_repeatable)
  @value_metadata = args[:value_metadata] if args.key?(:value_metadata)
end