<?php
 declare(strict_types=1); namespace Square\Models; use stdClass; class OrderFulfillmentUpdated implements \JsonSerializable { private $orderId; private $version; private $locationId; private $state; private $createdAt; private $updatedAt; private $fulfillmentUpdate; public function getOrderId(): ?string { return $this->orderId; } public function setOrderId(?string $orderId): void { $this->orderId = $orderId; } public function getVersion(): ?int { return $this->version; } public function setVersion(?int $version): void { $this->version = $version; } public function getLocationId(): ?string { return $this->locationId; } public function setLocationId(?string $locationId): void { $this->locationId = $locationId; } public function getState(): ?string { return $this->state; } public function setState(?string $state): void { $this->state = $state; } public function getCreatedAt(): ?string { return $this->createdAt; } public function setCreatedAt(?string $createdAt): void { $this->createdAt = $createdAt; } public function getUpdatedAt(): ?string { return $this->updatedAt; } public function setUpdatedAt(?string $updatedAt): void { $this->updatedAt = $updatedAt; } public function getFulfillmentUpdate(): ?array { return $this->fulfillmentUpdate; } public function setFulfillmentUpdate(?array $fulfillmentUpdate): void { $this->fulfillmentUpdate = $fulfillmentUpdate; } #[\ReturnTypeWillChange] public function jsonSerialize(bool $asArrayWhenEmpty = false) { $json = []; if (isset($this->orderId)) { $json['order_id'] = $this->orderId; } if (isset($this->version)) { $json['version'] = $this->version; } if (isset($this->locationId)) { $json['location_id'] = $this->locationId; } if (isset($this->state)) { $json['state'] = $this->state; } if (isset($this->createdAt)) { $json['created_at'] = $this->createdAt; } if (isset($this->updatedAt)) { $json['updated_at'] = $this->updatedAt; } if (isset($this->fulfillmentUpdate)) { $json['fulfillment_update'] = $this->fulfillmentUpdate; } $json = array_filter($json, function ($val) { return $val !== null; }); return (!$asArrayWhenEmpty && empty($json)) ? new stdClass() : $json; } } 