MinuboPersistenceFactory   A
last analyzed

Complexity

Total Complexity 3

Size/Duplication

Total Lines 24
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 1
Metric Value
wmc 3
eloc 4
c 1
b 0
f 1
dl 0
loc 24
rs 10

3 Methods

Rating   Name   Duplication   Size   Complexity  
A getCustomerQuery() 0 3 1
A createMinuboRunQuery() 0 3 1
A getSalesOrderQuery() 0 3 1
1
<?php
2
3
/**
4
 * MIT License
5
 * Use of this software requires acceptance of the Evaluation License Agreement. See LICENSE file.
6
 */
7
8
namespace SprykerEco\Zed\Minubo\Persistence;
9
10
use Orm\Zed\Customer\Persistence\SpyCustomerQuery;
0 ignored issues
show
Bug introduced by
The type Orm\Zed\Customer\Persistence\SpyCustomerQuery was not found. Maybe you did not declare it correctly or list all dependencies?

The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g. excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:

filter:
    dependency_paths: ["lib/*"]

For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths

Loading history...
11
use Orm\Zed\Minubo\Persistence\SpyMinuboRunQuery;
0 ignored issues
show
Bug introduced by
The type Orm\Zed\Minubo\Persistence\SpyMinuboRunQuery was not found. Maybe you did not declare it correctly or list all dependencies?

The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g. excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:

filter:
    dependency_paths: ["lib/*"]

For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths

Loading history...
12
use Orm\Zed\Sales\Persistence\SpySalesOrderQuery;
0 ignored issues
show
Bug introduced by
The type Orm\Zed\Sales\Persistence\SpySalesOrderQuery was not found. Maybe you did not declare it correctly or list all dependencies?

The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g. excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:

filter:
    dependency_paths: ["lib/*"]

For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths

Loading history...
13
use Spryker\Zed\Kernel\Persistence\AbstractPersistenceFactory;
14
use SprykerEco\Zed\Minubo\MinuboDependencyProvider;
15
16
/**
17
 * @method \SprykerEco\Zed\Minubo\MinuboConfig getConfig()
18
 * @method \SprykerEco\Zed\Minubo\Persistence\MinuboEntityManagerInterface getEntityManager()
19
 * @method \SprykerEco\Zed\Minubo\Persistence\MinuboRepositoryInterface getRepository()
20
 */
21
class MinuboPersistenceFactory extends AbstractPersistenceFactory
22
{
23
    /**
24
     * @return \Orm\Zed\Minubo\Persistence\SpyMinuboRunQuery
25
     */
26
    public function createMinuboRunQuery(): SpyMinuboRunQuery
27
    {
28
        return new SpyMinuboRunQuery();
29
    }
30
31
    /**
32
     * @return \Orm\Zed\Customer\Persistence\SpyCustomerQuery
33
     */
34
    public function getCustomerQuery(): SpyCustomerQuery
35
    {
36
        return $this->getProvidedDependency(MinuboDependencyProvider::PROPEL_QUERY_CUSTOMER);
37
    }
38
39
    /**
40
     * @return \Orm\Zed\Sales\Persistence\SpySalesOrderQuery
41
     */
42
    public function getSalesOrderQuery(): SpySalesOrderQuery
43
    {
44
        return $this->getProvidedDependency(MinuboDependencyProvider::PROPEL_QUERY_SALES_ORDER);
45
    }
46
}
47