<?php
 declare(strict_types=1); namespace Square\Models; use stdClass; class EmployeeWage implements \JsonSerializable { private $id; private $employeeId; private $title; private $hourlyRate; public function getId(): ?string { return $this->id; } public function setId(?string $id): void { $this->id = $id; } public function getEmployeeId(): ?string { return $this->employeeId; } public function setEmployeeId(?string $employeeId): void { $this->employeeId = $employeeId; } public function getTitle(): ?string { return $this->title; } public function setTitle(?string $title): void { $this->title = $title; } public function getHourlyRate(): ?Money { return $this->hourlyRate; } public function setHourlyRate(?Money $hourlyRate): void { $this->hourlyRate = $hourlyRate; } #[\ReturnTypeWillChange] public function jsonSerialize(bool $asArrayWhenEmpty = false) { $json = []; if (isset($this->id)) { $json['id'] = $this->id; } if (isset($this->employeeId)) { $json['employee_id'] = $this->employeeId; } if (isset($this->title)) { $json['title'] = $this->title; } if (isset($this->hourlyRate)) { $json['hourly_rate'] = $this->hourlyRate; } $json = array_filter($json, function ($val) { return $val !== null; }); return (!$asArrayWhenEmpty && empty($json)) ? new stdClass() : $json; } } 