for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
/*
* This file is part of the BenGorUser library.
*
* (c) Beñat Espiña <[email protected]>
* (c) Gorka Laucirica <[email protected]>
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace BenatEspina\StackExchangeApiClient\Application\DataTransformer;
use BenatEspina\StackExchangeApiClient\Domain\Model\Response;
/**
* Answer not transformation data transformer.
* @author Beñat Espiña <[email protected]>
class ResponseNoTransformationDataTransformer implements DataTransformer
{
* The response.
* @var Response
private $response;
* {@inheritdoc}
public function write(Response $response)
$this->response = $response;
}
public function read()
if (null === $this->response) {
return [];
return $this->response;