<?php
 declare(strict_types=1); namespace Square\Models; use stdClass; class CatalogV1Id implements \JsonSerializable { private $catalogV1Id; private $locationId; public function getCatalogV1Id(): ?string { return $this->catalogV1Id; } public function setCatalogV1Id(?string $catalogV1Id): void { $this->catalogV1Id = $catalogV1Id; } public function getLocationId(): ?string { return $this->locationId; } public function setLocationId(?string $locationId): void { $this->locationId = $locationId; } #[\ReturnTypeWillChange] public function jsonSerialize(bool $asArrayWhenEmpty = false) { $json = []; if (isset($this->catalogV1Id)) { $json['catalog_v1_id'] = $this->catalogV1Id; } if (isset($this->locationId)) { $json['location_id'] = $this->locationId; } $json = array_filter($json, function ($val) { return $val !== null; }); return (!$asArrayWhenEmpty && empty($json)) ? new stdClass() : $json; } } 