for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
namespace Carpenstar\ByBitAPI\Core\Response;
use Carpenstar\ByBitAPI\Core\Helpers\DateTimeHelper;
use Carpenstar\ByBitAPI\Core\Interfaces\ICollectionInterface;
use Carpenstar\ByBitAPI\Core\Interfaces\ICurlResponseDtoInterface;
class CurlResponseDto implements ICurlResponseDtoInterface
{
/**
* @var \DateTime $time
*/
private \DateTime $time;
* @var int $retCode
private int $retCode;
* @var string $retMsg
private string $retMsg;
* @var array $retExtInfo
private array $retExtInfo = [];
private ICollectionInterface $body;
* @param int $code
* @return CurlResponseDto
public function setReturnCode(int $code): self
$this->retCode = $code;
return $this;
}
* @return int
public function getReturnCode(): int
return $this->retCode;
* @param string $message
public function setReturnMessage(string $message): self
$this->retMsg = $message;
* @return string
public function getReturnMessage(): string
return $this->retMsg;
* @param array $extInfo
public function setReturnExtendedInfo(array $extInfo): self
$this->retExtInfo = $extInfo;
* @return array
public function getReturnExtendedInfo(): array
return $this->retExtInfo;
* @param int $time
public function setTime(int $time): self
$this->time = DateTimeHelper::makeFromTimestamp($time);
* @return \DateTime
public function getTime(): \DateTime
return $this->time;
* @param $collection
* @return $this
public function setBody($collection): self
$this->body = $collection;
* @return array|null
public function getBody(): ICollectionInterface
return $this->body;
return $this->body
Carpenstar\ByBitAPI\Core...es\ICollectionInterface
array|null