Completed
Pull Request — master (#39)
by Tim
03:12
created

getEavAttributeByIsUserDefined()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 0
CRAP Score 2

Importance

Changes 0
Metric Value
dl 0
loc 4
ccs 0
cts 4
cp 0
rs 10
c 0
b 0
f 0
cc 1
eloc 2
nc 1
nop 1
crap 2
1
<?php
2
3
/**
4
 * TechDivision\Import\Product\Services\ProductBunchProcessor
5
 *
6
 * NOTICE OF LICENSE
7
 *
8
 * This source file is subject to the Open Software License (OSL 3.0)
9
 * that is available through the world-wide-web at this URL:
10
 * http://opensource.org/licenses/osl-3.0.php
11
 *
12
 * PHP version 5
13
 *
14
 * @author    Tim Wagner <[email protected]>
15
 * @copyright 2016 TechDivision GmbH <[email protected]>
16
 * @license   http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
17
 * @link      https://github.com/techdivision/import-product
18
 * @link      http://www.techdivision.com
19
 */
20
21
namespace TechDivision\Import\Product\Services;
22
23
/**
24
 * The product bunch processor implementation.
25
 *
26
 * @author    Tim Wagner <[email protected]>
27
 * @copyright 2016 TechDivision GmbH <[email protected]>
28
 * @license   http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
29
 * @link      https://github.com/techdivision/import-product
30
 * @link      http://www.techdivision.com
31
 */
32
class ProductBunchProcessor implements ProductBunchProcessorInterface
33
{
34
35
    /**
36
     * A PDO connection initialized with the values from the Doctrine EntityManager.
37
     *
38
     * @var \PDO
39
     */
40
    protected $connection;
41
42
    /**
43
     * The repository to access EAV attribute option values.
44
     *
45
     * @var \TechDivision\Import\Product\Repositories\EavAttributeOptionValueRepository
46
     */
47
    protected $eavAttributeOptionValueRepository;
48
49
    /**
50
     * The repository to access EAV attributes.
51
     *
52
     * @var \TechDivision\Import\Repositories\EavAttributeRepository
53
     */
54
    protected $eavAttributeRepository;
55
56
    /**
57
     * The action for product CRUD methods.
58
     *
59
     * @var \TechDivision\Import\Product\Actions\ProductAction
60
     */
61
    protected $productAction;
62
63
    /**
64
     * The action for product varchar attribute CRUD methods.
65
     *
66
     * @var \TechDivision\Import\Product\Actions\ProductVarcharAction
67
     */
68
    protected $productVarcharAction;
69
70
    /**
71
     * The action for product text attribute CRUD methods.
72
     *
73
     * @var \TechDivision\Import\Product\Actions\ProductTextAction
74
     */
75
    protected $productTextAction;
76
77
    /**
78
     * The action for product int attribute CRUD methods.
79
     *
80
     * @var \TechDivision\Import\Product\Actions\ProductIntAction
81
     */
82
    protected $productIntAction;
83
84
    /**
85
     * The action for product decimal attribute CRUD methods.
86
     *
87
     * @var \TechDivision\Import\Product\Actions\ProductDecimalAction
88
     */
89
    protected $productDecimalAction;
90
91
    /**
92
     * The action for product datetime attribute CRUD methods.
93
     *
94
     * @var \TechDivision\Import\Product\Actions\ProductDatetimeAction
95
     */
96
    protected $productDatetimeAction;
97
98
    /**
99
     * The action for product website CRUD methods.
100
     *
101
     * @var \TechDivision\Import\Product\Actions\ProductWebsiteAction
102
     */
103
    protected $productWebsiteAction;
104
105
    /**
106
     * The action for category product relation CRUD methods.
107
     *
108
     * @var \TechDivision\Import\Product\Actions\CategoryProductAction
109
     */
110
    protected $categoryProductAction;
111
112
    /**
113
     * The action for stock item CRUD methods.
114
     *
115
     * @var \TechDivision\Import\Product\Actions\StockItemAction
116
     */
117
    protected $stockItemAction;
118
119
    /**
120
     * The action for stock status CRUD methods.
121
     *
122
     * @var \TechDivision\Import\Product\Actions\StockStatusAction
123
     */
124
    protected $stockStatusAction;
125
126
    /**
127
     * The action for URL rewrite CRUD methods.
128
     *
129
     * @var \TechDivision\Import\Product\Actions\UrlRewriteAction
130
     */
131
    protected $urlRewriteAction;
132
133
    /**
134
     * The action for URL rewrite product category CRUD methods.
135
     *
136
     * @var \TechDivision\Import\Product\Actions\UrlRewriteProductCategoryAction
137
     */
138
    protected $urlRewriteProductCategoryAction;
139
140
    /**
141
     * The repository to load the products with.
142
     *
143
     * @var \TechDivision\Import\Product\Repositories\ProductRepository
144
     */
145
    protected $productRepository;
146
147
    /**
148
     * The repository to load the product website relations with.
149
     *
150
     * @var \TechDivision\Import\Product\Repositories\ProductWebsiteRepository
151
     */
152
    protected $productWebsiteRepository;
153
154
    /**
155
     * The repository to load the product datetime attribute with.
156
     *
157
     * @var \TechDivision\Import\Product\Repositories\ProductDatetimeRepository
158
     */
159
    protected $productDatetimeRepository;
160
161
    /**
162
     * The repository to load the product decimal attribute with.
163
     *
164
     * @var \TechDivision\Import\Product\Repositories\ProductDecimalRepository
165
     */
166
    protected $productDecimalRepository;
167
168
    /**
169
     * The repository to load the product integer attribute with.
170
     *
171
     * @var \TechDivision\Import\Product\Repositories\ProductIntRepository
172
     */
173
    protected $productIntRepository;
174
175
    /**
176
     * The repository to load the product text attribute with.
177
     *
178
     * @var \TechDivision\Import\Product\Repositories\ProductTextRepository
179
     */
180
    protected $productTextRepository;
181
182
    /**
183
     * The repository to load the product varchar attribute with.
184
     *
185
     * @var \TechDivision\Import\Product\Repositories\ProductVarcharRepository
186
     */
187
    protected $productVarcharRepository;
188
189
    /**
190
     * The repository to load the category product relations with.
191
     *
192
     * @var \TechDivision\Import\Product\Repositories\CategoryProductRepository
193
     */
194
    protected $categoryProductRepository;
195
196
    /**
197
     * The repository to load the stock status with.
198
     *
199
     * @var \TechDivision\Import\Product\Repositories\StockStatusRepository
200
     */
201
    protected $stockStatusRepository;
202
203
    /**
204
     * The repository to load the stock item with.
205
     *
206
     * @var \TechDivision\Import\Product\Repositories\StockItemRepository
207
     */
208
    protected $stockItemRepository;
209
210
    /**
211
     * The repository to load the URL rewrites with.
212
     *
213
     * @var \TechDivision\Import\Product\Repositories\UrlRewriteRepository
214
     */
215
    protected $urlRewriteRepository;
216
217
    /**
218
     * The repository to load the URL rewrite product category relations with.
219
     *
220
     * @var \TechDivision\Import\Product\Repositories\UrlRewriteProductCategoryRepository
221
     */
222
    protected $urlRewriteProductCategoryRepository;
223
224
    /**
225
     * Set's the passed connection.
226
     *
227
     * @param \PDO $connection The connection to set
228
     *
229
     * @return void
230
     */
231
    public function setConnection(\PDO $connection)
232
    {
233
        $this->connection = $connection;
234
    }
235
236
    /**
237
     * Return's the connection.
238
     *
239
     * @return \PDO The connection instance
240
     */
241
    public function getConnection()
242
    {
243
        return $this->connection;
244
    }
245
246
    /**
247
     * Turns off autocommit mode. While autocommit mode is turned off, changes made to the database via the PDO
248
     * object instance are not committed until you end the transaction by calling ProductProcessor::commit().
249
     * Calling ProductProcessor::rollBack() will roll back all changes to the database and return the connection
250
     * to autocommit mode.
251
     *
252
     * @return boolean Returns TRUE on success or FALSE on failure
253
     * @link http://php.net/manual/en/pdo.begintransaction.php
254
     */
255
    public function beginTransaction()
256
    {
257
        return $this->connection->beginTransaction();
258
    }
259
260
    /**
261
     * Commits a transaction, returning the database connection to autocommit mode until the next call to
262
     * ProductProcessor::beginTransaction() starts a new transaction.
263
     *
264
     * @return boolean Returns TRUE on success or FALSE on failure
265
     * @link http://php.net/manual/en/pdo.commit.php
266
     */
267
    public function commit()
268
    {
269
        return $this->connection->commit();
270
    }
271
272
    /**
273
     * Rolls back the current transaction, as initiated by ProductProcessor::beginTransaction().
274
     *
275
     * If the database was set to autocommit mode, this function will restore autocommit mode after it has
276
     * rolled back the transaction.
277
     *
278
     * Some databases, including MySQL, automatically issue an implicit COMMIT when a database definition
279
     * language (DDL) statement such as DROP TABLE or CREATE TABLE is issued within a transaction. The implicit
280
     * COMMIT will prevent you from rolling back any other changes within the transaction boundary.
281
     *
282
     * @return boolean Returns TRUE on success or FALSE on failure
283
     * @link http://php.net/manual/en/pdo.rollback.php
284
     */
285
    public function rollBack()
286
    {
287
        return $this->connection->rollBack();
288
    }
289
290
    /**
291
     * Set's the repository to access EAV attribute option values.
292
     *
293
     * @param \TechDivision\Import\Product\Repositories\EavAttributeOptionValueRepository $eavAttributeOptionValueRepository The repository to access EAV attribute option values
294
     *
295
     * @return void
296
     */
297
    public function setEavAttributeOptionValueRepository($eavAttributeOptionValueRepository)
298
    {
299
        $this->eavAttributeOptionValueRepository = $eavAttributeOptionValueRepository;
300
    }
301
302
    /**
303
     * Return's the repository to access EAV attribute option values.
304
     *
305
     * @return \TechDivision\Import\Product\Repositories\EavAttributeOptionValueRepository The repository instance
306
     */
307
    public function getEavAttributeOptionValueRepository()
308
    {
309
        return $this->eavAttributeOptionValueRepository;
310
    }
311
312
    /**
313
     * Set's the repository to access EAV attributes.
314
     *
315
     * @param \TechDivision\Import\Repositories\EavAttributeRepository $eavAttributeRepository The repository to access EAV attributes
316
     *
317
     * @return void
318
     */
319
    public function setEavAttributeRepository($eavAttributeRepository)
320
    {
321
        $this->eavAttributeRepository = $eavAttributeRepository;
322
    }
323
324
    /**
325
     * Return's the repository to access EAV attributes.
326
     *
327
     * @return \TechDivision\Import\Repositories\EavAttributeRepository The repository instance
328
     */
329
    public function getEavAttributeRepository()
330
    {
331
        return $this->eavAttributeRepository;
332
    }
333
334
    /**
335
     * Return's an array with the available EAV attributes for the passed is user defined flag.
336
     *
337
     * @param integer $isUserDefined The flag itself
338
     *
339
     * @return array The array with the EAV attributes matching the passed flag
340
     */
341
    public function getEavAttributeByIsUserDefined($isUserDefined = 1)
342
    {
343
        return $this->getEavAttributeRepository()->findAllByIsUserDefined($isUserDefined);
0 ignored issues
show
Bug introduced by
The method findAllByIsUserDefined() does not seem to exist on object<TechDivision\Impo...EavAttributeRepository>.

This check looks for calls to methods that do not seem to exist on a given type. It looks for the method on the type itself as well as in inherited classes or implemented interfaces.

This is most likely a typographical error or the method has been renamed.

Loading history...
344
    }
345
346
    /**
347
     * Set's the action with the product CRUD methods.
348
     *
349
     * @param \TechDivision\Import\Product\Actions\ProductAction $productAction The action with the product CRUD methods
350
     *
351
     * @return void
352
     */
353
    public function setProductAction($productAction)
354
    {
355
        $this->productAction = $productAction;
356
    }
357
358
    /**
359
     * Return's the action with the product CRUD methods.
360
     *
361
     * @return \TechDivision\Import\Product\Actions\ProductAction The action instance
362
     */
363
    public function getProductAction()
364
    {
365
        return $this->productAction;
366
    }
367
368
    /**
369
     * Set's the action with the product varchar attribute CRUD methods.
370
     *
371
     * @param \TechDivision\Import\Product\Actions\ProductVarcharAction $productVarcharAction The action with the product varchar attriute CRUD methods
372
     *
373
     * @return void
374
     */
375
    public function setProductVarcharAction($productVarcharAction)
376
    {
377
        $this->productVarcharAction = $productVarcharAction;
378
    }
379
380
    /**
381
     * Return's the action with the product varchar attribute CRUD methods.
382
     *
383
     * @return \TechDivision\Import\Product\Actions\ProductVarcharAction The action instance
384
     */
385
    public function getProductVarcharAction()
386
    {
387
        return $this->productVarcharAction;
388
    }
389
390
    /**
391
     * Set's the action with the product text attribute CRUD methods.
392
     *
393
     * @param \TechDivision\Import\Product\Actions\ProductTextAction $productTextAction The action with the product text attriute CRUD methods
394
     *
395
     * @return void
396
     */
397
    public function setProductTextAction($productTextAction)
398
    {
399
        $this->productTextAction = $productTextAction;
400
    }
401
402
    /**
403
     * Return's the action with the product text attribute CRUD methods.
404
     *
405
     * @return \TechDivision\Import\Product\Actions\ProductTextAction The action instance
406
     */
407
    public function getProductTextAction()
408
    {
409
        return $this->productTextAction;
410
    }
411
412
    /**
413
     * Set's the action with the product int attribute CRUD methods.
414
     *
415
     * @param \TechDivision\Import\Product\Actions\ProductIntAction $productIntAction The action with the product int attriute CRUD methods
416
     *
417
     * @return void
418
     */
419
    public function setProductIntAction($productIntAction)
420
    {
421
        $this->productIntAction = $productIntAction;
422
    }
423
424
    /**
425
     * Return's the action with the product int attribute CRUD methods.
426
     *
427
     * @return \TechDivision\Import\Product\Actions\ProductIntAction The action instance
428
     */
429
    public function getProductIntAction()
430
    {
431
        return $this->productIntAction;
432
    }
433
434
    /**
435
     * Set's the action with the product decimal attribute CRUD methods.
436
     *
437
     * @param \TechDivision\Import\Product\Actions\ProductDecimalAction $productDecimalAction The action with the product decimal attriute CRUD methods
438
     *
439
     * @return void
440
     */
441
    public function setProductDecimalAction($productDecimalAction)
442
    {
443
        $this->productDecimalAction = $productDecimalAction;
444
    }
445
446
    /**
447
     * Return's the action with the product decimal attribute CRUD methods.
448
     *
449
     * @return \TechDivision\Import\Product\Actions\ProductDecimalAction The action instance
450
     */
451
    public function getProductDecimalAction()
452
    {
453
        return $this->productDecimalAction;
454
    }
455
456
    /**
457
     * Set's the action with the product datetime attribute CRUD methods.
458
     *
459
     * @param \TechDivision\Import\Product\Actions\ProductDatetimeAction $productDatetimeAction The action with the product datetime attriute CRUD methods
460
     *
461
     * @return void
462
     */
463
    public function setProductDatetimeAction($productDatetimeAction)
464
    {
465
        $this->productDatetimeAction = $productDatetimeAction;
466
    }
467
468
    /**
469
     * Return's the action with the product datetime attribute CRUD methods.
470
     *
471
     * @return \TechDivision\Import\Product\Actions\ProductDatetimeAction The action instance
472
     */
473
    public function getProductDatetimeAction()
474
    {
475
        return $this->productDatetimeAction;
476
    }
477
478
    /**
479
     * Set's the action with the product website CRUD methods.
480
     *
481
     * @param \TechDivision\Import\Product\Actions\ProductWebsiteAction $productWebsiteAction The action with the product website CRUD methods
482
     *
483
     * @return void
484
     */
485
    public function setProductWebsiteAction($productWebsiteAction)
486
    {
487
        $this->productWebsiteAction = $productWebsiteAction;
488
    }
489
490
    /**
491
     * Return's the action with the product website CRUD methods.
492
     *
493
     * @return \TechDivision\Import\Product\Actions\ProductWebsiteAction The action instance
494
     */
495
    public function getProductWebsiteAction()
496
    {
497
        return $this->productWebsiteAction;
498
    }
499
500
    /**
501
     * Set's the action with the category product relation CRUD methods.
502
     *
503
     * @param \TechDivision\Import\Product\Actions\ProductCategoryAction $categoryProductAction The action with the category product relation CRUD methods
504
     *
505
     * @return void
506
     */
507
    public function setCategoryProductAction($categoryProductAction)
508
    {
509
        $this->categoryProductAction = $categoryProductAction;
0 ignored issues
show
Documentation Bug introduced by
It seems like $categoryProductAction of type object<TechDivision\Impo...\ProductCategoryAction> is incompatible with the declared type object<TechDivision\Impo...\CategoryProductAction> of property $categoryProductAction.

Our type inference engine has found an assignment to a property that is incompatible with the declared type of that property.

Either this assignment is in error or the assigned type should be added to the documentation/type hint for that property..

Loading history...
510
    }
511
512
    /**
513
     * Return's the action with the category product relation CRUD methods.
514
     *
515
     * @return \TechDivision\Import\Product\Actions\CategoryProductAction The action instance
516
     */
517
    public function getCategoryProductAction()
518
    {
519
        return $this->categoryProductAction;
520
    }
521
522
    /**
523
     * Set's the action with the stock item CRUD methods.
524
     *
525
     * @param \TechDivision\Import\Product\Actions\StockItemAction $stockItemAction The action with the stock item CRUD methods
526
     *
527
     * @return void
528
     */
529
    public function setStockItemAction($stockItemAction)
530
    {
531
        $this->stockItemAction = $stockItemAction;
532
    }
533
534
    /**
535
     * Return's the action with the stock item CRUD methods.
536
     *
537
     * @return \TechDivision\Import\Product\Actions\StockItemAction The action instance
538
     */
539
    public function getStockItemAction()
540
    {
541
        return $this->stockItemAction;
542
    }
543
544
    /**
545
     * Set's the action with the stock status CRUD methods.
546
     *
547
     * @param \TechDivision\Import\Product\Actions\StockStatusAction $stockStatusAction The action with the stock status CRUD methods
548
     *
549
     * @return void
550
     */
551
    public function setStockStatusAction($stockStatusAction)
552
    {
553
        $this->stockStatusAction = $stockStatusAction;
554
    }
555
556
    /**
557
     * Return's the action with the stock status CRUD methods.
558
     *
559
     * @return \TechDivision\Import\Product\Actions\StockStatusAction The action instance
560
     */
561
    public function getStockStatusAction()
562
    {
563
        return $this->stockStatusAction;
564
    }
565
566
    /**
567
     * Set's the action with the URL rewrite CRUD methods.
568
     *
569
     * @param \TechDivision\Import\Product\Actions\UrlRewriteAction $urlRewriteAction The action with the URL rewrite CRUD methods
570
     *
571
     * @return void
572
     */
573
    public function setUrlRewriteAction($urlRewriteAction)
574
    {
575
        $this->urlRewriteAction = $urlRewriteAction;
576
    }
577
578
    /**
579
     * Return's the action with the URL rewrite CRUD methods.
580
     *
581
     * @return \TechDivision\Import\Product\Actions\UrlRewriteAction The action instance
582
     */
583
    public function getUrlRewriteAction()
584
    {
585
        return $this->urlRewriteAction;
586
    }
587
588
    /**
589
     * Set's the action with the URL rewrite product category CRUD methods.
590
     *
591
     * @param \TechDivision\Import\Product\Actions\UrlRewriteAction $urlRewriteProductCategoryAction The action with the URL rewrite CRUD methods
592
     *
593
     * @return void
594
     */
595
    public function setUrlRewriteProductCategoryAction($urlRewriteProductCategoryAction)
596
    {
597
        $this->urlRewriteProductCategoryAction = $urlRewriteProductCategoryAction;
0 ignored issues
show
Documentation Bug introduced by
It seems like $urlRewriteProductCategoryAction of type object<TechDivision\Impo...tions\UrlRewriteAction> is incompatible with the declared type object<TechDivision\Impo...eProductCategoryAction> of property $urlRewriteProductCategoryAction.

Our type inference engine has found an assignment to a property that is incompatible with the declared type of that property.

Either this assignment is in error or the assigned type should be added to the documentation/type hint for that property..

Loading history...
598
    }
599
600
    /**
601
     * Return's the action with the URL rewrite product category CRUD methods.
602
     *
603
     * @return \TechDivision\Import\Product\Actions\UrlRewriteProductCategoryAction The action instance
604
     */
605
    public function getUrlRewriteProductCategoryAction()
606
    {
607
        return $this->urlRewriteProductCategoryAction;
608
    }
609
610
    /**
611
     * Set's the repository to load the products with.
612
     *
613
     * @param \TechDivision\Import\Product\Repositories\ProductRepository $productRepository The repository instance
614
     *
615
     * @return void
616
     */
617
    public function setProductRepository($productRepository)
618
    {
619
        $this->productRepository = $productRepository;
620
    }
621
622
    /**
623
     * Return's the repository to load the products with.
624
     *
625
     * @return \TechDivision\Import\Product\Repositories\ProductRepository The repository instance
626
     */
627
    public function getProductRepository()
628
    {
629
        return $this->productRepository;
630
    }
631
632
    /**
633
     * Set's the repository to load the product website relations with.
634
     *
635
     * @param \TechDivision\Import\Product\Repositories\ProductWebsiteRepository $productWebsiteRepository The repository instance
636
     *
637
     * @return void
638
     */
639
    public function setProductWebsiteRepository($productWebsiteRepository)
640
    {
641
        $this->productWebsiteRepository = $productWebsiteRepository;
642
    }
643
644
    /**
645
     * Return's the repository to load the product website relations with.
646
     *
647
     * @return \TechDivision\Import\Product\Repositories\ProductWebsiteRepository The repository instance
648
     */
649
    public function getProductWebsiteRepository()
650
    {
651
        return $this->productWebsiteRepository;
652
    }
653
654
    /**
655
     * Set's the repository to load the product datetime attribute with.
656
     *
657
     * @param \TechDivision\Import\Product\Repositories\ProductDatetimeRepository $productDatetimeRepository The repository instance
658
     *
659
     * @return void
660
     */
661
    public function setProductDatetimeRepository($productDatetimeRepository)
662
    {
663
        $this->productDatetimeRepository = $productDatetimeRepository;
664
    }
665
666
    /**
667
     * Return's the repository to load the product datetime attribute with.
668
     *
669
     * @return \TechDivision\Import\Product\Repositories\ProductDatetimeRepository The repository instance
670
     */
671
    public function getProductDatetimeRepository()
672
    {
673
        return $this->productDatetimeRepository;
674
    }
675
676
    /**
677
     * Set's the repository to load the product decimal attribute with.
678
     *
679
     * @param \TechDivision\Import\Product\Repositories\ProductDecimalRepository $productDecimalRepository The repository instance
680
     *
681
     * @return void
682
     */
683
    public function setProductDecimalRepository($productDecimalRepository)
684
    {
685
        $this->productDecimalRepository = $productDecimalRepository;
686
    }
687
688
    /**
689
     * Return's the repository to load the product decimal attribute with.
690
     *
691
     * @return \TechDivision\Import\Product\Repositories\ProductDecimalRepository The repository instance
692
     */
693
    public function getProductDecimalRepository()
694
    {
695
        return $this->productDecimalRepository;
696
    }
697
698
    /**
699
     * Set's the repository to load the product integer attribute with.
700
     *
701
     * @param \TechDivision\Import\Product\Repositories\ProductIntRepository $productIntRepository The repository instance
702
     *
703
     * @return void
704
     */
705
    public function setProductIntRepository($productIntRepository)
706
    {
707
        $this->productIntRepository = $productIntRepository;
708
    }
709
710
    /**
711
     * Return's the repository to load the product integer attribute with.
712
     *
713
     * @return \TechDivision\Import\Product\Repositories\ProductIntRepository The repository instance
714
     */
715
    public function getProductIntRepository()
716
    {
717
        return $this->productIntRepository;
718
    }
719
720
    /**
721
     * Set's the repository to load the product text attribute with.
722
     *
723
     * @param \TechDivision\Import\Product\Repositories\ProductTextRepository $productTextRepository The repository instance
724
     *
725
     * @return void
726
     */
727
    public function setProductTextRepository($productTextRepository)
728
    {
729
        $this->productTextRepository = $productTextRepository;
730
    }
731
732
    /**
733
     * Return's the repository to load the product text attribute with.
734
     *
735
     * @return \TechDivision\Import\Product\Repositories\ProductTextRepository The repository instance
736
     */
737
    public function getProductTextRepository()
738
    {
739
        return $this->productTextRepository;
740
    }
741
742
    /**
743
     * Set's the repository to load the product varchar attribute with.
744
     *
745
     * @param \TechDivision\Import\Product\Repositories\ProductVarcharRepository $productVarcharRepository The repository instance
746
     *
747
     * @return void
748
     */
749
    public function setProductVarcharRepository($productVarcharRepository)
750
    {
751
        $this->productVarcharRepository = $productVarcharRepository;
752
    }
753
754
    /**
755
     * Return's the repository to load the product varchar attribute with.
756
     *
757
     * @return \TechDivision\Import\Product\Repositories\ProductVarcharRepository The repository instance
758
     */
759
    public function getProductVarcharRepository()
760
    {
761
        return $this->productVarcharRepository;
762
    }
763
764
    /**
765
     * Set's the repository to load the category product relations with.
766
     *
767
     * @param \TechDivision\Import\Product\Repositories\CategoryProductRepository $categoryProductRepository The repository instance
768
     *
769
     * @return void
770
     */
771
    public function setCategoryProductRepository($categoryProductRepository)
772
    {
773
        $this->categoryProductRepository = $categoryProductRepository;
774
    }
775
776
    /**
777
     * Return's the repository to load the category product relations with.
778
     *
779
     * @return \TechDivision\Import\Product\Repositories\CategoryProductRepository The repository instance
780
     */
781
    public function getCategoryProductRepository()
782
    {
783
        return $this->categoryProductRepository;
784
    }
785
786
    /**
787
     * Set's the repository to load the stock status with.
788
     *
789
     * @param \TechDivision\Import\Product\Repositories\StockStatusRepository $stockStatusRepository The repository instance
790
     *
791
     * @return void
792
     */
793
    public function setStockStatusRepository($stockStatusRepository)
794
    {
795
        $this->stockStatusRepository = $stockStatusRepository;
796
    }
797
798
    /**
799
     * Return's the repository to load the stock status with.
800
     *
801
     * @return \TechDivision\Import\Product\Repositories\StockStatusRepository The repository instance
802
     */
803
    public function getStockStatusRepository()
804
    {
805
        return $this->stockStatusRepository;
806
    }
807
808
    /**
809
     * Set's the repository to load the stock items with.
810
     *
811
     * @param \TechDivision\Import\Product\Repositories\StockItemRepository $stockItemRepository The repository instance
812
     *
813
     * @return void
814
     */
815
    public function setStockItemRepository($stockItemRepository)
816
    {
817
        $this->stockItemRepository = $stockItemRepository;
818
    }
819
820
    /**
821
     * Return's the repository to load the stock items with.
822
     *
823
     * @return \TechDivision\Import\Product\Repositories\StockItemRepository The repository instance
824
     */
825
    public function getStockItemRepository()
826
    {
827
        return $this->stockItemRepository;
828
    }
829
830
    /**
831
     * Set's the repository to load the URL rewrites with.
832
     *
833
     * @param \TechDivision\Import\Product\Repositories\UrlRewriteRepository $urlRewriteRepository The repository instance
834
     *
835
     * @return void
836
     */
837
    public function setUrlRewriteRepository($urlRewriteRepository)
838
    {
839
        $this->urlRewriteRepository = $urlRewriteRepository;
840
    }
841
842
    /**
843
     * Return's the repository to load the URL rewrites with.
844
     *
845
     * @return \TechDivision\Import\Product\Repositories\UrlRewriteRepository The repository instance
846
     */
847
    public function getUrlRewriteRepository()
848
    {
849
        return $this->urlRewriteRepository;
850
    }
851
852
    /**
853
     * Set's the repository to load the URL rewrite product category relations with.
854
     *
855
     * @param \TechDivision\Import\Product\Repositories\UrlRewriteProductCategoryRepository $urlRewriteProductCategoryRepository The repository instance
856
     *
857
     * @return void
858
     */
859
    public function setUrlRewriteProductCategoryRepository($urlRewriteProductCategoryRepository)
860
    {
861
        $this->urlRewriteProductCategoryRepository = $urlRewriteProductCategoryRepository;
862
    }
863
864
    /**
865
     * Return's the repository to load the URL rewrite product category relations with.
866
     *
867
     * @return \TechDivision\Import\Product\Repositories\UrlRewriteProductCategoryRepository The repository instance
868
     */
869
    public function getUrlRewriteProductCategoryRepository()
870
    {
871
        return $this->urlRewriteProductCategoryRepository;
872
    }
873
874
    /**
875
     * Return's the attribute option value with the passed value and store ID.
876
     *
877
     * @param mixed   $value   The option value
878
     * @param integer $storeId The ID of the store
879
     *
880
     * @return array|boolean The attribute option value instance
881
     */
882
    public function getEavAttributeOptionValueByOptionValueAndStoreId($value, $storeId)
883
    {
884
        return $this->getEavAttributeOptionValueRepository()->findEavAttributeOptionValueByOptionValueAndStoreId($value, $storeId);
885
    }
886
887
    /**
888
     * Return's the URL rewrites for the passed URL entity type and ID.
889
     *
890
     * @param string  $entityType The entity type to load the URL rewrites for
891
     * @param integer $entityId   The entity ID to laod the rewrites for
892
     *
893
     * @return array The URL rewrites
894
     */
895
    public function getUrlRewritesByEntityTypeAndEntityId($entityType, $entityId)
896
    {
897
        return $this->getUrlRewriteRepository()->findAllByEntityTypeAndEntityId($entityType, $entityId);
898
    }
899
900
    /**
901
     * Load's and return's the product with the passed SKU.
902
     *
903
     * @param string $sku The SKU of the product to load
904
     *
905
     * @return array The product
906
     */
907
    public function loadProduct($sku)
908
    {
909
        return $this->getProductRepository()->findOneBySku($sku);
910
    }
911
912
    /**
913
     * Load's and return's the product website relation with the passed product and website ID.
914
     *
915
     * @param string $productId The product ID of the relation
916
     * @param string $websiteId The website ID of the relation
917
     *
918
     * @return array The product website
919
     */
920
    public function loadProductWebsite($productId, $websiteId)
921
    {
922
        return $this->getProductWebsiteRepository()->findOneByProductIdAndWebsite($productId, $websiteId);
923
    }
924
925
    /**
926
     * Return's the category product relation with the passed category/product ID.
927
     *
928
     * @param integer $categoryId The category ID of the category product relation to return
929
     * @param integer $productId  The product ID of the category product relation to return
930
     *
931
     * @return array The category product relation
932
     */
933
    public function loadCategoryProduct($categoryId, $productId)
934
    {
935
        return $this->getCategoryProductRepository()->findOneByCategoryIdAndProductId($categoryId, $productId);
936
    }
937
938
    /**
939
     * Load's and return's the stock status with the passed product/website/stock ID.
940
     *
941
     * @param integer $productId The product ID of the stock status to load
942
     * @param integer $websiteId The website ID of the stock status to load
943
     * @param integer $stockId   The stock ID of the stock status to load
944
     *
945
     * @return array The stock status
946
     */
947
    public function loadStockStatus($productId, $websiteId, $stockId)
948
    {
949
        return $this->getStockStatusRepository()->findOneByProductIdAndWebsiteIdAndStockId($productId, $websiteId, $stockId);
950
    }
951
952
    /**
953
     * Load's and return's the stock status with the passed product/website/stock ID.
954
     *
955
     * @param integer $productId The product ID of the stock item to load
956
     * @param integer $websiteId The website ID of the stock item to load
957
     * @param integer $stockId   The stock ID of the stock item to load
958
     *
959
     * @return array The stock item
960
     */
961
    public function loadStockItem($productId, $websiteId, $stockId)
962
    {
963
        return $this->getStockItemRepository()->findOneByProductIdAndWebsiteIdAndStockId($productId, $websiteId, $stockId);
964
    }
965
966
    /**
967
     * Load's and return's the datetime attribute with the passed entity/attribute/store ID.
968
     *
969
     * @param integer $entityId    The entity ID of the attribute
970
     * @param integer $attributeId The attribute ID of the attribute
971
     * @param integer $storeId     The store ID of the attribute
972
     *
973
     * @return array|null The datetime attribute
974
     */
975
    public function loadProductDatetimeAttribute($entityId, $attributeId, $storeId)
976
    {
977
        return  $this->getProductDatetimeRepository()->findOneByEntityIdAndAttributeIdAndStoreId($entityId, $attributeId, $storeId);
978
    }
979
980
    /**
981
     * Load's and return's the decimal attribute with the passed entity/attribute/store ID.
982
     *
983
     * @param integer $entityId    The entity ID of the attribute
984
     * @param integer $attributeId The attribute ID of the attribute
985
     * @param integer $storeId     The store ID of the attribute
986
     *
987
     * @return array|null The decimal attribute
988
     */
989
    public function loadProductDecimalAttribute($entityId, $attributeId, $storeId)
990
    {
991
        return  $this->getProductDecimalRepository()->findOneByEntityIdAndAttributeIdAndStoreId($entityId, $attributeId, $storeId);
992
    }
993
994
    /**
995
     * Load's and return's the integer attribute with the passed entity/attribute/store ID.
996
     *
997
     * @param integer $entityId    The entity ID of the attribute
998
     * @param integer $attributeId The attribute ID of the attribute
999
     * @param integer $storeId     The store ID of the attribute
1000
     *
1001
     * @return array|null The integer attribute
1002
     */
1003
    public function loadProductIntAttribute($entityId, $attributeId, $storeId)
1004
    {
1005
        return $this->getProductIntRepository()->findOneByEntityIdAndAttributeIdAndStoreId($entityId, $attributeId, $storeId);
1006
    }
1007
1008
    /**
1009
     * Load's and return's the text attribute with the passed entity/attribute/store ID.
1010
     *
1011
     * @param integer $entityId    The entity ID of the attribute
1012
     * @param integer $attributeId The attribute ID of the attribute
1013
     * @param integer $storeId     The store ID of the attribute
1014
     *
1015
     * @return array|null The text attribute
1016
     */
1017
    public function loadProductTextAttribute($entityId, $attributeId, $storeId)
1018
    {
1019
        return $this->getProductTextRepository()->findOneByEntityIdAndAttributeIdAndStoreId($entityId, $attributeId, $storeId);
1020
    }
1021
1022
    /**
1023
     * Load's and return's the varchar attribute with the passed entity/attribute/store ID.
1024
     *
1025
     * @param integer $entityId    The entity ID of the attribute
1026
     * @param integer $attributeId The attribute ID of the attribute
1027
     * @param integer $storeId     The store ID of the attribute
1028
     *
1029
     * @return array|null The varchar attribute
1030
     */
1031
    public function loadProductVarcharAttribute($entityId, $attributeId, $storeId)
1032
    {
1033
        return $this->getProductVarcharRepository()->findOneByEntityIdAndAttributeIdAndStoreId($entityId, $attributeId, $storeId);
1034
    }
1035
1036
    /**
1037
     * Return's the URL rewrite product category relation for the passed
1038
     * product and category ID.
1039
     *
1040
     * @param integer $productId  The product ID to load the URL rewrite product category relation for
1041
     * @param integer $categoryId The category ID to load the URL rewrite product category relation for
1042
     *
1043
     * @return array|false The URL rewrite product category relations
1044
     */
1045
    public function loadUrlRewriteProductCategory($productId, $categoryId)
1046
    {
1047
        return $this->getUrlRewriteProductCategoryRepository()->findOneByProductIdAndCategoryId($productId, $categoryId);
0 ignored issues
show
Comprehensibility Best Practice introduced by
The expression $this->getUrlRewriteProd...roductId, $categoryId); of type array|false adds false to the return on line 1047 which is incompatible with the return type declared by the interface TechDivision\Import\Prod...lRewriteProductCategory of type array|null. It seems like you forgot to handle an error condition.
Loading history...
1048
    }
1049
1050
    /**
1051
     * Persist's the passed product data and return's the ID.
1052
     *
1053
     * @param array       $product The product data to persist
1054
     * @param string|null $name    The name of the prepared statement that has to be executed
1055
     *
1056
     * @return string The ID of the persisted entity
1057
     */
1058
    public function persistProduct($product, $name = null)
1059
    {
1060
        return $this->getProductAction()->persist($product, $name);
0 ignored issues
show
Unused Code introduced by
The call to ProductAction::persist() has too many arguments starting with $name.

This check compares calls to functions or methods with their respective definitions. If the call has more arguments than are defined, it raises an issue.

If a function is defined several times with a different number of parameters, the check may pick up the wrong definition and report false positives. One codebase where this has been known to happen is Wordpress.

In this case you can add the @ignore PhpDoc annotation to the duplicate definition and it will be ignored.

Loading history...
1061
    }
1062
1063
    /**
1064
     * Persist's the passed product varchar attribute.
1065
     *
1066
     * @param array       $attribute The attribute to persist
1067
     * @param string|null $name      The name of the prepared statement that has to be executed
1068
     *
1069
     * @return void
1070
     */
1071
    public function persistProductVarcharAttribute($attribute, $name = null)
1072
    {
1073
        $this->getProductVarcharAction()->persist($attribute, $name);
0 ignored issues
show
Unused Code introduced by
The call to ProductVarcharAction::persist() has too many arguments starting with $name.

This check compares calls to functions or methods with their respective definitions. If the call has more arguments than are defined, it raises an issue.

If a function is defined several times with a different number of parameters, the check may pick up the wrong definition and report false positives. One codebase where this has been known to happen is Wordpress.

In this case you can add the @ignore PhpDoc annotation to the duplicate definition and it will be ignored.

Loading history...
1074
    }
1075
1076
    /**
1077
     * Persist's the passed product integer attribute.
1078
     *
1079
     * @param array       $attribute The attribute to persist
1080
     * @param string|null $name      The name of the prepared statement that has to be executed
1081
     *
1082
     * @return void
1083
     */
1084
    public function persistProductIntAttribute($attribute, $name = null)
1085
    {
1086
        $this->getProductIntAction()->persist($attribute, $name);
0 ignored issues
show
Unused Code introduced by
The call to ProductIntAction::persist() has too many arguments starting with $name.

This check compares calls to functions or methods with their respective definitions. If the call has more arguments than are defined, it raises an issue.

If a function is defined several times with a different number of parameters, the check may pick up the wrong definition and report false positives. One codebase where this has been known to happen is Wordpress.

In this case you can add the @ignore PhpDoc annotation to the duplicate definition and it will be ignored.

Loading history...
1087
    }
1088
1089
    /**
1090
     * Persist's the passed product decimal attribute.
1091
     *
1092
     * @param array       $attribute The attribute to persist
1093
     * @param string|null $name      The name of the prepared statement that has to be executed
1094
     *
1095
     * @return void
1096
     */
1097
    public function persistProductDecimalAttribute($attribute, $name = null)
1098
    {
1099
        $this->getProductDecimalAction()->persist($attribute, $name);
0 ignored issues
show
Unused Code introduced by
The call to ProductDecimalAction::persist() has too many arguments starting with $name.

This check compares calls to functions or methods with their respective definitions. If the call has more arguments than are defined, it raises an issue.

If a function is defined several times with a different number of parameters, the check may pick up the wrong definition and report false positives. One codebase where this has been known to happen is Wordpress.

In this case you can add the @ignore PhpDoc annotation to the duplicate definition and it will be ignored.

Loading history...
1100
    }
1101
1102
    /**
1103
     * Persist's the passed product datetime attribute.
1104
     *
1105
     * @param array       $attribute The attribute to persist
1106
     * @param string|null $name      The name of the prepared statement that has to be executed
1107
     *
1108
     * @return void
1109
     */
1110
    public function persistProductDatetimeAttribute($attribute, $name = null)
1111
    {
1112
        $this->getProductDatetimeAction()->persist($attribute, $name);
0 ignored issues
show
Unused Code introduced by
The call to ProductDatetimeAction::persist() has too many arguments starting with $name.

This check compares calls to functions or methods with their respective definitions. If the call has more arguments than are defined, it raises an issue.

If a function is defined several times with a different number of parameters, the check may pick up the wrong definition and report false positives. One codebase where this has been known to happen is Wordpress.

In this case you can add the @ignore PhpDoc annotation to the duplicate definition and it will be ignored.

Loading history...
1113
    }
1114
1115
    /**
1116
     * Persist's the passed product text attribute.
1117
     *
1118
     * @param array       $attribute The attribute to persist
1119
     * @param string|null $name      The name of the prepared statement that has to be executed
1120
     *
1121
     * @return void
1122
     */
1123
    public function persistProductTextAttribute($attribute, $name = null)
1124
    {
1125
        $this->getProductTextAction()->persist($attribute, $name);
0 ignored issues
show
Unused Code introduced by
The call to ProductTextAction::persist() has too many arguments starting with $name.

This check compares calls to functions or methods with their respective definitions. If the call has more arguments than are defined, it raises an issue.

If a function is defined several times with a different number of parameters, the check may pick up the wrong definition and report false positives. One codebase where this has been known to happen is Wordpress.

In this case you can add the @ignore PhpDoc annotation to the duplicate definition and it will be ignored.

Loading history...
1126
    }
1127
1128
    /**
1129
     * Persist's the passed product website data and return's the ID.
1130
     *
1131
     * @param array       $productWebsite The product website data to persist
1132
     * @param string|null $name           The name of the prepared statement that has to be executed
1133
     *
1134
     * @return void
1135
     */
1136
    public function persistProductWebsite($productWebsite, $name = null)
1137
    {
1138
        $this->getProductWebsiteAction()->persist($productWebsite, $name);
0 ignored issues
show
Unused Code introduced by
The call to ProductWebsiteAction::persist() has too many arguments starting with $name.

This check compares calls to functions or methods with their respective definitions. If the call has more arguments than are defined, it raises an issue.

If a function is defined several times with a different number of parameters, the check may pick up the wrong definition and report false positives. One codebase where this has been known to happen is Wordpress.

In this case you can add the @ignore PhpDoc annotation to the duplicate definition and it will be ignored.

Loading history...
1139
    }
1140
1141
    /**
1142
     * Persist's the passed category product relation.
1143
     *
1144
     * @param array       $categoryProduct The category product relation to persist
1145
     * @param string|null $name            The name of the prepared statement that has to be executed
1146
     *
1147
     * @return void
1148
     */
1149
    public function persistCategoryProduct($categoryProduct, $name = null)
1150
    {
1151
        $this->getCategoryProductAction()->persist($categoryProduct, $name);
0 ignored issues
show
Unused Code introduced by
The call to CategoryProductAction::persist() has too many arguments starting with $name.

This check compares calls to functions or methods with their respective definitions. If the call has more arguments than are defined, it raises an issue.

If a function is defined several times with a different number of parameters, the check may pick up the wrong definition and report false positives. One codebase where this has been known to happen is Wordpress.

In this case you can add the @ignore PhpDoc annotation to the duplicate definition and it will be ignored.

Loading history...
1152
    }
1153
1154
    /**
1155
     * Persist's the passed stock item data and return's the ID.
1156
     *
1157
     * @param array       $stockItem The stock item data to persist
1158
     * @param string|null $name      The name of the prepared statement that has to be executed
1159
     *
1160
     * @return void
1161
     */
1162
    public function persistStockItem($stockItem, $name = null)
1163
    {
1164
        $this->getStockItemAction()->persist($stockItem, $name);
0 ignored issues
show
Unused Code introduced by
The call to StockItemAction::persist() has too many arguments starting with $name.

This check compares calls to functions or methods with their respective definitions. If the call has more arguments than are defined, it raises an issue.

If a function is defined several times with a different number of parameters, the check may pick up the wrong definition and report false positives. One codebase where this has been known to happen is Wordpress.

In this case you can add the @ignore PhpDoc annotation to the duplicate definition and it will be ignored.

Loading history...
1165
    }
1166
1167
    /**
1168
     * Persist's the passed stock status data and return's the ID.
1169
     *
1170
     * @param array       $stockStatus The stock status data to persist
1171
     * @param string|null $name        The name of the prepared statement that has to be executed
1172
     *
1173
     * @return void
1174
     */
1175
    public function persistStockStatus($stockStatus, $name = null)
1176
    {
1177
        $this->getStockStatusAction()->persist($stockStatus, $name);
0 ignored issues
show
Unused Code introduced by
The call to StockStatusAction::persist() has too many arguments starting with $name.

This check compares calls to functions or methods with their respective definitions. If the call has more arguments than are defined, it raises an issue.

If a function is defined several times with a different number of parameters, the check may pick up the wrong definition and report false positives. One codebase where this has been known to happen is Wordpress.

In this case you can add the @ignore PhpDoc annotation to the duplicate definition and it will be ignored.

Loading history...
1178
    }
1179
1180
    /**
1181
     * Persist's the URL write with the passed data.
1182
     *
1183
     * @param array       $row  The URL rewrite to persist
1184
     * @param string|null $name The name of the prepared statement that has to be executed
1185
     *
1186
     * @return string The ID of the persisted entity
1187
     */
1188
    public function persistUrlRewrite($row, $name = null)
1189
    {
1190
        return $this->getUrlRewriteAction()->persist($row, $name);
0 ignored issues
show
Unused Code introduced by
The call to UrlRewriteAction::persist() has too many arguments starting with $name.

This check compares calls to functions or methods with their respective definitions. If the call has more arguments than are defined, it raises an issue.

If a function is defined several times with a different number of parameters, the check may pick up the wrong definition and report false positives. One codebase where this has been known to happen is Wordpress.

In this case you can add the @ignore PhpDoc annotation to the duplicate definition and it will be ignored.

Loading history...
1191
    }
1192
1193
    /**
1194
     * Persist's the URL rewrite product => category relation with the passed data.
1195
     *
1196
     * @param array       $row  The URL rewrite product => category relation to persist
1197
     * @param string|null $name The name of the prepared statement that has to be executed
1198
     *
1199
     * @return void
1200
     */
1201
    public function persistUrlRewriteProductCategory($row, $name = null)
1202
    {
1203
        $this->getUrlRewriteProductCategoryAction()->persist($row, $name);
0 ignored issues
show
Unused Code introduced by
The call to UrlRewriteProductCategoryAction::persist() has too many arguments starting with $name.

This check compares calls to functions or methods with their respective definitions. If the call has more arguments than are defined, it raises an issue.

If a function is defined several times with a different number of parameters, the check may pick up the wrong definition and report false positives. One codebase where this has been known to happen is Wordpress.

In this case you can add the @ignore PhpDoc annotation to the duplicate definition and it will be ignored.

Loading history...
1204
    }
1205
1206
    /**
1207
     * Delete's the entity with the passed attributes.
1208
     *
1209
     * @param array       $row  The attributes of the entity to delete
1210
     * @param string|null $name The name of the prepared statement that has to be executed
1211
     *
1212
     * @return void
1213
     */
1214
    public function deleteProduct($row, $name = null)
1215
    {
1216
        $this->getProductAction()->delete($row, $name);
1217
    }
1218
1219
    /**
1220
     * Delete's the URL rewrite with the passed attributes.
1221
     *
1222
     * @param array       $row  The attributes of the entity to delete
1223
     * @param string|null $name The name of the prepared statement that has to be executed
1224
     *
1225
     * @return void
1226
     */
1227
    public function deleteUrlRewrite($row, $name = null)
1228
    {
1229
        $this->getUrlRewriteAction()->delete($row, $name);
1230
    }
1231
1232
    /**
1233
     * Delete's the stock item(s) with the passed attributes.
1234
     *
1235
     * @param array       $row  The attributes of the entity to delete
1236
     * @param string|null $name The name of the prepared statement that has to be executed
1237
     *
1238
     * @return void
1239
     */
1240
    public function deleteStockItem($row, $name = null)
1241
    {
1242
        $this->getStockItemAction()->delete($row, $name);
1243
    }
1244
1245
    /**
1246
     * Delete's the stock status with the passed attributes.
1247
     *
1248
     * @param array       $row  The attributes of the entity to delete
1249
     * @param string|null $name The name of the prepared statement that has to be executed
1250
     *
1251
     * @return void
1252
     */
1253
    public function deleteStockStatus($row, $name = null)
1254
    {
1255
        $this->getStockStatusAction()->delete($row, $name);
1256
    }
1257
1258
    /**
1259
     * Delete's the product website relations with the passed attributes.
1260
     *
1261
     * @param array       $row  The attributes of the entity to delete
1262
     * @param string|null $name The name of the prepared statement that has to be executed
1263
     *
1264
     * @return void
1265
     */
1266
    public function deleteProductWebsite($row, $name = null)
1267
    {
1268
        $this->getProductWebsiteAction()->delete($row, $name);
1269
    }
1270
1271
    /**
1272
     * Delete's the category product relations with the passed attributes.
1273
     *
1274
     * @param array       $row  The attributes of the entity to delete
1275
     * @param string|null $name The name of the prepared statement that has to be executed
1276
     *
1277
     * @return void
1278
     */
1279
    public function deleteCategoryProduct($row, $name = null)
1280
    {
1281
        $this->getCategoryProductAction()->delete($row, $name);
1282
    }
1283
}
1284