GitHub Access Token became invalid

It seems like the GitHub access token used for retrieving details about this repository from GitHub became invalid. This might prevent certain types of inspections from being run (in particular, everything related to pull requests).
Please ask an admin of your repository to re-new the access token on this website.

CommonClient   A
last analyzed

Complexity

Total Complexity 9

Size/Duplication

Total Lines 133
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 25
dl 0
loc 133
rs 10
c 1
b 0
f 0
wmc 9

9 Methods

Rating   Name   Duplication   Size   Complexity  
A getTagsApi() 0 3 1
A getAbandonedCartApi() 0 3 1
A getOrderApi() 0 3 1
A getListsApi() 0 3 1
A __construct() 0 18 1
A getCustomerApi() 0 3 1
A getContactApi() 0 3 1
A getConnectionApi() 0 3 1
A getDealApi() 0 3 1
1
<?php
2
declare(strict_types=1);
3
/**
4
 */
5
6
namespace CommerceLeague\ActiveCampaignApi;
7
8
use CommerceLeague\ActiveCampaignApi\Api\AbandonedCartApiResourceInterface;
9
use CommerceLeague\ActiveCampaignApi\Api\ConnectionApiResourceInterface;
10
use CommerceLeague\ActiveCampaignApi\Api\ContactApiResourceInterface;
11
use CommerceLeague\ActiveCampaignApi\Api\CustomerApiResourceInterface;
12
use CommerceLeague\ActiveCampaignApi\Api\DealApiResourceInterface;
13
use CommerceLeague\ActiveCampaignApi\Api\ListsApiResourceInterface;
14
use CommerceLeague\ActiveCampaignApi\Api\OrderApiResourceInterface;
15
use CommerceLeague\ActiveCampaignApi\Api\TagsApiResourceInterface;
16
17
/**
18
 * Class CommonClient
19
 */
20
class CommonClient implements CommonClientInterface
21
{
22
23
    /**
24
     * @var AbandonedCartApiResourceInterface
25
     */
26
    private $abandonedCartApi;
27
28
    /**
29
     * @var ConnectionApiResourceInterface
30
     */
31
    private $connectionApi;
32
33
    /**
34
     * @var ContactApiResourceInterface
35
     */
36
    private $contactApi;
37
38
    /**
39
     * @var CustomerApiResourceInterface
40
     */
41
    private $customerApi;
42
43
    /**
44
     * @var DealApiResourceInterface
45
     */
46
    private $dealApi;
47
48
    /**
49
     * @var OrderApiResourceInterface
50
     */
51
    private $orderApi;
52
53
    /**
54
     * @var TagsApiResourceInterface
55
     */
56
    private $tagsApi;
57
58
    /**
59
     * @var ListsApiResourceInterface
60
     */
61
    private $listsApi;
62
63
    /**
64
     * @param AbandonedCartApiResourceInterface $abandonedCartApi
65
     * @param ConnectionApiResourceInterface    $connectionApi
66
     * @param ContactApiResourceInterface       $contactApi
67
     * @param CustomerApiResourceInterface      $customerApi
68
     * @param DealApiResourceInterface          $dealApi
69
     * @param OrderApiResourceInterface         $orderApi
70
     */
71
    public function __construct(
72
        AbandonedCartApiResourceInterface $abandonedCartApi,
73
        ConnectionApiResourceInterface $connectionApi,
74
        ContactApiResourceInterface $contactApi,
75
        CustomerApiResourceInterface $customerApi,
76
        DealApiResourceInterface $dealApi,
77
        OrderApiResourceInterface $orderApi,
78
        TagsApiResourceInterface $tagsApi,
79
        ListsApiResourceInterface $listsApi
80
    ) {
81
        $this->abandonedCartApi = $abandonedCartApi;
82
        $this->connectionApi    = $connectionApi;
83
        $this->contactApi       = $contactApi;
84
        $this->customerApi      = $customerApi;
85
        $this->dealApi          = $dealApi;
86
        $this->orderApi         = $orderApi;
87
        $this->tagsApi          = $tagsApi;
88
        $this->listsApi         = $listsApi;
89
    }
90
91
    /**
92
     * @return ListsApiResourceInterface
93
     */
94
    public function getListsApi(): ListsApiResourceInterface
95
    {
96
        return $this->listsApi;
97
    }
98
99
    /**
100
     * @inheritDoc
101
     */
102
    public function getAbandonedCartApi(): AbandonedCartApiResourceInterface
103
    {
104
        return $this->abandonedCartApi;
105
    }
106
107
    /**
108
     * @inheritDoc
109
     */
110
    public function getConnectionApi(): ConnectionApiResourceInterface
111
    {
112
        return $this->connectionApi;
113
    }
114
115
    /**
116
     * @inheritDoc
117
     */
118
    public function getContactApi(): ContactApiResourceInterface
119
    {
120
        return $this->contactApi;
121
    }
122
123
    /**
124
     * @inheritDoc
125
     */
126
    public function getCustomerApi(): CustomerApiResourceInterface
127
    {
128
        return $this->customerApi;
129
    }
130
131
    /**
132
     * @inheritDoc
133
     */
134
    public function getDealApi(): DealApiResourceInterface
135
    {
136
        return $this->dealApi;
137
    }
138
139
    /**
140
     * @inheritDoc
141
     */
142
    public function getOrderApi(): OrderApiResourceInterface
143
    {
144
        return $this->orderApi;
145
    }
146
147
    /**
148
     * @inheritDoc
149
     */
150
    public function getTagsApi(): TagsApiResourceInterface
151
    {
152
        return $this->tagsApi;
153
    }
154
155
}
156