GetCustomerProfileRequest::__construct()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 7
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 0
CRAP Score 2

Importance

Changes 0
Metric Value
cc 1
eloc 2
c 0
b 0
f 0
nc 1
nop 3
dl 0
loc 7
ccs 0
cts 3
cp 0
crap 2
rs 10
1
<?php
2
3
namespace CommerceGuys\AuthNet;
4
5
use GuzzleHttp\Client;
6
use CommerceGuys\AuthNet\Request\RequestInterface;
7
8
/**
9
 * Retrieve an existing customer profile.
10
 *
11
 * @link http://developer.authorize.net/api/reference/index.html#customer-profiles-get-customer-profile
12
 */
13
class GetCustomerProfileRequest extends BaseApiRequest
14
{
15
    protected $customerProfileId;
16
17
    public function __construct(
18
        Configuration $configuration,
19
        Client $client,
20
        $customerProfileId
21
    ) {
22
        parent::__construct($configuration, $client);
23
        $this->customerProfileId = $customerProfileId;
24
    }
25
26
    protected function attachData(RequestInterface $request)
27
    {
28
        $request->addData('customerProfileId', $this->customerProfileId);
29
    }
30
}
31