| Total Complexity | 2 |
| Total Lines | 33 |
| Duplicated Lines | 0 % |
| Changes | 3 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 21 | class Service extends AbstractService |
||
| 22 | { |
||
| 23 | /** |
||
| 24 | * @var ClientInterface The API client. |
||
| 25 | */ |
||
| 26 | protected $client; |
||
| 27 | |||
| 28 | /** |
||
| 29 | * Constructs the API service. |
||
| 30 | * |
||
| 31 | * @inheritDoc |
||
| 32 | * @param ClientInterface $client The API client. |
||
| 33 | */ |
||
| 34 | public function __construct( |
||
| 35 | ContainerInterface $container, |
||
| 36 | ClientInterface $client |
||
| 37 | ) { |
||
| 38 | parent::__construct($container); |
||
| 39 | $this->client = $client; |
||
| 40 | } |
||
| 41 | |||
| 42 | /** |
||
| 43 | * Sends the provided request message and populates |
||
| 44 | * the provided response message with the API response. |
||
| 45 | * |
||
| 46 | * @param RequestInterface $request The request message to send. |
||
| 47 | * @param ResponseInterface $response The response message to populate with the API response. |
||
| 48 | * @throws ClientExceptionInterface If sending fails. |
||
| 49 | * @throws ErrorResponseExceptionInterface If the response is a PAYONE API error. |
||
| 50 | */ |
||
| 51 | public function sendRequest(RequestInterface $request, ResponseInterface $response): void |
||
| 54 | } |
||
| 55 | } |
||
| 56 |