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.

SoapAdapter   A
last analyzed

Complexity

Total Complexity 3

Size/Duplication

Total Lines 34
Duplicated Lines 0 %

Coupling/Cohesion

Components 1
Dependencies 1

Test Coverage

Coverage 100%

Importance

Changes 0
Metric Value
wmc 3
lcom 1
cbo 1
dl 0
loc 34
ccs 5
cts 5
cp 1
rs 10
c 0
b 0
f 0

2 Methods

Rating   Name   Duplication   Size   Complexity  
A call() 0 10 2
A getClient() 0 4 1
1
<?php
2
3
namespace WebservicesNl\Connector\ProtocolAdapter;
4
5
use WebservicesNl\Common\Exception\Server\NoServerAvailableException;
6
use WebservicesNl\Connector\Client\ClientInterface;
7
use WebservicesNl\Protocol\Soap\Client\SoapClient;
8
9
/**
10
 * SoapAdapter.
11
 *
12
 * Soap protocol adapter for a ConnectorInterface to connect to the Webservices API.
13
 */
14
class SoapAdapter extends AbstractAdapter
15
{
16
    /**
17
     * {@inheritdoc}
18
     *
19
     * @param string $functionName name of the function call
20
     * @param mixed  $args         arguments for the function call
21
     *
22
     * @return mixed
23
     * @throws NoServerAvailableException
24
     * @throws \SoapFault
25
     * @throws \Exception
26
     */
27 1
    public function call($functionName, $args)
28
    {
29 1
        if (method_exists($this->getClient(), $functionName) === true) {
30
            // @codeCoverageIgnoreStart
31
            return $this->getClient()->$functionName($args);
32
            // @codeCoverageIgnoreEnd
33
        }
34
35 1
        return $this->getClient()->__soapCall($functionName, $args);
36
    }
37
38
    /**
39
     * {@inheritdoc}
40
     *
41
     * @return SoapClient|ClientInterface
42
     */
43 1
    public function getClient()
44
    {
45 1
        return $this->client;
46
    }
47
}
48