<?php
 declare(strict_types=1); namespace Square\Models; use stdClass; class BankAccountPaymentDetails implements \JsonSerializable { private $bankName; private $transferType; private $accountOwnershipType; private $fingerprint; private $country; private $statementDescription; private $achDetails; private $errors; public function getBankName(): ?string { return $this->bankName; } public function setBankName(?string $bankName): void { $this->bankName = $bankName; } public function getTransferType(): ?string { return $this->transferType; } public function setTransferType(?string $transferType): void { $this->transferType = $transferType; } public function getAccountOwnershipType(): ?string { return $this->accountOwnershipType; } public function setAccountOwnershipType(?string $accountOwnershipType): void { $this->accountOwnershipType = $accountOwnershipType; } public function getFingerprint(): ?string { return $this->fingerprint; } public function setFingerprint(?string $fingerprint): void { $this->fingerprint = $fingerprint; } public function getCountry(): ?string { return $this->country; } public function setCountry(?string $country): void { $this->country = $country; } public function getStatementDescription(): ?string { return $this->statementDescription; } public function setStatementDescription(?string $statementDescription): void { $this->statementDescription = $statementDescription; } public function getAchDetails(): ?ACHDetails { return $this->achDetails; } public function setAchDetails(?ACHDetails $achDetails): void { $this->achDetails = $achDetails; } public function getErrors(): ?array { return $this->errors; } public function setErrors(?array $errors): void { $this->errors = $errors; } #[\ReturnTypeWillChange] public function jsonSerialize(bool $asArrayWhenEmpty = false) { $json = []; if (isset($this->bankName)) { $json['bank_name'] = $this->bankName; } if (isset($this->transferType)) { $json['transfer_type'] = $this->transferType; } if (isset($this->accountOwnershipType)) { $json['account_ownership_type'] = $this->accountOwnershipType; } if (isset($this->fingerprint)) { $json['fingerprint'] = $this->fingerprint; } if (isset($this->country)) { $json['country'] = $this->country; } if (isset($this->statementDescription)) { $json['statement_description'] = $this->statementDescription; } if (isset($this->achDetails)) { $json['ach_details'] = $this->achDetails; } if (isset($this->errors)) { $json['errors'] = $this->errors; } $json = array_filter($json, function ($val) { return $val !== null; }); return (!$asArrayWhenEmpty && empty($json)) ? new stdClass() : $json; } } 