Total Complexity | 4 |
Total Lines | 35 |
Duplicated Lines | 0 % |
Coverage | 84.62% |
Changes | 6 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
12 | class SoapFactory implements LoggerAwareInterface |
||
13 | { |
||
14 | /** @var LoggerInterface */ |
||
15 | private $logger; |
||
16 | |||
17 | 90 | public function __construct(LoggerInterface $logger = null) |
|
20 | 90 | } |
|
21 | |||
22 | 56 | public function createSoapClient(string $wsdlLocation): SoapClient |
|
29 | ]); |
||
30 | } |
||
31 | |||
32 | /** |
||
33 | * @param string $wsdlLocation |
||
34 | * @param array<mixed> $defaultOptions |
||
35 | * @return SoapCaller |
||
36 | */ |
||
37 | 56 | public function createSoapCaller(string $wsdlLocation, array $defaultOptions): SoapCaller |
|
38 | { |
||
39 | 56 | $caller = new SoapCaller($this->createSoapClient($wsdlLocation), $defaultOptions); |
|
40 | 56 | $caller->setLogger($this->logger); |
|
41 | 56 | return $caller; |
|
42 | } |
||
43 | |||
44 | public function setLogger(LoggerInterface $logger): void |
||
47 | } |
||
48 | } |
||
49 |