. */ declare(strict_types=1); namespace FireflyIII\Services\Bunq\Object; /** * Class Image */ class Image extends BunqObject { /** @var string */ private $attachmentPublicUuid; /** @var string */ private $contentType; /** @var int */ private $height; /** @var int */ private $width; /** * Image constructor. * * @param array $data */ public function __construct(array $data) { $this->attachmentPublicUuid = $data['attachment_public_uuid'] ?? null; $this->height = $data['height'] ?? null; $this->width = $data['width'] ?? null; $this->contentType = $data['content_type'] ?? null; } /** * @return array */ public function toArray(): array { return [ 'attachment_public_uuid' => $this->attachmentPublicUuid, 'height' => $this->height, 'width' => $this->width, 'content_type' => $this->contentType, ]; } }