-
Notifications
You must be signed in to change notification settings - Fork 260
/
AddPerformanceMaxProductListingGroupTree.php
606 lines (563 loc) · 26.2 KB
/
AddPerformanceMaxProductListingGroupTree.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
<?php
/**
* Copyright 2022 Google LLC
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* https://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
namespace Google\Ads\GoogleAds\Examples\ShoppingAds;
require __DIR__ . '/../../vendor/autoload.php';
use GetOpt\GetOpt;
use Google\Ads\GoogleAds\Examples\Utils\ArgumentNames;
use Google\Ads\GoogleAds\Examples\Utils\ArgumentParser;
use Google\Ads\GoogleAds\Lib\OAuth2TokenBuilder;
use Google\Ads\GoogleAds\Lib\V12\GoogleAdsClient;
use Google\Ads\GoogleAds\Lib\V12\GoogleAdsClientBuilder;
use Google\Ads\GoogleAds\Lib\V12\GoogleAdsException;
use Google\Ads\GoogleAds\Util\V12\ResourceNames;
use Google\Ads\GoogleAds\V12\Enums\ListingGroupFilterProductConditionEnum\ListingGroupFilterProductCondition;
use Google\Ads\GoogleAds\V12\Enums\ListingGroupFilterTypeEnum\ListingGroupFilterType;
use Google\Ads\GoogleAds\V12\Enums\ListingGroupFilterVerticalEnum\ListingGroupFilterVertical;
use Google\Ads\GoogleAds\V12\Errors\GoogleAdsError;
use Google\Ads\GoogleAds\V12\Resources\AssetGroupListingGroupFilter;
use Google\Ads\GoogleAds\V12\Resources\ListingGroupFilterDimension;
use Google\Ads\GoogleAds\V12\Resources\ListingGroupFilterDimension\ProductBrand;
use Google\Ads\GoogleAds\V12\Resources\ListingGroupFilterDimension\ProductCondition;
use Google\Ads\GoogleAds\V12\Services\AssetGroupListingGroupFilterOperation;
use Google\Ads\GoogleAds\V12\Services\GoogleAdsRow;
use Google\Ads\GoogleAds\V12\Services\MutateGoogleAdsResponse;
use Google\Ads\GoogleAds\V12\Services\MutateOperation;
use Google\Ads\GoogleAds\V12\Services\MutateOperationResponse;
use Google\ApiCore\ApiException;
use Google\ApiCore\Serializer;
/**
* This example shows how to add product partitions to a Performance Max retail campaign.
*
* For Performance Max campaigns, product partitions are represented using the
* AssetGroupListingGroupFilter resource. This resource can be combined with itself to form a
* hierarchy that creates a product partition tree.
*
* For more information about Performance Max retail campaigns, see the
* AddPerformanceMaxRetailCampaign example.
*/
class AddPerformanceMaxProductListingGroupTree
{
private const CUSTOMER_ID = 'INSERT_CUSTOMER_ID_HERE';
private const ASSET_GROUP_ID = 'INSERT_ASSET_GROUP_ID_HERE';
// Optional: Removes the existing listing group tree from the asset group or not.
//
// If the current asset group already has a tree of listing group filters, and you
// try to add a new set of listing group filters including a root filter, you'll
// receive a 'ASSET_GROUP_LISTING_GROUP_FILTER_ERROR_MULTIPLE_ROOTS' error.
//
// Setting this option to true will remove the existing tree and prevent this error.
private const REPLACE_EXISTING_TREE = false;
// We specify temporary IDs that are specific to a single mutate request.
// Temporary IDs are always negative and unique within one mutate request.
private const LISTING_GROUP_ROOT_TEMPORARY_ID = -1;
private const PAGE_SIZE = 1000;
public static function main()
{
// Either pass the required parameters for this example on the command line, or insert them
// into the constants above.
$options = (new ArgumentParser())->parseCommandArguments([
ArgumentNames::CUSTOMER_ID => GetOpt::REQUIRED_ARGUMENT,
ArgumentNames::ASSET_GROUP_ID => GetOpt::REQUIRED_ARGUMENT,
ArgumentNames::REPLACE_EXISTING_TREE => GetOpt::OPTIONAL_ARGUMENT
]);
// Generate a refreshable OAuth2 credential for authentication.
$oAuth2Credential = (new OAuth2TokenBuilder())->fromFile()->build();
// Construct a Google Ads client configured from a properties file and the
// OAuth2 credentials above.
$googleAdsClient = (new GoogleAdsClientBuilder())->fromFile()
->withOAuth2Credential($oAuth2Credential)
->build();
try {
self::runExample(
$googleAdsClient,
$options[ArgumentNames::CUSTOMER_ID] ?: self::CUSTOMER_ID,
$options[ArgumentNames::ASSET_GROUP_ID] ?: self::ASSET_GROUP_ID,
filter_var(
$options[ArgumentNames::REPLACE_EXISTING_TREE]
?: self::REPLACE_EXISTING_TREE,
FILTER_VALIDATE_BOOLEAN
)
);
} catch (GoogleAdsException $googleAdsException) {
printf(
"Request with ID '%s' has failed.%sGoogle Ads failure details:%s",
$googleAdsException->getRequestId(),
PHP_EOL,
PHP_EOL
);
foreach ($googleAdsException->getGoogleAdsFailure()->getErrors() as $error) {
/** @var GoogleAdsError $error */
printf(
"\t%s: %s%s",
$error->getErrorCode()->getErrorCode(),
$error->getMessage(),
PHP_EOL
);
}
exit(1);
} catch (ApiException $apiException) {
printf(
"ApiException was thrown with message '%s'.%s",
$apiException->getMessage(),
PHP_EOL
);
exit(1);
}
}
// [START add_performance_max_product_listing_group_tree]
/**
* Runs the example.
*
* @param GoogleAdsClient $googleAdsClient the Google Ads API client
* @param int $customerId the customer ID
* @param int $assetGroupId the asset group ID
* @param bool $replaceExistingTree true if it should replace the existing listing group
* tree on the asset group
*/
public static function runExample(
GoogleAdsClient $googleAdsClient,
int $customerId,
int $assetGroupId,
bool $replaceExistingTree
) {
// We create all the mutate operations that manipulate a specific asset group for a specific
// customer. The operations are used to optionally remove all asset group listing group
// filters from the tree, and then to construct a new tree of filters. These filters can
// have a parent-child relationship, and also include a special root that includes all
// children.
//
// When creating these filters, we use temporary IDs to create the hierarchy between
// the root listing group filter, and the subdivisions and leave nodes beneath that.
$mutateOperations = [];
if ($replaceExistingTree === true) {
$existingListingGroupFilters = self::getAllExistingListingGroupFilterAssetsInAssetGroup(
$googleAdsClient,
$customerId,
ResourceNames::forAssetGroup($customerId, $assetGroupId)
);
if (count($existingListingGroupFilters) > 0) {
$mutateOperations = array_merge(
$mutateOperations,
// Ensures the creation of remove operations in the correct order (child listing
// group filters must be removed before their parents).
self::createMutateOperationsForRemovingListingGroupFiltersTree(
$existingListingGroupFilters
)
);
}
}
$mutateOperations[] = self::createMutateOperationForRoot(
$customerId,
$assetGroupId,
self::LISTING_GROUP_ROOT_TEMPORARY_ID
);
// The temporary ID to be used for creating subdivisions and units.
static $tempId = self::LISTING_GROUP_ROOT_TEMPORARY_ID - 1;
$mutateOperations[] = self::createMutateOperationForUnit(
$customerId,
$assetGroupId,
$tempId--,
self::LISTING_GROUP_ROOT_TEMPORARY_ID,
new ListingGroupFilterDimension([
'product_condition' => new ProductCondition([
'condition' => ListingGroupFilterProductCondition::PBNEW
])
])
);
$mutateOperations[] = self::createMutateOperationForUnit(
$customerId,
$assetGroupId,
$tempId--,
self::LISTING_GROUP_ROOT_TEMPORARY_ID,
new ListingGroupFilterDimension([
'product_condition' => new ProductCondition([
'condition' => ListingGroupFilterProductCondition::USED
])
])
);
// We save this ID to create child nodes underneath it.
$conditionOtherSubdivisionId = $tempId--;
// We're calling createMutateOperationForSubdivision() because this listing group will
// have children.
$mutateOperations[] = self::createMutateOperationForSubdivision(
$customerId,
$assetGroupId,
$conditionOtherSubdivisionId,
self::LISTING_GROUP_ROOT_TEMPORARY_ID,
new ListingGroupFilterDimension([
// All sibling nodes must have the same dimension type. We use an empty
// ProductCondition to indicate that this is an "Other" partition.
'product_condition' => new ProductCondition()
])
);
$mutateOperations[] = self::createMutateOperationForUnit(
$customerId,
$assetGroupId,
$tempId--,
$conditionOtherSubdivisionId,
new ListingGroupFilterDimension(
['product_brand' => new ProductBrand(['value' => 'CoolBrand'])]
)
);
$mutateOperations[] = self::createMutateOperationForUnit(
$customerId,
$assetGroupId,
$tempId--,
$conditionOtherSubdivisionId,
new ListingGroupFilterDimension([
'product_brand' => new ProductBrand(['value' => 'CheapBrand'])
])
);
$mutateOperations[] = self::createMutateOperationForUnit(
$customerId,
$assetGroupId,
$tempId--,
$conditionOtherSubdivisionId,
// All other product brands.
new ListingGroupFilterDimension(['product_brand' => new ProductBrand()])
);
// Issues a mutate request to create everything and prints its information.
$googleAdsServiceClient = $googleAdsClient->getGoogleAdsServiceClient();
$response = $googleAdsServiceClient->mutate(
$customerId,
$mutateOperations
);
self::printResponseDetails($mutateOperations, $response);
}
// [END add_performance_max_product_listing_group_tree]
// [START add_performance_max_product_listing_group_tree_7]
/**
* Fetches all of the asset group listing group filters in an asset group.
*
* @param GoogleAdsClient $googleAdsClient the Google Ads API client
* @param int $customerId the customer ID
* @param string $assetGroupResourceName the resource name of the asset group
* @return AssetGroupListingGroupFilter[] the list of asset group listing group filters
*/
private static function getAllExistingListingGroupFilterAssetsInAssetGroup(
GoogleAdsClient $googleAdsClient,
int $customerId,
string $assetGroupResourceName
): array {
$googleAdsServiceClient = $googleAdsClient->getGoogleAdsServiceClient();
// Creates a query that retrieves asset group listing group filters.
// The limit to the number of listing group filters permitted in a Performance
// Max campaign can be found here:
// https://developers.google.com/google-ads/api/docs/best-practices/system-limits.
$query = sprintf(
'SELECT asset_group_listing_group_filter.resource_name, '
. 'asset_group_listing_group_filter.parent_listing_group_filter '
. 'FROM asset_group_listing_group_filter '
. 'WHERE asset_group_listing_group_filter.asset_group = "%s"',
$assetGroupResourceName
);
// Issues a search request by specifying page size.
$response =
$googleAdsServiceClient->search($customerId, $query, ['pageSize' => self::PAGE_SIZE]);
$assetGroupListingGroupFilters = [];
// Iterates over all rows in all pages to get an asset group listing group filter.
foreach ($response->iterateAllElements() as $googleAdsRow) {
/** @var GoogleAdsRow $googleAdsRow */
$assetGroupListingGroupFilters[] = $googleAdsRow->getAssetGroupListingGroupFilter();
}
return $assetGroupListingGroupFilters;
}
// [END add_performance_max_product_listing_group_tree_7]
/**
* Creates mutate operations for removing an existing tree of asset group listing group filters.
*
* Asset group listing group filters must be removed in a specific order: all of the children
* of a filter must be removed before the filter itself, otherwise the API will return an
* error.
*
* @param AssetGroupListingGroupFilter[] $assetGroupListingGroupFilters the existing asset
* group listing group filters
* @return MutateOperation[] the list of MutateOperations to remove all listing groups
*/
private static function createMutateOperationsForRemovingListingGroupFiltersTree(
array $assetGroupListingGroupFilters
): array {
if (empty($assetGroupListingGroupFilters)) {
throw new \UnexpectedValueException('No listing group filters to remove');
}
$resourceNamesToListingGroupFilters = [];
$parentsToChildren = [];
$rootResourceName = null;
foreach ($assetGroupListingGroupFilters as $assetGroupListingGroupFilter) {
$resourceNamesToListingGroupFilters[$assetGroupListingGroupFilter->getResourceName()] =
$assetGroupListingGroupFilter;
// When the node has no parent, it means it's the root node, which is treated
// differently.
if (empty($assetGroupListingGroupFilter->getParentListingGroupFilter())) {
if (!is_null($rootResourceName)) {
throw new \UnexpectedValueException('More than one root node found.');
}
$rootResourceName = $assetGroupListingGroupFilter->getResourceName();
continue;
}
$parentResourceName = $assetGroupListingGroupFilter->getParentListingGroupFilter();
$siblings = [];
// Checks to see if we've already visited a sibling in this group and fetches it.
if (array_key_exists($parentResourceName, $parentsToChildren)) {
$siblings = $parentsToChildren[$parentResourceName];
}
$siblings[] = $assetGroupListingGroupFilter->getResourceName();
$parentsToChildren[$parentResourceName] = $siblings;
}
// [START add_performance_max_product_listing_group_tree_2]
return self::createMutateOperationsForRemovingDescendents(
$rootResourceName,
$parentsToChildren
);
// [END add_performance_max_product_listing_group_tree_2]
}
// [START add_performance_max_product_listing_group_tree_3]
/**
* Creates a list of mutate operations that remove all the descendents of the specified
* asset group listing group filter's resource name. The order of removal is post-order,
* where all the children (and their children, recursively) are removed first. Then,
* the node itself is removed.
*
* @param string $assetGroupListingGroupFilterResourceName the resource name of the root of
* listing group tree
* @param array $parentsToChildren the map from parent resource names to children resource
* names
* @return MutateOperation[] the list of MutateOperations to remove all listing groups
*/
private static function createMutateOperationsForRemovingDescendents(
string $assetGroupListingGroupFilterResourceName,
array $parentsToChildren
): array {
$operations = [];
if (array_key_exists($assetGroupListingGroupFilterResourceName, $parentsToChildren)) {
foreach ($parentsToChildren[$assetGroupListingGroupFilterResourceName] as $child) {
$operations = array_merge(
$operations,
self::createMutateOperationsForRemovingDescendents($child, $parentsToChildren)
);
}
}
$operations[] = new MutateOperation([
'asset_group_listing_group_filter_operation'
=> new AssetGroupListingGroupFilterOperation([
'remove' => $assetGroupListingGroupFilterResourceName
])
]);
return $operations;
}
// [END add_performance_max_product_listing_group_tree_3]
// [START add_performance_max_product_listing_group_tree_4]
/**
* Creates a mutate operation that creates a root asset group listing group filter for the
* factory's asset group.
*
* The root node or partition is the default, which is displayed as "All Products".
*
* @param int $customerId the customer ID
* @param int $assetGroupId the asset group ID
* @param int $rootListingGroupId the root listing group ID
* @return MutateOperation the mutate operation for creating the root
*/
private static function createMutateOperationForRoot(
int $customerId,
int $assetGroupId,
int $rootListingGroupId
): MutateOperation {
$assetGroupListingGroupFilter = new AssetGroupListingGroupFilter([
'resource_name' => ResourceNames::forAssetGroupListingGroupFilter(
$customerId,
$assetGroupId,
$rootListingGroupId
),
'asset_group' => ResourceNames::forAssetGroup($customerId, $assetGroupId),
// Since this is the root node, do not set the 'parent_listing_group_filter' field. For
// all other nodes, this would refer to the parent listing group filter resource
// name.
// Unlike AddPerformanceMaxRetailCampaign, the type for the root node here must
// be SUBDIVISION because we add child partitions under it.
'type' => ListingGroupFilterType::SUBDIVISION,
// Because this is a Performance Max campaign for retail, we need to specify
// that this is in the shopping vertical.
'vertical' => ListingGroupFilterVertical::SHOPPING
]);
return new MutateOperation([
'asset_group_listing_group_filter_operation'
=> new AssetGroupListingGroupFilterOperation([
'create' => $assetGroupListingGroupFilter
])
]);
}
// [END add_performance_max_product_listing_group_tree_4]
// [START add_performance_max_product_listing_group_tree_5]
/**
* Creates a mutate operation that creates a intermediate asset group listing group filter.
*
* @param int $customerId the customer ID
* @param int $assetGroupId the asset group ID
* @param int $assetGroupListingGroupFilterId the ID of the asset group listing group filter to
* be created
* @param int $parentId the ID of the parent of asset group listing group filter to be created
* @param ListingGroupFilterDimension $listingGroupFilterDimension the listing group
* filter dimension to associate with the asset group listing group filter
* @return MutateOperation the mutate operation for creating a subdivision
*/
private static function createMutateOperationForSubdivision(
int $customerId,
int $assetGroupId,
int $assetGroupListingGroupFilterId,
int $parentId,
ListingGroupFilterDimension $listingGroupFilterDimension
): MutateOperation {
$assetGroupListingGroupFilter = new AssetGroupListingGroupFilter([
'resource_name' => ResourceNames::forAssetGroupListingGroupFilter(
$customerId,
$assetGroupId,
$assetGroupListingGroupFilterId
),
'asset_group' => ResourceNames::forAssetGroup($customerId, $assetGroupId),
// Sets the type as a SUBDIVISION, which will allow the node to be the parent of
// another sub-tree.
'type' => ListingGroupFilterType::SUBDIVISION,
// Because this is a Performance Max campaign for retail, we need to specify
// that this is in the shopping vertical.
'vertical' => ListingGroupFilterVertical::SHOPPING,
'parent_listing_group_filter' => ResourceNames::forAssetGroupListingGroupFilter(
$customerId,
$assetGroupId,
$parentId
),
// Case values contain the listing dimension used for the node.
'case_value' => $listingGroupFilterDimension
]);
return new MutateOperation([
'asset_group_listing_group_filter_operation'
=> new AssetGroupListingGroupFilterOperation([
'create' => $assetGroupListingGroupFilter
])
]);
}
// [END add_performance_max_product_listing_group_tree_5]
// [START add_performance_max_product_listing_group_tree_6]
/**
* Creates a mutate operation that creates a child asset group listing group filter (unit
* node).
*
* Use this method if the filter won't have child filters. Otherwise, use
* createMutateOperationForSubdivision().
*
* @param int $customerId the customer ID
* @param int $assetGroupId the asset group ID
* @param int $assetGroupListingGroupFilterId the ID of the asset group listing group filter to
* be created
* @param int $parentId the ID of the parent of asset group listing group filter to be
* created
* @param ListingGroupFilterDimension $listingGroupFilterDimension the listing group
* filter dimension to associate with the asset group listing group filter
* @return MutateOperation the mutate operation for creating a unit
*/
private static function createMutateOperationForUnit(
int $customerId,
int $assetGroupId,
int $assetGroupListingGroupFilterId,
string $parentId,
ListingGroupFilterDimension $listingGroupFilterDimension
): MutateOperation {
$assetGroupListingGroupFilter = new AssetGroupListingGroupFilter([
'resource_name' => ResourceNames::forAssetGroupListingGroupFilter(
$customerId,
$assetGroupId,
$assetGroupListingGroupFilterId
),
'asset_group' => ResourceNames::forAssetGroup($customerId, $assetGroupId),
'parent_listing_group_filter' => ResourceNames::forAssetGroupListingGroupFilter(
$customerId,
$assetGroupId,
$parentId
),
// Sets the type as a UNIT_INCLUDED to indicate that this asset group listing group
// filter won't have children.
'type' => ListingGroupFilterType::UNIT_INCLUDED,
// Because this is a Performance Max campaign for retail, we need to specify
// that this is in the shopping vertical.
'vertical' => ListingGroupFilterVertical::SHOPPING,
'case_value' => $listingGroupFilterDimension
]);
return new MutateOperation([
'asset_group_listing_group_filter_operation'
=> new AssetGroupListingGroupFilterOperation([
'create' => $assetGroupListingGroupFilter
])
]);
}
// [END add_performance_max_product_listing_group_tree_6]
/**
* Prints the details of a mutate google ads response. Parses the "response" oneof field name
* and uses it to extract the new entity's name and resource name.
*
* @param MutateOperation[] $mutateOperations the submitted mutate operations
* @param MutateGoogleAdsResponse $mutateGoogleAdsResponse the mutate Google Ads response
*/
private static function printResponseDetails(
array $mutateOperations,
MutateGoogleAdsResponse $mutateGoogleAdsResponse
): void {
foreach (
$mutateGoogleAdsResponse->getMutateOperationResponses() as $i => $operationResponse
) {
/** @var MutateOperationResponse $operationResponse */
if (
$operationResponse->getResponse()
!== 'asset_group_listing_group_filter_result'
) {
// Trims the substring "_result" from the end of the entity name.
printf(
"Unsupported entity type: %s.%s",
substr($operationResponse->getResponse(), 0, -strlen('_result')),
PHP_EOL
);
continue;
}
$operation = $mutateOperations[$i]->getAssetGroupListingGroupFilterOperation();
$getter = Serializer::getGetter($operationResponse->getResponse());
switch ($operation->getOperation()) {
case 'create':
printf(
"Created an asset group listing group filter with resource name: "
. " '%s'.%s",
$operationResponse->$getter()->getResourceName(),
PHP_EOL
);
break;
case 'remove':
printf(
"Removed an asset group listing group filter with resource name: "
. " '%s'.%s",
$operationResponse->$getter()->getResourceName(),
PHP_EOL
);
break;
default:
printf(
"Unsupported operation type: '%s'.%s",
$operation->getOperation(),
PHP_EOL
);
}
}
}
}
AddPerformanceMaxProductListingGroupTree::main();