Reference documentation and code samples for the Google Ads Ad Manager V1 Client class InventoryTargeting.
Targeted ad units and AU placements are applied with logical OR. Example: (au:1 OR au:2 OR au_placement:5) AND (NOT (au:3))
Generated from protobuf message google.ads.admanager.v1.InventoryTargeting
Namespace
Google \ Ads \ AdManager \ V1Methods
__construct
Constructor.
Parameters | |
---|---|
Name | Description |
data |
array
Optional. Data for populating the Message object. |
↳ targeted_ad_units |
array<AdUnitTargeting>
Optional. A list of ad units that should be targeted/included. |
↳ excluded_ad_units |
array<AdUnitTargeting>
Optional. A list of ad units that should be excluded. Excluded AUs take precedence over targeted AUs. In fact an AU can be excluded only if one of its ancestors is targeted. Subsequently child AUs of an excluded AU can not be targeted (except via a placement). |
↳ targeted_placements |
array
Optional. The resource names of the placements that should be targeted/included. |
getTargetedAdUnits
Optional. A list of ad units that should be targeted/included.
Returns | |
---|---|
Type | Description |
Google\Protobuf\Internal\RepeatedField |
setTargetedAdUnits
Optional. A list of ad units that should be targeted/included.
Parameter | |
---|---|
Name | Description |
var |
array<AdUnitTargeting>
|
Returns | |
---|---|
Type | Description |
$this |
getExcludedAdUnits
Optional. A list of ad units that should be excluded.
Excluded AUs take precedence over targeted AUs. In fact an AU can be excluded only if one of its ancestors is targeted. Subsequently child AUs of an excluded AU can not be targeted (except via a placement).
Returns | |
---|---|
Type | Description |
Google\Protobuf\Internal\RepeatedField |
setExcludedAdUnits
Optional. A list of ad units that should be excluded.
Excluded AUs take precedence over targeted AUs. In fact an AU can be excluded only if one of its ancestors is targeted. Subsequently child AUs of an excluded AU can not be targeted (except via a placement).
Parameter | |
---|---|
Name | Description |
var |
array<AdUnitTargeting>
|
Returns | |
---|---|
Type | Description |
$this |
getTargetedPlacements
Optional. The resource names of the placements that should be targeted/included.
Returns | |
---|---|
Type | Description |
Google\Protobuf\Internal\RepeatedField |
setTargetedPlacements
Optional. The resource names of the placements that should be targeted/included.
Parameter | |
---|---|
Name | Description |
var |
string[]
|
Returns | |
---|---|
Type | Description |
$this |