Class: Google::Apis::MybusinessbusinessinformationV1::Attribute
- Inherits:
-
Object
- Object
- Google::Apis::MybusinessbusinessinformationV1::Attribute
- Includes:
- Core::Hashable, Core::JsonObjectSupport
- Defined in:
- lib/google/apis/mybusinessbusinessinformation_v1/classes.rb,
lib/google/apis/mybusinessbusinessinformation_v1/representations.rb,
lib/google/apis/mybusinessbusinessinformation_v1/representations.rb
Overview
A location attribute. Attributes provide additional information about a location. The attributes that can be set on a location may vary based on the properties of that location (for example, category). Available attributes are determined by Google and may be added and removed without API changes.
Instance Attribute Summary collapse
-
#name ⇒ String
Required.
-
#repeated_enum_value ⇒ Google::Apis::MybusinessbusinessinformationV1::RepeatedEnumAttributeValue
Values for an attribute with a
value_type
of REPEATED_ENUM. -
#uri_values ⇒ Array<Google::Apis::MybusinessbusinessinformationV1::UriAttributeValue>
When the attribute value type is URL, this field contains the value(s) for this attribute, and the other values fields must be empty.
-
#value_type ⇒ String
Output only.
-
#values ⇒ Array<Object>
The values for this attribute.
Instance Method Summary collapse
-
#initialize(**args) ⇒ Attribute
constructor
A new instance of Attribute.
-
#update!(**args) ⇒ Object
Update properties of this object.
Constructor Details
#initialize(**args) ⇒ Attribute
Returns a new instance of Attribute.
84 85 86 |
# File 'lib/google/apis/mybusinessbusinessinformation_v1/classes.rb', line 84 def initialize(**args) update!(**args) end |
Instance Attribute Details
#name ⇒ String
Required. The resource name for this attribute.
Corresponds to the JSON property name
55 56 57 |
# File 'lib/google/apis/mybusinessbusinessinformation_v1/classes.rb', line 55 def name @name end |
#repeated_enum_value ⇒ Google::Apis::MybusinessbusinessinformationV1::RepeatedEnumAttributeValue
Values for an attribute with a value_type
of REPEATED_ENUM. This consists of
two lists of value IDs: those that are set (true) and those that are unset (
false). Values absent are considered unknown. At least one value must be
specified.
Corresponds to the JSON property repeatedEnumValue
63 64 65 |
# File 'lib/google/apis/mybusinessbusinessinformation_v1/classes.rb', line 63 def repeated_enum_value @repeated_enum_value end |
#uri_values ⇒ Array<Google::Apis::MybusinessbusinessinformationV1::UriAttributeValue>
When the attribute value type is URL, this field contains the value(s) for
this attribute, and the other values fields must be empty.
Corresponds to the JSON property uriValues
69 70 71 |
# File 'lib/google/apis/mybusinessbusinessinformation_v1/classes.rb', line 69 def uri_values @uri_values end |
#value_type ⇒ String
Output only. The type of value that this attribute contains. This should be
used to determine how to interpret the value.
Corresponds to the JSON property valueType
75 76 77 |
# File 'lib/google/apis/mybusinessbusinessinformation_v1/classes.rb', line 75 def value_type @value_type end |
#values ⇒ Array<Object>
The values for this attribute. The type of the values supplied must match that
expected for that attribute. This is a repeated field where multiple attribute
values may be provided. Attribute types only support one value.
Corresponds to the JSON property values
82 83 84 |
# File 'lib/google/apis/mybusinessbusinessinformation_v1/classes.rb', line 82 def values @values end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
89 90 91 92 93 94 95 |
# File 'lib/google/apis/mybusinessbusinessinformation_v1/classes.rb', line 89 def update!(**args) @name = args[:name] if args.key?(:name) @repeated_enum_value = args[:repeated_enum_value] if args.key?(:repeated_enum_value) @uri_values = args[:uri_values] if args.key?(:uri_values) @value_type = args[:value_type] if args.key?(:value_type) @values = args[:values] if args.key?(:values) end |