Google Shopping Common Protos Client - Class CustomAttribute (0.4.0)

Reference documentation and code samples for the Google Shopping Common Protos Client class CustomAttribute.

A message that represents custom attributes. Exactly one of value or group_values must not be empty.

Generated from protobuf message google.shopping.type.CustomAttribute

Namespace

Google \ Shopping \ Type

Methods

__construct

Constructor.

Parameters
Name Description
data array

Optional. Data for populating the Message object.

↳ name string

The name of the attribute.

↳ value string

The value of the attribute. If value is not empty, group_values must be empty.

↳ group_values array<Google\Shopping\Type\CustomAttribute>

Subattributes within this attribute group. If group_values is not empty, value must be empty.

getName

The name of the attribute.

Returns
Type Description
string

hasName

clearName

setName

The name of the attribute.

Parameter
Name Description
var string
Returns
Type Description
$this

getValue

The value of the attribute. If value is not empty, group_values must be empty.

Returns
Type Description
string

hasValue

clearValue

setValue

The value of the attribute. If value is not empty, group_values must be empty.

Parameter
Name Description
var string
Returns
Type Description
$this

getGroupValues

Subattributes within this attribute group. If group_values is not empty, value must be empty.

Returns
Type Description
Google\Protobuf\Internal\RepeatedField

setGroupValues

Subattributes within this attribute group. If group_values is not empty, value must be empty.

Parameter
Name Description
var array<Google\Shopping\Type\CustomAttribute>
Returns
Type Description
$this