From 20e8bb244c9d91aea6d52f2c96b21f441d281736 Mon Sep 17 00:00:00 2001 From: Kevin Hellemun Date: Thu, 16 Nov 2017 12:13:43 +0100 Subject: [PATCH 01/27] Generated CHANGELOG.md :clap:. (bunq/sdk_php#71) --- CHANGELOG.md | 139 +++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 139 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index e69de29b..b4600ee0 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -0,0 +1,139 @@ +# Change Log + +## [0.12.3](https://github.com/bunq/sdk_php/tree/0.12.3) (2017-11-15) +[Full Changelog](https://github.com/bunq/sdk_php/compare/0.12.2...0.12.3) + +**Implemented enhancements:** + +- Callback models for holding callback data. [\#67](https://github.com/bunq/sdk_php/issues/67) + +**Fixed bugs:** + +- Scheduled payments are not decoded because of a typo [\#70](https://github.com/bunq/sdk_php/issues/70) + +**Merged pull requests:** + +- Feature/callback models \#67 [\#69](https://github.com/bunq/sdk_php/pull/69) ([OGKevin](https://github.com/OGKevin)) + +## [0.12.2](https://github.com/bunq/sdk_php/tree/0.12.2) (2017-11-08) +[Full Changelog](https://github.com/bunq/sdk_php/compare/0.12.1...0.12.2) + +**Implemented enhancements:** + +- Add missing fields for cvc endpoint [\#64](https://github.com/bunq/sdk_php/issues/64) +- Missing CARD GENERATED CVC2 endpoint [\#61](https://github.com/bunq/sdk_php/issues/61) +- More flexibility for sessionContext handling [\#58](https://github.com/bunq/sdk_php/issues/58) +- Added cvc\_endpoint. \#61 [\#62](https://github.com/bunq/sdk_php/pull/62) ([OGKevin](https://github.com/OGKevin)) +- Feature/is expired\#58 [\#59](https://github.com/bunq/sdk_php/pull/59) ([OGKevin](https://github.com/OGKevin)) + +**Fixed bugs:** + +- Getting a DraftPayment that has been ACCEPTED results in an error [\#63](https://github.com/bunq/sdk_php/issues/63) + +**Merged pull requests:** + +- Feature/fix draft payment object \#63 [\#66](https://github.com/bunq/sdk_php/pull/66) ([OGKevin](https://github.com/OGKevin)) +- Feature/add missing cvc fields \#64 [\#65](https://github.com/bunq/sdk_php/pull/65) ([OGKevin](https://github.com/OGKevin)) + +## [0.12.1](https://github.com/bunq/sdk_php/tree/0.12.1) (2017-10-11) +[Full Changelog](https://github.com/bunq/sdk_php/compare/0.12.0...0.12.1) + +**Fixed bugs:** + +- toJson\(\) fails on ApiContext of an user person due to session context [\#56](https://github.com/bunq/sdk_php/issues/56) + +**Merged pull requests:** + +- toJson\(\) fails on ApiContext of an user person due to session context [\#57](https://github.com/bunq/sdk_php/pull/57) ([DennisSnijder](https://github.com/DennisSnijder)) + +## [0.12.0](https://github.com/bunq/sdk_php/tree/0.12.0) (2017-10-11) +[Full Changelog](https://github.com/bunq/sdk_php/compare/0.11.0...0.12.0) + +**Implemented enhancements:** + +- Add strictly typed BunqResponses [\#52](https://github.com/bunq/sdk_php/issues/52) +- Better error handling [\#49](https://github.com/bunq/sdk_php/issues/49) +- End support for PHP 5.6 [\#44](https://github.com/bunq/sdk_php/issues/44) +- Add strictly typed responses; fix GET in extended models \[\#52\] [\#53](https://github.com/bunq/sdk_php/pull/53) ([dnl-blkv](https://github.com/dnl-blkv)) +- Feature/exception factory [\#50](https://github.com/bunq/sdk_php/pull/50) ([OGKevin](https://github.com/OGKevin)) +- Marked all files in generated dir as generated code. [\#47](https://github.com/bunq/sdk_php/pull/47) ([OGKevin](https://github.com/OGKevin)) + +**Fixed bugs:** + +- User::get returns empty object? [\#51](https://github.com/bunq/sdk_php/issues/51) +- Error retrieving pinned certificates [\#14](https://github.com/bunq/sdk_php/issues/14) + +**Merged pull requests:** + +- cleanup after 52-strict-response [\#55](https://github.com/bunq/sdk_php/pull/55) ([dnl-blkv](https://github.com/dnl-blkv)) +- !== instead of != [\#54](https://github.com/bunq/sdk_php/pull/54) ([OGKevin](https://github.com/OGKevin)) +- Added PHPStan and script to run "composer phpstan" [\#48](https://github.com/bunq/sdk_php/pull/48) ([holtkamp](https://github.com/holtkamp)) + +## [0.11.0](https://github.com/bunq/sdk_php/tree/0.11.0) (2017-09-06) +[Full Changelog](https://github.com/bunq/sdk_php/compare/0.10.0...0.11.0) + +**Implemented enhancements:** + +- Ignore generated code for reviews [\#45](https://github.com/bunq/sdk_php/issues/45) +- Pagination and limit is missing for listing methods [\#15](https://github.com/bunq/sdk_php/issues/15) +- Updated git attributes. [\#46](https://github.com/bunq/sdk_php/pull/46) ([OGKevin](https://github.com/OGKevin)) +- Add Pagination and missing fields/endpoints \[\#15\] [\#43](https://github.com/bunq/sdk_php/pull/43) ([dnl-blkv](https://github.com/dnl-blkv)) + +## [0.10.0](https://github.com/bunq/sdk_php/tree/0.10.0) (2017-08-22) +[Full Changelog](https://github.com/bunq/sdk_php/compare/0.9.1...0.10.0) + +**Implemented enhancements:** + +- Allow saving context to JSON and restoring from it [\#39](https://github.com/bunq/sdk_php/issues/39) +- Response is missing response headers and pagination [\#33](https://github.com/bunq/sdk_php/issues/33) +- Allow to configure Guzzle options / use a proxy to ensure static IP address [\#5](https://github.com/bunq/sdk_php/issues/5) +- Cleanup; add toJson and fromJson to ApiContext \[\#39\] [\#40](https://github.com/bunq/sdk_php/pull/40) ([dnl-blkv](https://github.com/dnl-blkv)) +- \#33 bunq response [\#34](https://github.com/bunq/sdk_php/pull/34) ([dnl-blkv](https://github.com/dnl-blkv)) +- \#5 Allow setting a proxy [\#27](https://github.com/bunq/sdk_php/pull/27) ([qurben](https://github.com/qurben)) +- Introduction of Grumphp [\#24](https://github.com/bunq/sdk_php/pull/24) ([cafferata](https://github.com/cafferata)) + +**Fixed bugs:** + +- Error in api context script [\#36](https://github.com/bunq/sdk_php/issues/36) + +**Merged pull requests:** + +- Fixes \#36 on php5.6 [\#37](https://github.com/bunq/sdk_php/pull/37) ([OGKevin](https://github.com/OGKevin)) +- Added an .gitattributes file. [\#20](https://github.com/bunq/sdk_php/pull/20) ([cafferata](https://github.com/cafferata)) + +## [0.9.1](https://github.com/bunq/sdk_php/tree/0.9.1) (2017-08-07) +**Implemented enhancements:** + +- Remove phpstan [\#28](https://github.com/bunq/sdk_php/issues/28) +- Suggestion: use Objects instead of arrays [\#22](https://github.com/bunq/sdk_php/issues/22) +- Changes the composer PHP requirement [\#19](https://github.com/bunq/sdk_php/pull/19) ([cafferata](https://github.com/cafferata)) +- Removed the default PHPStorm constructor header\(s\) [\#18](https://github.com/bunq/sdk_php/pull/18) ([cafferata](https://github.com/cafferata)) +- Add readme for tests. [\#16](https://github.com/bunq/sdk_php/pull/16) ([OGKevin](https://github.com/OGKevin)) +- Restructure project [\#12](https://github.com/bunq/sdk_php/pull/12) ([LauLaman](https://github.com/LauLaman)) +- Add PHP-CS and PHPStan dependencies and scripts to execute [\#3](https://github.com/bunq/sdk_php/pull/3) ([holtkamp](https://github.com/holtkamp)) +- Add first series of unit-tests [\#1](https://github.com/bunq/sdk_php/pull/1) ([OGKevin](https://github.com/OGKevin)) + +**Fixed bugs:** + +- User Agent header generation is broken in ApiClient [\#30](https://github.com/bunq/sdk_php/issues/30) +- Scripts in composer.json are broken [\#25](https://github.com/bunq/sdk_php/issues/25) +- public.api.bunq.com is using wrong certificate [\#11](https://github.com/bunq/sdk_php/issues/11) +- SessionContext is missing timeout for UserPerson [\#10](https://github.com/bunq/sdk_php/issues/10) +- SDK not working on Windows \(XAMPP\) [\#8](https://github.com/bunq/sdk_php/issues/8) +- Curl error "Invalid certificate chain" when running `vendor/bin/bunq-install` [\#6](https://github.com/bunq/sdk_php/issues/6) + +**Closed issues:** + +- Incorrect composer.json / authors sections [\#2](https://github.com/bunq/sdk_php/issues/2) + +**Merged pull requests:** + +- Fix user agent generation in ApiClient [\#31](https://github.com/bunq/sdk_php/pull/31) ([dnl-blkv](https://github.com/dnl-blkv)) +- \#28 remove phpstan as it does not support php 5.6 [\#29](https://github.com/bunq/sdk_php/pull/29) ([qurben](https://github.com/qurben)) +- \#25 Update directory for composer scripts, also omit version. [\#26](https://github.com/bunq/sdk_php/pull/26) ([qurben](https://github.com/qurben)) +- Updated composer.lock [\#23](https://github.com/bunq/sdk_php/pull/23) ([cafferata](https://github.com/cafferata)) +- Fixed signature newline handling \(Windows\) [\#9](https://github.com/bunq/sdk_php/pull/9) ([BabyDino](https://github.com/BabyDino)) + + + +\* *This Change Log was automatically generated by [github_changelog_generator](https://github.com/skywinder/Github-Changelog-Generator)* \ No newline at end of file From ef623c5aa2f26ff8835ab2e1e8480e4a4d74d407 Mon Sep 17 00:00:00 2001 From: Kevin Hellemun Date: Fri, 17 Nov 2017 16:06:09 +0100 Subject: [PATCH 02/27] Return static. (bunq/sdk_php#73) This ensure that the base class is returned instead of BunqModel. --- src/Model/Core/BunqModel.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Model/Core/BunqModel.php b/src/Model/Core/BunqModel.php index d22038ba..da71d263 100644 --- a/src/Model/Core/BunqModel.php +++ b/src/Model/Core/BunqModel.php @@ -87,9 +87,9 @@ protected static function fromJsonList( /** * @param string $json * - * @return BunqModel + * @return static */ - public static function createFromJsonString(string $json): BunqModel + public static function createFromJsonString(string $json) { $responseArray = ModelUtil::deserializeResponseArray($json); From c1be5b1f7c8135e029d3c0132c8e31448393fdbd Mon Sep 17 00:00:00 2001 From: Kevin Hellemun Date: Tue, 21 Nov 2017 14:38:30 +0100 Subject: [PATCH 03/27] Re-added strict return type. (bunq/sdk_php#73) --- src/Model/Core/BunqModel.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Model/Core/BunqModel.php b/src/Model/Core/BunqModel.php index da71d263..751e38ba 100644 --- a/src/Model/Core/BunqModel.php +++ b/src/Model/Core/BunqModel.php @@ -89,7 +89,7 @@ protected static function fromJsonList( * * @return static */ - public static function createFromJsonString(string $json) + public static function createFromJsonString(string $json): BunqModel { $responseArray = ModelUtil::deserializeResponseArray($json); From 2d037dd0af7e00b489adcd53697a10311d09790b Mon Sep 17 00:00:00 2001 From: Kevin Hellemun Date: Fri, 17 Nov 2017 17:24:39 +0100 Subject: [PATCH 04/27] Added abstract method areAllFieldsNull. (bunq/sdk_php#68) --- src/Model/Core/BunqModel.php | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/Model/Core/BunqModel.php b/src/Model/Core/BunqModel.php index 751e38ba..4d5515e4 100644 --- a/src/Model/Core/BunqModel.php +++ b/src/Model/Core/BunqModel.php @@ -96,6 +96,13 @@ public static function createFromJsonString(string $json): BunqModel return static::createFromResponseArray($responseArray); } + /** + * @return bool + * + * @throws BunqException + */ + abstract protected function areAllFieldsNull(); + /** * @param mixed[] $responseArray * @param string $wrapper From bc5c37e8cf764a2ba7957530c5241a650e40dd95 Mon Sep 17 00:00:00 2001 From: Kevin Hellemun Date: Tue, 28 Nov 2017 15:57:10 +0100 Subject: [PATCH 05/27] Check headers casing. (bunq/sdk_php#75) --- src/Http/Handler/ResponseHandlerSignature.php | 22 +++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/src/Http/Handler/ResponseHandlerSignature.php b/src/Http/Handler/ResponseHandlerSignature.php index 3a33c62e..432345d8 100644 --- a/src/Http/Handler/ResponseHandlerSignature.php +++ b/src/Http/Handler/ResponseHandlerSignature.php @@ -23,6 +23,18 @@ class ResponseHandlerSignature extends ResponseHandlerBase const HEADER_SEPARATOR = ', '; const FORMAT_HEADER = '%s: %s'; + /** + * Regex constants. + */ + const REGEX_FOR_LOWERCASE_HEADERS = '/-([a-z])/'; + const REGEX_REPLACE = '/%s/'; + const REGEX_CHECK_FAILED = '0'; + + /** + * The index of the first item in an array. + */ + const INDEX_FIRST = 0; + /** * Http status constants. */ @@ -95,6 +107,16 @@ private function determineHeaderStringForSignedResponse(array $headers) foreach ($headers as $headerName => $headerValue) { // All headers with the prefix 'X-Bunq-' except 'Server-Signature' need to be signed. + $headerName = ucfirst($headerName); + $regexResult = preg_match_all(self::REGEX_FOR_LOWERCASE_HEADERS, $headerName, $matches); + + if ($regexResult != self::REGEX_CHECK_FAILED) { + foreach ($matches[self::INDEX_FIRST] as $match) { + $matchUpper = strtoupper($match); + $headerName = preg_replace(vsprintf(self::REGEX_REPLACE, $match), $matchUpper, $headerName); + } + } + if ($headerName === self::HEADER_SERVER_SIGNATURE) { // Skip this header } elseif (strpos($headerName, self::HEADER_PREFIX) === self::HEADER_PREFIX_START) { From 21fd016f554b46abd87342547e98510f0f982e01 Mon Sep 17 00:00:00 2001 From: Kevin Hellemun Date: Tue, 28 Nov 2017 16:33:59 +0100 Subject: [PATCH 06/27] Exctracted the case chech in a seperate method. (bunq/sdk_php#75) --- src/Http/Handler/ResponseHandlerSignature.php | 30 +++++++++++++------ 1 file changed, 21 insertions(+), 9 deletions(-) diff --git a/src/Http/Handler/ResponseHandlerSignature.php b/src/Http/Handler/ResponseHandlerSignature.php index 432345d8..1d4531d2 100644 --- a/src/Http/Handler/ResponseHandlerSignature.php +++ b/src/Http/Handler/ResponseHandlerSignature.php @@ -107,15 +107,7 @@ private function determineHeaderStringForSignedResponse(array $headers) foreach ($headers as $headerName => $headerValue) { // All headers with the prefix 'X-Bunq-' except 'Server-Signature' need to be signed. - $headerName = ucfirst($headerName); - $regexResult = preg_match_all(self::REGEX_FOR_LOWERCASE_HEADERS, $headerName, $matches); - - if ($regexResult != self::REGEX_CHECK_FAILED) { - foreach ($matches[self::INDEX_FIRST] as $match) { - $matchUpper = strtoupper($match); - $headerName = preg_replace(vsprintf(self::REGEX_REPLACE, $match), $matchUpper, $headerName); - } - } + $headerName = $this->ensureHeaderIsCorrectlyCased($headerName); if ($headerName === self::HEADER_SERVER_SIGNATURE) { // Skip this header @@ -127,6 +119,26 @@ private function determineHeaderStringForSignedResponse(array $headers) return implode(self::NEWLINE, $signedDataHeaders); } + /** + * @param string $headerName + * + * @return mixed|string + */ + private function ensureHeaderIsCorrectlyCased(string $headerName) + { + $headerName = ucfirst($headerName); + $regexResult = preg_match_all(self::REGEX_FOR_LOWERCASE_HEADERS, $headerName, $matches); + + if ($regexResult != self::REGEX_CHECK_FAILED) { + foreach ($matches[self::INDEX_FIRST] as $match) { + $matchUpper = strtoupper($match); + $headerName = preg_replace(vsprintf(self::REGEX_REPLACE, $match), $matchUpper, $headerName); + } + } + + return $headerName; + } + /** * @param string $headerName * @param string[] $headerValue From 5a52e70968770519f482b432d5ad42ad49d2681e Mon Sep 17 00:00:00 2001 From: Kevin Hellemun Date: Sun, 3 Dec 2017 18:12:14 +0100 Subject: [PATCH 07/27] Added specific php version to composer. (bunq/sdk_php#38) --- composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.json b/composer.json index 11b82d18..9c45ded0 100644 --- a/composer.json +++ b/composer.json @@ -20,7 +20,7 @@ } ], "require": { - "php": "^7.0", + "php": "^7.0.13", "ext-curl": "*", "ext-json": "*", "ext-mbstring": "*", From f17abf838a903d3c4f5a5850d2e6e4a067abc4ca Mon Sep 17 00:00:00 2001 From: Mathijs Bernson Date: Thu, 7 Dec 2017 17:54:03 +0100 Subject: [PATCH 08/27] Allow permitted IPs to be null in interactive installer --- src/Util/InstallationUtil.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Util/InstallationUtil.php b/src/Util/InstallationUtil.php index 6f2cd614..f7c89e11 100644 --- a/src/Util/InstallationUtil.php +++ b/src/Util/InstallationUtil.php @@ -190,7 +190,7 @@ private static function createAccessibleReflectionMethod(string $class, string $ * * @return string[] */ - private static function formatIps(string $permittedIpsInput): array + private static function formatIps(string $permittedIpsInput = null): array { if (is_null($permittedIpsInput)) { $permittedIps = []; From 2f894fc8926c4d7bf2a9a61e3ae9575f9cd58474 Mon Sep 17 00:00:00 2001 From: Kevin Hellemun Date: Wed, 20 Dec 2017 15:56:56 +0100 Subject: [PATCH 09/27] Added abstract method isAllFieldNull(). (bunq/sdk_php#68) --- src/Model/Core/BunqModel.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Model/Core/BunqModel.php b/src/Model/Core/BunqModel.php index 4d5515e4..40048fbe 100644 --- a/src/Model/Core/BunqModel.php +++ b/src/Model/Core/BunqModel.php @@ -101,7 +101,7 @@ public static function createFromJsonString(string $json): BunqModel * * @throws BunqException */ - abstract protected function areAllFieldsNull(); + abstract protected function isAllFieldNull(); /** * @param mixed[] $responseArray From 40187ae02574935c147e2be4d639a811278003df Mon Sep 17 00:00:00 2001 From: Kevin Hellemun Date: Fri, 17 Nov 2017 17:25:45 +0100 Subject: [PATCH 10/27] Changed method signature. (bunq/sdk_php#68) --- src/Model/Core/BunqModel.php | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/Model/Core/BunqModel.php b/src/Model/Core/BunqModel.php index 40048fbe..51276495 100644 --- a/src/Model/Core/BunqModel.php +++ b/src/Model/Core/BunqModel.php @@ -125,11 +125,15 @@ protected static function createListFromResponseArray( /** * @param mixed[] $responseArray * @param string $wrapper + * @param int $depthCounter * * @return BunqModel|null */ - protected static function createFromResponseArray(array $responseArray, string $wrapper = null) - { + protected static function createFromResponseArray( + array $responseArray, + string $wrapper = null, + int $depthCounter = null + ) { if (is_string($wrapper)) { $responseArray = $responseArray[$wrapper]; } From e9787d61a2c2afa50fc704f17339a27223161ad2 Mon Sep 17 00:00:00 2001 From: Kevin Hellemun Date: Fri, 17 Nov 2017 17:26:05 +0100 Subject: [PATCH 11/27] New method body. (bunq/sdk_php#68) --- src/Model/Core/BunqModel.php | 26 ++++++++++++++++++++++++-- 1 file changed, 24 insertions(+), 2 deletions(-) diff --git a/src/Model/Core/BunqModel.php b/src/Model/Core/BunqModel.php index 51276495..34114019 100644 --- a/src/Model/Core/BunqModel.php +++ b/src/Model/Core/BunqModel.php @@ -140,9 +140,31 @@ protected static function createFromResponseArray( if (is_null($responseArray)) { return null; - } else { - return self::createInstanceFromResponseArray($responseArray); } + + if ($depthCounter === null) { + $depthCounter = self::DEPTH_COUNTER_BEGIN; + } + + $model = self::createInstanceFromResponseArray($responseArray); + + if ($model->areAllFieldsNull() && $depthCounter < self::DEPTH_COUNTER_MAX) { + $modelFields = (array_keys(get_object_vars($model))); + + foreach ($modelFields as $field) { + try { + $fieldClass = ModelUtil::determineModelClassNameQualified($field); + $reflectionClass = new ReflectionClass($fieldClass); + /** @var BunqModel $bunqModelSubClass */ + $bunqModelSubClass = $reflectionClass->newInstanceWithoutConstructor(); + $model->$field = $bunqModelSubClass::createFromResponseArray($responseArray, null, $depthCounter++); + } catch (BunqException $exception) { + continue; + } + } + } + + return $model; } /** From 23752798ff75456d73c42f9329db99702ab32eb5 Mon Sep 17 00:00:00 2001 From: Kevin Hellemun Date: Fri, 17 Nov 2017 17:26:20 +0100 Subject: [PATCH 12/27] Added new BunqModel constants. (bunq/sdk_php#68) --- src/Model/Core/BunqModel.php | 23 +- src/Model/Core/Id.php | 12 + src/Model/Core/Installation.php | 24 ++ src/Model/Core/ServerPublicKey.php | 24 +- src/Model/Core/SessionServer.php | 24 ++ src/Model/Core/Token.php | 24 ++ src/Model/Core/Uuid.php | 12 + .../AttachmentConversationContent.php | 8 + .../Endpoint/AttachmentMonetaryAccount.php | 16 ++ .../Generated/Endpoint/AttachmentPublic.php | 24 ++ .../Endpoint/AttachmentPublicContent.php | 8 + .../Generated/Endpoint/AttachmentTab.php | 24 ++ .../Endpoint/AttachmentTabContent.php | 8 + src/Model/Generated/Endpoint/Avatar.php | 16 ++ .../Endpoint/BillingContractSubscription.php | 36 +++ src/Model/Generated/Endpoint/BunqMeTab.php | 44 ++++ .../Generated/Endpoint/BunqMeTabEntry.php | 36 +++ .../Endpoint/BunqMeTabResultInquiry.php | 12 + .../Endpoint/BunqMeTabResultResponse.php | 12 + src/Model/Generated/Endpoint/Card.php | 92 +++++++ src/Model/Generated/Endpoint/CardDebit.php | 88 +++++++ .../Generated/Endpoint/CardGeneratedCvc2.php | 32 +++ src/Model/Generated/Endpoint/CardName.php | 12 + .../Generated/Endpoint/CardPinChange.php | 32 +++ src/Model/Generated/Endpoint/CardReplace.php | 12 + src/Model/Generated/Endpoint/CardResult.php | 72 ++++++ src/Model/Generated/Endpoint/CashRegister.php | 44 ++++ .../Generated/Endpoint/CashRegisterQrCode.php | 32 +++ .../Endpoint/CashRegisterQrCodeContent.php | 8 + .../Generated/Endpoint/CertificatePinned.php | 16 ++ .../Generated/Endpoint/ChatConversation.php | 16 ++ .../Endpoint/ChatConversationReference.php | 20 ++ .../ChatConversationSupportExternal.php | 24 ++ src/Model/Generated/Endpoint/ChatMessage.php | 20 ++ .../Endpoint/ChatMessageAnnouncement.php | 32 +++ .../Endpoint/ChatMessageAttachment.php | 12 + .../Generated/Endpoint/ChatMessageStatus.php | 32 +++ .../Generated/Endpoint/ChatMessageText.php | 12 + .../Generated/Endpoint/ChatMessageUser.php | 36 +++ src/Model/Generated/Endpoint/Customer.php | 24 ++ .../Generated/Endpoint/CustomerLimit.php | 28 +++ .../Endpoint/CustomerStatementExport.php | 48 ++++ .../CustomerStatementExportContent.php | 8 + src/Model/Generated/Endpoint/Device.php | 12 + src/Model/Generated/Endpoint/DeviceServer.php | 32 +++ src/Model/Generated/Endpoint/DraftPayment.php | 40 +++ .../Endpoint/DraftShareInviteBank.php | 36 +++ .../DraftShareInviteBankQrCodeContent.php | 8 + .../Endpoint/ExportAnnualOverview.php | 28 +++ .../Endpoint/ExportAnnualOverviewContent.php | 8 + .../Endpoint/IdealMerchantTransaction.php | 64 +++++ .../Endpoint/InstallationServerPublicKey.php | 12 + src/Model/Generated/Endpoint/Invoice.php | 72 ++++++ .../Generated/Endpoint/InvoiceByUser.php | 72 ++++++ .../Generated/Endpoint/MasterCardAction.php | 100 ++++++++ .../Generated/Endpoint/MonetaryAccount.php | 12 + .../Endpoint/MonetaryAccountBank.php | 88 +++++++ .../Endpoint/MonetaryAccountProfile.php | 16 ++ src/Model/Generated/Endpoint/Payment.php | 100 ++++++++ src/Model/Generated/Endpoint/PaymentBatch.php | 12 + src/Model/Generated/Endpoint/PaymentChat.php | 24 ++ src/Model/Generated/Endpoint/PermittedIp.php | 16 ++ .../Generated/Endpoint/PromotionDisplay.php | 24 ++ .../Generated/Endpoint/RequestInquiry.php | 108 ++++++++ .../Endpoint/RequestInquiryBatch.php | 16 ++ .../Generated/Endpoint/RequestInquiryChat.php | 24 ++ .../Generated/Endpoint/RequestResponse.php | 108 ++++++++ .../Endpoint/RequestResponseChat.php | 24 ++ src/Model/Generated/Endpoint/Schedule.php | 32 +++ .../Generated/Endpoint/ScheduleInstance.php | 32 +++ .../Generated/Endpoint/SchedulePayment.php | 16 ++ .../Endpoint/SchedulePaymentBatch.php | 16 ++ src/Model/Generated/Endpoint/ScheduleUser.php | 8 + src/Model/Generated/Endpoint/Session.php | 8 + .../Endpoint/ShareInviteBankAmountUsed.php | 8 + .../Endpoint/ShareInviteBankInquiry.php | 56 +++++ .../Endpoint/ShareInviteBankResponse.php | 48 ++++ src/Model/Generated/Endpoint/Tab.php | 16 ++ .../Generated/Endpoint/TabAttachmentTab.php | 24 ++ .../Endpoint/TabAttachmentTabContent.php | 8 + src/Model/Generated/Endpoint/TabItem.php | 36 +++ src/Model/Generated/Endpoint/TabItemShop.php | 36 +++ .../Generated/Endpoint/TabItemShopBatch.php | 12 + .../Generated/Endpoint/TabQrCodeContent.php | 8 + .../Generated/Endpoint/TabResultInquiry.php | 16 ++ .../Generated/Endpoint/TabResultResponse.php | 16 ++ .../Generated/Endpoint/TabUsageMultiple.php | 76 ++++++ .../Generated/Endpoint/TabUsageSingle.php | 84 +++++++ .../Endpoint/TokenQrRequestIdeal.php | 88 +++++++ src/Model/Generated/Endpoint/User.php | 20 ++ src/Model/Generated/Endpoint/UserCompany.php | 124 ++++++++++ .../Endpoint/UserCredentialPasswordIp.php | 36 +++ src/Model/Generated/Endpoint/UserLight.php | 136 +++++++++++ src/Model/Generated/Endpoint/UserPerson.php | 132 ++++++++++ src/Model/Generated/Object/Address.php | 36 +++ src/Model/Generated/Object/Amount.php | 16 ++ src/Model/Generated/Object/AnchoredObject.php | 80 ++++++ src/Model/Generated/Object/Attachment.php | 16 ++ .../AttachmentMonetaryAccountPayment.php | 16 ++ .../Generated/Object/AttachmentPublic.php | 20 ++ src/Model/Generated/Object/AttachmentTab.php | 20 ++ src/Model/Generated/Object/Avatar.php | 20 ++ .../Generated/Object/BudgetRestriction.php | 16 ++ src/Model/Generated/Object/BunqId.php | 12 + .../Object/BunqMeMerchantAvailable.php | 16 ++ .../Object/CardCountryPermission.php | 20 ++ src/Model/Generated/Object/CardLimit.php | 24 ++ .../Object/CardMagStripePermission.php | 12 + .../Generated/Object/CardPinAssignment.php | 16 ++ src/Model/Generated/Object/Certificate.php | 12 + .../Generated/Object/ChatMessageContent.php | 36 +++ .../Object/ChatMessageContentAnchorEvent.php | 12 + .../Object/ChatMessageContentAttachment.php | 12 + .../Object/ChatMessageContentGeolocation.php | 12 + .../ChatMessageContentStatusConversation.php | 12 + ...tMessageContentStatusConversationTitle.php | 12 + .../ChatMessageContentStatusMembership.php | 16 ++ .../Object/ChatMessageContentText.php | 12 + .../Object/DraftPaymentAnchorObject.php | 16 ++ .../Generated/Object/DraftPaymentEntry.php | 40 +++ .../Generated/Object/DraftPaymentResponse.php | 16 ++ .../Object/DraftShareInviteBankEntry.php | 20 ++ src/Model/Generated/Object/Error.php | 16 ++ src/Model/Generated/Object/Geolocation.php | 24 ++ src/Model/Generated/Object/Image.php | 24 ++ src/Model/Generated/Object/InvoiceItem.php | 44 ++++ .../Generated/Object/InvoiceItemGroup.php | 36 +++ src/Model/Generated/Object/Issuer.php | 16 ++ src/Model/Generated/Object/LabelCard.php | 32 +++ .../Generated/Object/LabelMonetaryAccount.php | 44 ++++ src/Model/Generated/Object/LabelUser.php | 28 +++ .../Object/MonetaryAccountProfileDrain.php | 24 ++ .../Object/MonetaryAccountProfileFill.php | 28 +++ .../Object/MonetaryAccountSetting.php | 20 ++ .../Object/NotificationAnchorObject.php | 231 ++++++++++-------- .../Generated/Object/NotificationFilter.php | 20 ++ .../Generated/Object/NotificationUrl.php | 24 ++ .../Generated/Object/PermittedDevice.php | 16 ++ src/Model/Generated/Object/Pointer.php | 20 ++ .../Generated/Object/ScheduleAnchorObject.php | 16 ++ .../Object/ScheduleInstanceAnchorObject.php | 16 ++ .../Generated/Object/SchedulePaymentEntry.php | 32 +++ src/Model/Generated/Object/ShareDetail.php | 20 ++ .../Object/ShareDetailDraftPayment.php | 24 ++ .../Generated/Object/ShareDetailPayment.php | 32 +++ .../Generated/Object/ShareDetailReadOnly.php | 20 ++ .../Generated/Object/TabTextWaitingScreen.php | 16 ++ src/Model/Generated/Object/TabVisibility.php | 20 ++ src/Model/Generated/Object/TaxResident.php | 16 ++ src/Model/Generated/Object/Ubo.php | 20 ++ 150 files changed, 4620 insertions(+), 114 deletions(-) diff --git a/src/Model/Core/BunqModel.php b/src/Model/Core/BunqModel.php index 34114019..37377993 100644 --- a/src/Model/Core/BunqModel.php +++ b/src/Model/Core/BunqModel.php @@ -42,6 +42,13 @@ abstract class BunqModel implements JsonSerializable */ const INDEX_FIRST = 0; + /** + * Depth counter constants. + */ + const DEPTH_COUNTER_BEGIN = 0; + const DEPTH_COUNTER_MAX = 2; + const DEPTH_COUNTER_INCREMENTER = 1; + /** * Type constants. */ @@ -98,8 +105,6 @@ public static function createFromJsonString(string $json): BunqModel /** * @return bool - * - * @throws BunqException */ abstract protected function isAllFieldNull(); @@ -142,7 +147,7 @@ protected static function createFromResponseArray( return null; } - if ($depthCounter === null) { + if (is_null($depthCounter)) { $depthCounter = self::DEPTH_COUNTER_BEGIN; } @@ -157,7 +162,17 @@ protected static function createFromResponseArray( $reflectionClass = new ReflectionClass($fieldClass); /** @var BunqModel $bunqModelSubClass */ $bunqModelSubClass = $reflectionClass->newInstanceWithoutConstructor(); - $model->$field = $bunqModelSubClass::createFromResponseArray($responseArray, null, $depthCounter++); + $fieldContents = $bunqModelSubClass::createFromResponseArray( + $responseArray, + null, + $depthCounter + self::DEPTH_COUNTER_INCREMENTER + ); + + if ($fieldContents->areAllFieldsNull()) { + $model->{$field} = null; + } else { + $model->{$field} = $fieldContents; + } } catch (BunqException $exception) { continue; } diff --git a/src/Model/Core/Id.php b/src/Model/Core/Id.php index e8f41eaa..42a32f88 100644 --- a/src/Model/Core/Id.php +++ b/src/Model/Core/Id.php @@ -17,4 +17,16 @@ public function getId(): int { return $this->id; } + + /** + * @return bool + */ + protected function areAllFieldsNull() + { + if (!is_null($this->id)) { + return false; + } + + return true; + } } diff --git a/src/Model/Core/Installation.php b/src/Model/Core/Installation.php index 15bb284b..8e574af9 100644 --- a/src/Model/Core/Installation.php +++ b/src/Model/Core/Installation.php @@ -105,4 +105,28 @@ public function jsonSerialize(): array self::FIELD_CLIENT_PUBLIC_KEY => $this->clientPublicKey, ]; } + + /** + * @return bool + */ + protected function areAllFieldsNull() + { + if (!is_null($this->id)) { + return false; + } + + if (!is_null($this->token)) { + return false; + } + + if (!is_null($this->serverPublicKey)) { + return false; + } + + if (!is_null($this->clientPublicKey)) { + return false; + } + + return true; + } } diff --git a/src/Model/Core/ServerPublicKey.php b/src/Model/Core/ServerPublicKey.php index 9eaaa071..930d6874 100644 --- a/src/Model/Core/ServerPublicKey.php +++ b/src/Model/Core/ServerPublicKey.php @@ -34,13 +34,31 @@ public function getServerPublicKey(): PublicKey } /** - * @param mixed[] $responseArray + * @param array $responseArray * @param string|null $wrapper + * @param int|null $depthCounter * * @return static */ - public static function createFromResponseArray(array $responseArray, string $wrapper = null): ServerPublicKey - { + protected static function createFromResponseArray( + array $responseArray, + string $wrapper = null, + int $depthCounter = null + ) { return new static($responseArray[self::FIELD_SERVER_PUBLIC_KEY]); } + + + + /** + * @return bool + */ + protected function areAllFieldsNull() + { + if (!is_null($this->serverPublicKey)) { + return false; + } + + return true; + } } diff --git a/src/Model/Core/SessionServer.php b/src/Model/Core/SessionServer.php index 9afeae67..c72fc679 100644 --- a/src/Model/Core/SessionServer.php +++ b/src/Model/Core/SessionServer.php @@ -86,4 +86,28 @@ public function getUserPerson() { return $this->userPerson; } + + /** + * @return bool + */ + protected function areAllFieldsNull() + { + if (!is_null($this->token)) { + return false; + } + + if (!is_null($this->id)) { + return false; + } + + if (!is_null($this->userCompany)) { + return false; + } + + if (!is_null($this->userPerson)) { + return false; + } + + return true; + } } diff --git a/src/Model/Core/Token.php b/src/Model/Core/Token.php index 3069c414..9d51c7e9 100644 --- a/src/Model/Core/Token.php +++ b/src/Model/Core/Token.php @@ -40,4 +40,28 @@ public function getToken(): string { return $this->token; } + + /** + * @return bool + */ + protected function areAllFieldsNull() + { + if (!is_null($this->id)) { + return false; + } + + if (!is_null($this->created)) { + return false; + } + + if (!is_null($this->updated)) { + return false; + } + + if (!is_null($this->token)) { + return false; + } + + return true; + } } diff --git a/src/Model/Core/Uuid.php b/src/Model/Core/Uuid.php index a9c5e304..4d51b057 100644 --- a/src/Model/Core/Uuid.php +++ b/src/Model/Core/Uuid.php @@ -17,4 +17,16 @@ public function getUuid(): string { return $this->uuid; } + + /** + * @return bool + */ + protected function areAllFieldsNull() + { + if (!is_null($this->uuid)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/AttachmentConversationContent.php b/src/Model/Generated/Endpoint/AttachmentConversationContent.php index 0afbb69d..5734df5d 100644 --- a/src/Model/Generated/Endpoint/AttachmentConversationContent.php +++ b/src/Model/Generated/Endpoint/AttachmentConversationContent.php @@ -54,4 +54,12 @@ public static function listing(ApiContext $apiContext, int $userId, int $chatCon new BunqResponse($responseRaw->getBodyString(), $responseRaw->getHeaders()) ); } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + return true; + } } diff --git a/src/Model/Generated/Endpoint/AttachmentMonetaryAccount.php b/src/Model/Generated/Endpoint/AttachmentMonetaryAccount.php index 6fe59326..a6cf2d07 100644 --- a/src/Model/Generated/Endpoint/AttachmentMonetaryAccount.php +++ b/src/Model/Generated/Endpoint/AttachmentMonetaryAccount.php @@ -115,4 +115,20 @@ public function setId($id) { $this->id = $id; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->attachment)) { + return false; + } + + if (!is_null($this->id)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/AttachmentPublic.php b/src/Model/Generated/Endpoint/AttachmentPublic.php index f0732bb8..7aadf01a 100644 --- a/src/Model/Generated/Endpoint/AttachmentPublic.php +++ b/src/Model/Generated/Endpoint/AttachmentPublic.php @@ -192,4 +192,28 @@ public function setAttachment($attachment) { $this->attachment = $attachment; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->uuid)) { + return false; + } + + if (!is_null($this->created)) { + return false; + } + + if (!is_null($this->updated)) { + return false; + } + + if (!is_null($this->attachment)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/AttachmentPublicContent.php b/src/Model/Generated/Endpoint/AttachmentPublicContent.php index f8c25da2..1e5d94b5 100644 --- a/src/Model/Generated/Endpoint/AttachmentPublicContent.php +++ b/src/Model/Generated/Endpoint/AttachmentPublicContent.php @@ -53,4 +53,12 @@ public static function listing(ApiContext $apiContext, string $attachmentPublicU new BunqResponse($responseRaw->getBodyString(), $responseRaw->getHeaders()) ); } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + return true; + } } diff --git a/src/Model/Generated/Endpoint/AttachmentTab.php b/src/Model/Generated/Endpoint/AttachmentTab.php index a050a1c7..e850a763 100644 --- a/src/Model/Generated/Endpoint/AttachmentTab.php +++ b/src/Model/Generated/Endpoint/AttachmentTab.php @@ -196,4 +196,28 @@ public function setAttachment($attachment) { $this->attachment = $attachment; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->id)) { + return false; + } + + if (!is_null($this->created)) { + return false; + } + + if (!is_null($this->updated)) { + return false; + } + + if (!is_null($this->attachment)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/AttachmentTabContent.php b/src/Model/Generated/Endpoint/AttachmentTabContent.php index cb2f0049..94b3f6a5 100644 --- a/src/Model/Generated/Endpoint/AttachmentTabContent.php +++ b/src/Model/Generated/Endpoint/AttachmentTabContent.php @@ -54,4 +54,12 @@ public static function listing(ApiContext $apiContext, int $userId, int $monetar new BunqResponse($responseRaw->getBodyString(), $responseRaw->getHeaders()) ); } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + return true; + } } diff --git a/src/Model/Generated/Endpoint/Avatar.php b/src/Model/Generated/Endpoint/Avatar.php index 2ae97b87..619d7f6b 100644 --- a/src/Model/Generated/Endpoint/Avatar.php +++ b/src/Model/Generated/Endpoint/Avatar.php @@ -133,4 +133,20 @@ public function setImage($image) { $this->image = $image; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->uuid)) { + return false; + } + + if (!is_null($this->image)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/BillingContractSubscription.php b/src/Model/Generated/Endpoint/BillingContractSubscription.php index 39630169..b3b20259 100644 --- a/src/Model/Generated/Endpoint/BillingContractSubscription.php +++ b/src/Model/Generated/Endpoint/BillingContractSubscription.php @@ -262,4 +262,40 @@ public function setSubscriptionType($subscriptionType) { $this->subscriptionType = $subscriptionType; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->id)) { + return false; + } + + if (!is_null($this->created)) { + return false; + } + + if (!is_null($this->updated)) { + return false; + } + + if (!is_null($this->contractDateStart)) { + return false; + } + + if (!is_null($this->contractDateEnd)) { + return false; + } + + if (!is_null($this->contractVersion)) { + return false; + } + + if (!is_null($this->subscriptionType)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/BunqMeTab.php b/src/Model/Generated/Endpoint/BunqMeTab.php index 86c79044..973ee46e 100644 --- a/src/Model/Generated/Endpoint/BunqMeTab.php +++ b/src/Model/Generated/Endpoint/BunqMeTab.php @@ -368,4 +368,48 @@ public function setResultInquiries($resultInquiries) { $this->resultInquiries = $resultInquiries; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->id)) { + return false; + } + + if (!is_null($this->created)) { + return false; + } + + if (!is_null($this->updated)) { + return false; + } + + if (!is_null($this->timeExpiry)) { + return false; + } + + if (!is_null($this->monetaryAccountId)) { + return false; + } + + if (!is_null($this->status)) { + return false; + } + + if (!is_null($this->bunqmeTabShareUrl)) { + return false; + } + + if (!is_null($this->bunqmeTabEntry)) { + return false; + } + + if (!is_null($this->resultInquiries)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/BunqMeTabEntry.php b/src/Model/Generated/Endpoint/BunqMeTabEntry.php index 9bff0fff..04fa5294 100644 --- a/src/Model/Generated/Endpoint/BunqMeTabEntry.php +++ b/src/Model/Generated/Endpoint/BunqMeTabEntry.php @@ -205,4 +205,40 @@ public function setMerchantAvailable($merchantAvailable) { $this->merchantAvailable = $merchantAvailable; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->uuid)) { + return false; + } + + if (!is_null($this->amountInquired)) { + return false; + } + + if (!is_null($this->alias)) { + return false; + } + + if (!is_null($this->description)) { + return false; + } + + if (!is_null($this->status)) { + return false; + } + + if (!is_null($this->redirectUrl)) { + return false; + } + + if (!is_null($this->merchantAvailable)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/BunqMeTabResultInquiry.php b/src/Model/Generated/Endpoint/BunqMeTabResultInquiry.php index cfeacb4d..51cad454 100644 --- a/src/Model/Generated/Endpoint/BunqMeTabResultInquiry.php +++ b/src/Model/Generated/Endpoint/BunqMeTabResultInquiry.php @@ -41,4 +41,16 @@ public function setPayment($payment) { $this->payment = $payment; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->payment)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/BunqMeTabResultResponse.php b/src/Model/Generated/Endpoint/BunqMeTabResultResponse.php index 30518190..52ee40dd 100644 --- a/src/Model/Generated/Endpoint/BunqMeTabResultResponse.php +++ b/src/Model/Generated/Endpoint/BunqMeTabResultResponse.php @@ -41,4 +41,16 @@ public function setPayment($payment) { $this->payment = $payment; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->payment)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/Card.php b/src/Model/Generated/Endpoint/Card.php index 097595f6..315699f1 100644 --- a/src/Model/Generated/Endpoint/Card.php +++ b/src/Model/Generated/Endpoint/Card.php @@ -674,4 +674,96 @@ public function setCountry($country) { $this->country = $country; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->id)) { + return false; + } + + if (!is_null($this->created)) { + return false; + } + + if (!is_null($this->updated)) { + return false; + } + + if (!is_null($this->publicUuid)) { + return false; + } + + if (!is_null($this->type)) { + return false; + } + + if (!is_null($this->subType)) { + return false; + } + + if (!is_null($this->secondLine)) { + return false; + } + + if (!is_null($this->status)) { + return false; + } + + if (!is_null($this->subStatus)) { + return false; + } + + if (!is_null($this->orderStatus)) { + return false; + } + + if (!is_null($this->expiryDate)) { + return false; + } + + if (!is_null($this->nameOnCard)) { + return false; + } + + if (!is_null($this->primaryAccountNumberFourDigit)) { + return false; + } + + if (!is_null($this->limit)) { + return false; + } + + if (!is_null($this->magStripePermission)) { + return false; + } + + if (!is_null($this->countryPermission)) { + return false; + } + + if (!is_null($this->labelMonetaryAccountOrdered)) { + return false; + } + + if (!is_null($this->labelMonetaryAccountCurrent)) { + return false; + } + + if (!is_null($this->pinCodeAssignment)) { + return false; + } + + if (!is_null($this->monetaryAccountIdFallback)) { + return false; + } + + if (!is_null($this->country)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/CardDebit.php b/src/Model/Generated/Endpoint/CardDebit.php index 5f5df7d0..dd09ce0a 100644 --- a/src/Model/Generated/Endpoint/CardDebit.php +++ b/src/Model/Generated/Endpoint/CardDebit.php @@ -583,4 +583,92 @@ public function setCountry($country) { $this->country = $country; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->id)) { + return false; + } + + if (!is_null($this->created)) { + return false; + } + + if (!is_null($this->updated)) { + return false; + } + + if (!is_null($this->publicUuid)) { + return false; + } + + if (!is_null($this->type)) { + return false; + } + + if (!is_null($this->subType)) { + return false; + } + + if (!is_null($this->secondLine)) { + return false; + } + + if (!is_null($this->nameOnCard)) { + return false; + } + + if (!is_null($this->primaryAccountNumberFourDigit)) { + return false; + } + + if (!is_null($this->status)) { + return false; + } + + if (!is_null($this->orderStatus)) { + return false; + } + + if (!is_null($this->expiryDate)) { + return false; + } + + if (!is_null($this->limit)) { + return false; + } + + if (!is_null($this->countryPermission)) { + return false; + } + + if (!is_null($this->labelMonetaryAccountOrdered)) { + return false; + } + + if (!is_null($this->labelMonetaryAccountCurrent)) { + return false; + } + + if (!is_null($this->alias)) { + return false; + } + + if (!is_null($this->pinCodeAssignment)) { + return false; + } + + if (!is_null($this->monetaryAccountIdFallback)) { + return false; + } + + if (!is_null($this->country)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/CardGeneratedCvc2.php b/src/Model/Generated/Endpoint/CardGeneratedCvc2.php index bdd8f54b..fd697d80 100644 --- a/src/Model/Generated/Endpoint/CardGeneratedCvc2.php +++ b/src/Model/Generated/Endpoint/CardGeneratedCvc2.php @@ -262,4 +262,36 @@ public function setExpiryTime($expiryTime) { $this->expiryTime = $expiryTime; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->id)) { + return false; + } + + if (!is_null($this->created)) { + return false; + } + + if (!is_null($this->updated)) { + return false; + } + + if (!is_null($this->cvc2)) { + return false; + } + + if (!is_null($this->status)) { + return false; + } + + if (!is_null($this->expiryTime)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/CardName.php b/src/Model/Generated/Endpoint/CardName.php index 19d999ff..663dbea3 100644 --- a/src/Model/Generated/Endpoint/CardName.php +++ b/src/Model/Generated/Endpoint/CardName.php @@ -82,4 +82,16 @@ public function setPossibleCardNameArray($possibleCardNameArray) { $this->possibleCardNameArray = $possibleCardNameArray; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->possibleCardNameArray)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/CardPinChange.php b/src/Model/Generated/Endpoint/CardPinChange.php index 4606f30f..d545e217 100644 --- a/src/Model/Generated/Endpoint/CardPinChange.php +++ b/src/Model/Generated/Endpoint/CardPinChange.php @@ -234,4 +234,36 @@ public function setStatus($status) { $this->status = $status; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->id)) { + return false; + } + + if (!is_null($this->labelCard)) { + return false; + } + + if (!is_null($this->labelMonetaryAccountCurrent)) { + return false; + } + + if (!is_null($this->timeRequest)) { + return false; + } + + if (!is_null($this->timeAccept)) { + return false; + } + + if (!is_null($this->status)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/CardReplace.php b/src/Model/Generated/Endpoint/CardReplace.php index a07be4e1..59be2903 100644 --- a/src/Model/Generated/Endpoint/CardReplace.php +++ b/src/Model/Generated/Endpoint/CardReplace.php @@ -87,4 +87,16 @@ public function setId($id) { $this->id = $id; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->id)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/CardResult.php b/src/Model/Generated/Endpoint/CardResult.php index f2d3d819..bc3dbb6e 100644 --- a/src/Model/Generated/Endpoint/CardResult.php +++ b/src/Model/Generated/Endpoint/CardResult.php @@ -485,4 +485,76 @@ public function setReservationExpiryTime($reservationExpiryTime) { $this->reservationExpiryTime = $reservationExpiryTime; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->monetaryAccountId)) { + return false; + } + + if (!is_null($this->cardId)) { + return false; + } + + if (!is_null($this->amountOriginal)) { + return false; + } + + if (!is_null($this->amountFinal)) { + return false; + } + + if (!is_null($this->decision)) { + return false; + } + + if (!is_null($this->decisionDescription)) { + return false; + } + + if (!is_null($this->decisionDescriptionTranslated)) { + return false; + } + + if (!is_null($this->description)) { + return false; + } + + if (!is_null($this->messageType)) { + return false; + } + + if (!is_null($this->authorisationType)) { + return false; + } + + if (!is_null($this->city)) { + return false; + } + + if (!is_null($this->alias)) { + return false; + } + + if (!is_null($this->counterpartyAlias)) { + return false; + } + + if (!is_null($this->labelCard)) { + return false; + } + + if (!is_null($this->reservationStatus)) { + return false; + } + + if (!is_null($this->reservationExpiryTime)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/CashRegister.php b/src/Model/Generated/Endpoint/CashRegister.php index c8df8b72..1e1ef406 100644 --- a/src/Model/Generated/Endpoint/CashRegister.php +++ b/src/Model/Generated/Endpoint/CashRegister.php @@ -397,4 +397,48 @@ public function setTabTextWaitingScreen($tabTextWaitingScreen) { $this->tabTextWaitingScreen = $tabTextWaitingScreen; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->id)) { + return false; + } + + if (!is_null($this->created)) { + return false; + } + + if (!is_null($this->updated)) { + return false; + } + + if (!is_null($this->name)) { + return false; + } + + if (!is_null($this->status)) { + return false; + } + + if (!is_null($this->avatar)) { + return false; + } + + if (!is_null($this->location)) { + return false; + } + + if (!is_null($this->notificationFilters)) { + return false; + } + + if (!is_null($this->tabTextWaitingScreen)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/CashRegisterQrCode.php b/src/Model/Generated/Endpoint/CashRegisterQrCode.php index 9a9649cf..a1e42cb0 100644 --- a/src/Model/Generated/Endpoint/CashRegisterQrCode.php +++ b/src/Model/Generated/Endpoint/CashRegisterQrCode.php @@ -312,4 +312,36 @@ public function setTabObject($tabObject) { $this->tabObject = $tabObject; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->id)) { + return false; + } + + if (!is_null($this->created)) { + return false; + } + + if (!is_null($this->updated)) { + return false; + } + + if (!is_null($this->status)) { + return false; + } + + if (!is_null($this->cashRegister)) { + return false; + } + + if (!is_null($this->tabObject)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/CashRegisterQrCodeContent.php b/src/Model/Generated/Endpoint/CashRegisterQrCodeContent.php index 234a06f0..dac4013a 100644 --- a/src/Model/Generated/Endpoint/CashRegisterQrCodeContent.php +++ b/src/Model/Generated/Endpoint/CashRegisterQrCodeContent.php @@ -55,4 +55,12 @@ public static function listing(ApiContext $apiContext, int $userId, int $monetar new BunqResponse($responseRaw->getBodyString(), $responseRaw->getHeaders()) ); } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + return true; + } } diff --git a/src/Model/Generated/Endpoint/CertificatePinned.php b/src/Model/Generated/Endpoint/CertificatePinned.php index d318112d..8c1a9eaa 100644 --- a/src/Model/Generated/Endpoint/CertificatePinned.php +++ b/src/Model/Generated/Endpoint/CertificatePinned.php @@ -194,4 +194,20 @@ public function setId($id) { $this->id = $id; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->certificateChain)) { + return false; + } + + if (!is_null($this->id)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/ChatConversation.php b/src/Model/Generated/Endpoint/ChatConversation.php index 14968735..6f802d3a 100644 --- a/src/Model/Generated/Endpoint/ChatConversation.php +++ b/src/Model/Generated/Endpoint/ChatConversation.php @@ -141,4 +141,20 @@ public function getReferencedObject() throw new BunqException(self::ERROR_NULL_FIELDS); } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->supportConversationExternal)) { + return false; + } + + if (!is_null($this->chatConversationReference)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/ChatConversationReference.php b/src/Model/Generated/Endpoint/ChatConversationReference.php index c8e57fae..1bd7fe89 100644 --- a/src/Model/Generated/Endpoint/ChatConversationReference.php +++ b/src/Model/Generated/Endpoint/ChatConversationReference.php @@ -89,4 +89,24 @@ public function setUpdated($updated) { $this->updated = $updated; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->id)) { + return false; + } + + if (!is_null($this->created)) { + return false; + } + + if (!is_null($this->updated)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/ChatConversationSupportExternal.php b/src/Model/Generated/Endpoint/ChatConversationSupportExternal.php index 6f9981dc..5ebe108d 100644 --- a/src/Model/Generated/Endpoint/ChatConversationSupportExternal.php +++ b/src/Model/Generated/Endpoint/ChatConversationSupportExternal.php @@ -114,4 +114,28 @@ public function setLastMessage($lastMessage) { $this->lastMessage = $lastMessage; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->id)) { + return false; + } + + if (!is_null($this->created)) { + return false; + } + + if (!is_null($this->updated)) { + return false; + } + + if (!is_null($this->lastMessage)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/ChatMessage.php b/src/Model/Generated/Endpoint/ChatMessage.php index 8a4950d8..17c619a5 100644 --- a/src/Model/Generated/Endpoint/ChatMessage.php +++ b/src/Model/Generated/Endpoint/ChatMessage.php @@ -143,4 +143,24 @@ public function getReferencedObject() throw new BunqException(self::ERROR_NULL_FIELDS); } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->chatMessageAnnouncement)) { + return false; + } + + if (!is_null($this->chatMessageStatus)) { + return false; + } + + if (!is_null($this->chatMessageUser)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/ChatMessageAnnouncement.php b/src/Model/Generated/Endpoint/ChatMessageAnnouncement.php index 7e978347..a5b2af92 100644 --- a/src/Model/Generated/Endpoint/ChatMessageAnnouncement.php +++ b/src/Model/Generated/Endpoint/ChatMessageAnnouncement.php @@ -166,4 +166,36 @@ public function setContent($content) { $this->content = $content; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->id)) { + return false; + } + + if (!is_null($this->created)) { + return false; + } + + if (!is_null($this->updated)) { + return false; + } + + if (!is_null($this->conversationId)) { + return false; + } + + if (!is_null($this->creator)) { + return false; + } + + if (!is_null($this->content)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/ChatMessageAttachment.php b/src/Model/Generated/Endpoint/ChatMessageAttachment.php index 8eda118f..140784ab 100644 --- a/src/Model/Generated/Endpoint/ChatMessageAttachment.php +++ b/src/Model/Generated/Endpoint/ChatMessageAttachment.php @@ -82,4 +82,16 @@ public function setId($id) { $this->id = $id; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->id)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/ChatMessageStatus.php b/src/Model/Generated/Endpoint/ChatMessageStatus.php index 1d8c9a34..a2e9ef23 100644 --- a/src/Model/Generated/Endpoint/ChatMessageStatus.php +++ b/src/Model/Generated/Endpoint/ChatMessageStatus.php @@ -166,4 +166,36 @@ public function setContent($content) { $this->content = $content; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->id)) { + return false; + } + + if (!is_null($this->created)) { + return false; + } + + if (!is_null($this->updated)) { + return false; + } + + if (!is_null($this->conversationId)) { + return false; + } + + if (!is_null($this->creator)) { + return false; + } + + if (!is_null($this->content)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/ChatMessageText.php b/src/Model/Generated/Endpoint/ChatMessageText.php index b7358390..2b068bc1 100644 --- a/src/Model/Generated/Endpoint/ChatMessageText.php +++ b/src/Model/Generated/Endpoint/ChatMessageText.php @@ -81,4 +81,16 @@ public function setId($id) { $this->id = $id; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->id)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/ChatMessageUser.php b/src/Model/Generated/Endpoint/ChatMessageUser.php index a543b07c..1876b04c 100644 --- a/src/Model/Generated/Endpoint/ChatMessageUser.php +++ b/src/Model/Generated/Endpoint/ChatMessageUser.php @@ -191,4 +191,40 @@ public function setContent($content) { $this->content = $content; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->id)) { + return false; + } + + if (!is_null($this->created)) { + return false; + } + + if (!is_null($this->updated)) { + return false; + } + + if (!is_null($this->conversationId)) { + return false; + } + + if (!is_null($this->creator)) { + return false; + } + + if (!is_null($this->displayedSender)) { + return false; + } + + if (!is_null($this->content)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/Customer.php b/src/Model/Generated/Endpoint/Customer.php index 88bbdf3b..bee3f6a8 100644 --- a/src/Model/Generated/Endpoint/Customer.php +++ b/src/Model/Generated/Endpoint/Customer.php @@ -208,4 +208,28 @@ public function setBillingAccountId($billingAccountId) { $this->billingAccountId = $billingAccountId; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->id)) { + return false; + } + + if (!is_null($this->created)) { + return false; + } + + if (!is_null($this->updated)) { + return false; + } + + if (!is_null($this->billingAccountId)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/CustomerLimit.php b/src/Model/Generated/Endpoint/CustomerLimit.php index 6e58584f..a3ca3f13 100644 --- a/src/Model/Generated/Endpoint/CustomerLimit.php +++ b/src/Model/Generated/Endpoint/CustomerLimit.php @@ -177,4 +177,32 @@ public function setLimitCardDebitReplacement($limitCardDebitReplacement) { $this->limitCardDebitReplacement = $limitCardDebitReplacement; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->limitMonetaryAccount)) { + return false; + } + + if (!is_null($this->limitCardDebitMaestro)) { + return false; + } + + if (!is_null($this->limitCardDebitMastercard)) { + return false; + } + + if (!is_null($this->limitCardDebitWildcard)) { + return false; + } + + if (!is_null($this->limitCardDebitReplacement)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/CustomerStatementExport.php b/src/Model/Generated/Endpoint/CustomerStatementExport.php index 6248d590..5c9e8295 100644 --- a/src/Model/Generated/Endpoint/CustomerStatementExport.php +++ b/src/Model/Generated/Endpoint/CustomerStatementExport.php @@ -391,4 +391,52 @@ public function setAliasMonetaryAccount($aliasMonetaryAccount) { $this->aliasMonetaryAccount = $aliasMonetaryAccount; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->id)) { + return false; + } + + if (!is_null($this->created)) { + return false; + } + + if (!is_null($this->updated)) { + return false; + } + + if (!is_null($this->dateStart)) { + return false; + } + + if (!is_null($this->dateEnd)) { + return false; + } + + if (!is_null($this->status)) { + return false; + } + + if (!is_null($this->statementNumber)) { + return false; + } + + if (!is_null($this->statementFormat)) { + return false; + } + + if (!is_null($this->regionalFormat)) { + return false; + } + + if (!is_null($this->aliasMonetaryAccount)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/CustomerStatementExportContent.php b/src/Model/Generated/Endpoint/CustomerStatementExportContent.php index acf815fd..4a29b5a2 100644 --- a/src/Model/Generated/Endpoint/CustomerStatementExportContent.php +++ b/src/Model/Generated/Endpoint/CustomerStatementExportContent.php @@ -54,4 +54,12 @@ public static function listing(ApiContext $apiContext, int $userId, int $monetar new BunqResponse($responseRaw->getBodyString(), $responseRaw->getHeaders()) ); } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + return true; + } } diff --git a/src/Model/Generated/Endpoint/Device.php b/src/Model/Generated/Endpoint/Device.php index 46659a43..c6f49635 100644 --- a/src/Model/Generated/Endpoint/Device.php +++ b/src/Model/Generated/Endpoint/Device.php @@ -120,4 +120,16 @@ public function getReferencedObject() throw new BunqException(self::ERROR_NULL_FIELDS); } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->deviceServer)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/DeviceServer.php b/src/Model/Generated/Endpoint/DeviceServer.php index 4ab64a13..4b2c56c6 100644 --- a/src/Model/Generated/Endpoint/DeviceServer.php +++ b/src/Model/Generated/Endpoint/DeviceServer.php @@ -272,4 +272,36 @@ public function setStatus($status) { $this->status = $status; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->id)) { + return false; + } + + if (!is_null($this->created)) { + return false; + } + + if (!is_null($this->updated)) { + return false; + } + + if (!is_null($this->description)) { + return false; + } + + if (!is_null($this->ip)) { + return false; + } + + if (!is_null($this->status)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/DraftPayment.php b/src/Model/Generated/Endpoint/DraftPayment.php index afaafd0c..94effb7e 100644 --- a/src/Model/Generated/Endpoint/DraftPayment.php +++ b/src/Model/Generated/Endpoint/DraftPayment.php @@ -356,4 +356,44 @@ public function setObject($object) { $this->object = $object; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->id)) { + return false; + } + + if (!is_null($this->monetaryAccountId)) { + return false; + } + + if (!is_null($this->userAliasCreated)) { + return false; + } + + if (!is_null($this->responses)) { + return false; + } + + if (!is_null($this->status)) { + return false; + } + + if (!is_null($this->type)) { + return false; + } + + if (!is_null($this->entries)) { + return false; + } + + if (!is_null($this->object)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/DraftShareInviteBank.php b/src/Model/Generated/Endpoint/DraftShareInviteBank.php index ce51a8d9..4b9bcbea 100644 --- a/src/Model/Generated/Endpoint/DraftShareInviteBank.php +++ b/src/Model/Generated/Endpoint/DraftShareInviteBank.php @@ -323,4 +323,40 @@ public function setId($id) { $this->id = $id; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->userAliasCreated)) { + return false; + } + + if (!is_null($this->status)) { + return false; + } + + if (!is_null($this->expiration)) { + return false; + } + + if (!is_null($this->shareInviteBankResponseId)) { + return false; + } + + if (!is_null($this->draftShareUrl)) { + return false; + } + + if (!is_null($this->draftShareSettings)) { + return false; + } + + if (!is_null($this->id)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/DraftShareInviteBankQrCodeContent.php b/src/Model/Generated/Endpoint/DraftShareInviteBankQrCodeContent.php index 10cee91a..9a46a789 100644 --- a/src/Model/Generated/Endpoint/DraftShareInviteBankQrCodeContent.php +++ b/src/Model/Generated/Endpoint/DraftShareInviteBankQrCodeContent.php @@ -56,4 +56,12 @@ public static function listing(ApiContext $apiContext, int $userId, int $draftSh new BunqResponse($responseRaw->getBodyString(), $responseRaw->getHeaders()) ); } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + return true; + } } diff --git a/src/Model/Generated/Endpoint/ExportAnnualOverview.php b/src/Model/Generated/Endpoint/ExportAnnualOverview.php index de5fac8b..de6eda8e 100644 --- a/src/Model/Generated/Endpoint/ExportAnnualOverview.php +++ b/src/Model/Generated/Endpoint/ExportAnnualOverview.php @@ -242,4 +242,32 @@ public function setAliasUser($aliasUser) { $this->aliasUser = $aliasUser; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->id)) { + return false; + } + + if (!is_null($this->created)) { + return false; + } + + if (!is_null($this->updated)) { + return false; + } + + if (!is_null($this->year)) { + return false; + } + + if (!is_null($this->aliasUser)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/ExportAnnualOverviewContent.php b/src/Model/Generated/Endpoint/ExportAnnualOverviewContent.php index f904f426..406aa4b5 100644 --- a/src/Model/Generated/Endpoint/ExportAnnualOverviewContent.php +++ b/src/Model/Generated/Endpoint/ExportAnnualOverviewContent.php @@ -54,4 +54,12 @@ public static function listing(ApiContext $apiContext, int $userId, int $exportA new BunqResponse($responseRaw->getBodyString(), $responseRaw->getHeaders()) ); } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + return true; + } } diff --git a/src/Model/Generated/Endpoint/IdealMerchantTransaction.php b/src/Model/Generated/Endpoint/IdealMerchantTransaction.php index 1eaf6704..37dab98d 100644 --- a/src/Model/Generated/Endpoint/IdealMerchantTransaction.php +++ b/src/Model/Generated/Endpoint/IdealMerchantTransaction.php @@ -465,4 +465,68 @@ public function setAllowChat($allowChat) { $this->allowChat = $allowChat; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->monetaryAccountId)) { + return false; + } + + if (!is_null($this->alias)) { + return false; + } + + if (!is_null($this->counterpartyAlias)) { + return false; + } + + if (!is_null($this->amountGuaranteed)) { + return false; + } + + if (!is_null($this->amountRequested)) { + return false; + } + + if (!is_null($this->expiration)) { + return false; + } + + if (!is_null($this->issuer)) { + return false; + } + + if (!is_null($this->issuerName)) { + return false; + } + + if (!is_null($this->issuerAuthenticationUrl)) { + return false; + } + + if (!is_null($this->purchaseIdentifier)) { + return false; + } + + if (!is_null($this->status)) { + return false; + } + + if (!is_null($this->statusTimestamp)) { + return false; + } + + if (!is_null($this->transactionIdentifier)) { + return false; + } + + if (!is_null($this->allowChat)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/InstallationServerPublicKey.php b/src/Model/Generated/Endpoint/InstallationServerPublicKey.php index f62294df..ffa410dd 100644 --- a/src/Model/Generated/Endpoint/InstallationServerPublicKey.php +++ b/src/Model/Generated/Endpoint/InstallationServerPublicKey.php @@ -79,4 +79,16 @@ public function setServerPublicKey($serverPublicKey) { $this->serverPublicKey = $serverPublicKey; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->serverPublicKey)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/Invoice.php b/src/Model/Generated/Endpoint/Invoice.php index bba343d3..ba2cac74 100644 --- a/src/Model/Generated/Endpoint/Invoice.php +++ b/src/Model/Generated/Endpoint/Invoice.php @@ -491,4 +491,76 @@ public function setVatNumber($vatNumber) { $this->vatNumber = $vatNumber; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->id)) { + return false; + } + + if (!is_null($this->created)) { + return false; + } + + if (!is_null($this->updated)) { + return false; + } + + if (!is_null($this->invoiceDate)) { + return false; + } + + if (!is_null($this->invoiceNumber)) { + return false; + } + + if (!is_null($this->status)) { + return false; + } + + if (!is_null($this->group)) { + return false; + } + + if (!is_null($this->totalVatInclusive)) { + return false; + } + + if (!is_null($this->totalVatExclusive)) { + return false; + } + + if (!is_null($this->totalVat)) { + return false; + } + + if (!is_null($this->alias)) { + return false; + } + + if (!is_null($this->address)) { + return false; + } + + if (!is_null($this->counterpartyAlias)) { + return false; + } + + if (!is_null($this->counterpartyAddress)) { + return false; + } + + if (!is_null($this->chamberOfCommerceNumber)) { + return false; + } + + if (!is_null($this->vatNumber)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/InvoiceByUser.php b/src/Model/Generated/Endpoint/InvoiceByUser.php index e8967a7e..0182c630 100644 --- a/src/Model/Generated/Endpoint/InvoiceByUser.php +++ b/src/Model/Generated/Endpoint/InvoiceByUser.php @@ -482,4 +482,76 @@ public function setVatNumber($vatNumber) { $this->vatNumber = $vatNumber; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->id)) { + return false; + } + + if (!is_null($this->created)) { + return false; + } + + if (!is_null($this->updated)) { + return false; + } + + if (!is_null($this->invoiceDate)) { + return false; + } + + if (!is_null($this->invoiceNumber)) { + return false; + } + + if (!is_null($this->status)) { + return false; + } + + if (!is_null($this->group)) { + return false; + } + + if (!is_null($this->totalVatInclusive)) { + return false; + } + + if (!is_null($this->totalVatExclusive)) { + return false; + } + + if (!is_null($this->totalVat)) { + return false; + } + + if (!is_null($this->alias)) { + return false; + } + + if (!is_null($this->address)) { + return false; + } + + if (!is_null($this->counterpartyAlias)) { + return false; + } + + if (!is_null($this->counterpartyAddress)) { + return false; + } + + if (!is_null($this->chamberOfCommerceNumber)) { + return false; + } + + if (!is_null($this->vatNumber)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/MasterCardAction.php b/src/Model/Generated/Endpoint/MasterCardAction.php index a5accdd6..7364e32a 100644 --- a/src/Model/Generated/Endpoint/MasterCardAction.php +++ b/src/Model/Generated/Endpoint/MasterCardAction.php @@ -666,4 +666,104 @@ public function setEligibleWhitelistId($eligibleWhitelistId) { $this->eligibleWhitelistId = $eligibleWhitelistId; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->monetaryAccountId)) { + return false; + } + + if (!is_null($this->cardId)) { + return false; + } + + if (!is_null($this->amountLocal)) { + return false; + } + + if (!is_null($this->amountBilling)) { + return false; + } + + if (!is_null($this->amountOriginalLocal)) { + return false; + } + + if (!is_null($this->amountOriginalBilling)) { + return false; + } + + if (!is_null($this->amountFee)) { + return false; + } + + if (!is_null($this->decision)) { + return false; + } + + if (!is_null($this->decisionDescription)) { + return false; + } + + if (!is_null($this->decisionDescriptionTranslated)) { + return false; + } + + if (!is_null($this->description)) { + return false; + } + + if (!is_null($this->authorisationStatus)) { + return false; + } + + if (!is_null($this->authorisationType)) { + return false; + } + + if (!is_null($this->panEntryModeUser)) { + return false; + } + + if (!is_null($this->city)) { + return false; + } + + if (!is_null($this->alias)) { + return false; + } + + if (!is_null($this->counterpartyAlias)) { + return false; + } + + if (!is_null($this->labelCard)) { + return false; + } + + if (!is_null($this->tokenStatus)) { + return false; + } + + if (!is_null($this->reservationExpiryTime)) { + return false; + } + + if (!is_null($this->appliedLimit)) { + return false; + } + + if (!is_null($this->allowChat)) { + return false; + } + + if (!is_null($this->eligibleWhitelistId)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/MonetaryAccount.php b/src/Model/Generated/Endpoint/MonetaryAccount.php index 0587e034..1e660b78 100644 --- a/src/Model/Generated/Endpoint/MonetaryAccount.php +++ b/src/Model/Generated/Endpoint/MonetaryAccount.php @@ -124,4 +124,16 @@ public function getReferencedObject() throw new BunqException(self::ERROR_NULL_FIELDS); } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->monetaryAccountBank)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/MonetaryAccountBank.php b/src/Model/Generated/Endpoint/MonetaryAccountBank.php index dc732896..6f655b05 100644 --- a/src/Model/Generated/Endpoint/MonetaryAccountBank.php +++ b/src/Model/Generated/Endpoint/MonetaryAccountBank.php @@ -685,4 +685,92 @@ public function setSetting($setting) { $this->setting = $setting; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->id)) { + return false; + } + + if (!is_null($this->created)) { + return false; + } + + if (!is_null($this->updated)) { + return false; + } + + if (!is_null($this->avatar)) { + return false; + } + + if (!is_null($this->currency)) { + return false; + } + + if (!is_null($this->description)) { + return false; + } + + if (!is_null($this->dailyLimit)) { + return false; + } + + if (!is_null($this->dailySpent)) { + return false; + } + + if (!is_null($this->overdraftLimit)) { + return false; + } + + if (!is_null($this->balance)) { + return false; + } + + if (!is_null($this->alias)) { + return false; + } + + if (!is_null($this->publicUuid)) { + return false; + } + + if (!is_null($this->status)) { + return false; + } + + if (!is_null($this->subStatus)) { + return false; + } + + if (!is_null($this->reason)) { + return false; + } + + if (!is_null($this->reasonDescription)) { + return false; + } + + if (!is_null($this->userId)) { + return false; + } + + if (!is_null($this->monetaryAccountProfile)) { + return false; + } + + if (!is_null($this->notificationFilters)) { + return false; + } + + if (!is_null($this->setting)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/MonetaryAccountProfile.php b/src/Model/Generated/Endpoint/MonetaryAccountProfile.php index 624b4039..966d0e92 100644 --- a/src/Model/Generated/Endpoint/MonetaryAccountProfile.php +++ b/src/Model/Generated/Endpoint/MonetaryAccountProfile.php @@ -73,4 +73,20 @@ public function setProfileDrain($profileDrain) { $this->profileDrain = $profileDrain; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->profileFill)) { + return false; + } + + if (!is_null($this->profileDrain)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/Payment.php b/src/Model/Generated/Endpoint/Payment.php index 6a657b71..346406eb 100644 --- a/src/Model/Generated/Endpoint/Payment.php +++ b/src/Model/Generated/Endpoint/Payment.php @@ -728,4 +728,104 @@ public function setAllowChat($allowChat) { $this->allowChat = $allowChat; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->id)) { + return false; + } + + if (!is_null($this->created)) { + return false; + } + + if (!is_null($this->updated)) { + return false; + } + + if (!is_null($this->monetaryAccountId)) { + return false; + } + + if (!is_null($this->amount)) { + return false; + } + + if (!is_null($this->alias)) { + return false; + } + + if (!is_null($this->counterpartyAlias)) { + return false; + } + + if (!is_null($this->description)) { + return false; + } + + if (!is_null($this->type)) { + return false; + } + + if (!is_null($this->subType)) { + return false; + } + + if (!is_null($this->bunqtoStatus)) { + return false; + } + + if (!is_null($this->bunqtoSubStatus)) { + return false; + } + + if (!is_null($this->bunqtoShareUrl)) { + return false; + } + + if (!is_null($this->bunqtoExpiry)) { + return false; + } + + if (!is_null($this->bunqtoTimeResponded)) { + return false; + } + + if (!is_null($this->attachment)) { + return false; + } + + if (!is_null($this->merchantReference)) { + return false; + } + + if (!is_null($this->batchId)) { + return false; + } + + if (!is_null($this->scheduledId)) { + return false; + } + + if (!is_null($this->addressShipping)) { + return false; + } + + if (!is_null($this->addressBilling)) { + return false; + } + + if (!is_null($this->geolocation)) { + return false; + } + + if (!is_null($this->allowChat)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/PaymentBatch.php b/src/Model/Generated/Endpoint/PaymentBatch.php index d93fb4ee..d0d06d30 100644 --- a/src/Model/Generated/Endpoint/PaymentBatch.php +++ b/src/Model/Generated/Endpoint/PaymentBatch.php @@ -175,4 +175,16 @@ public function setPayments($payments) { $this->payments = $payments; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->payments)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/PaymentChat.php b/src/Model/Generated/Endpoint/PaymentChat.php index 378d0e5d..b19025cf 100644 --- a/src/Model/Generated/Endpoint/PaymentChat.php +++ b/src/Model/Generated/Endpoint/PaymentChat.php @@ -220,4 +220,28 @@ public function setUnreadMessageCount($unreadMessageCount) { $this->unreadMessageCount = $unreadMessageCount; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->id)) { + return false; + } + + if (!is_null($this->created)) { + return false; + } + + if (!is_null($this->updated)) { + return false; + } + + if (!is_null($this->unreadMessageCount)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/PermittedIp.php b/src/Model/Generated/Endpoint/PermittedIp.php index f3288067..9028c99f 100644 --- a/src/Model/Generated/Endpoint/PermittedIp.php +++ b/src/Model/Generated/Endpoint/PermittedIp.php @@ -194,4 +194,20 @@ public function setStatus($status) { $this->status = $status; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->ip)) { + return false; + } + + if (!is_null($this->status)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/PromotionDisplay.php b/src/Model/Generated/Endpoint/PromotionDisplay.php index 7efd7ce0..621f5f59 100644 --- a/src/Model/Generated/Endpoint/PromotionDisplay.php +++ b/src/Model/Generated/Endpoint/PromotionDisplay.php @@ -181,4 +181,28 @@ public function setStatus($status) { $this->status = $status; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->id)) { + return false; + } + + if (!is_null($this->counterpartyAlias)) { + return false; + } + + if (!is_null($this->eventDescription)) { + return false; + } + + if (!is_null($this->status)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/RequestInquiry.php b/src/Model/Generated/Endpoint/RequestInquiry.php index 0b614a91..9e8a6358 100644 --- a/src/Model/Generated/Endpoint/RequestInquiry.php +++ b/src/Model/Generated/Endpoint/RequestInquiry.php @@ -808,4 +808,112 @@ public function setAllowChat($allowChat) { $this->allowChat = $allowChat; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->id)) { + return false; + } + + if (!is_null($this->created)) { + return false; + } + + if (!is_null($this->updated)) { + return false; + } + + if (!is_null($this->timeResponded)) { + return false; + } + + if (!is_null($this->timeExpiry)) { + return false; + } + + if (!is_null($this->monetaryAccountId)) { + return false; + } + + if (!is_null($this->amountInquired)) { + return false; + } + + if (!is_null($this->amountResponded)) { + return false; + } + + if (!is_null($this->userAliasCreated)) { + return false; + } + + if (!is_null($this->userAliasRevoked)) { + return false; + } + + if (!is_null($this->counterpartyAlias)) { + return false; + } + + if (!is_null($this->description)) { + return false; + } + + if (!is_null($this->merchantReference)) { + return false; + } + + if (!is_null($this->attachment)) { + return false; + } + + if (!is_null($this->status)) { + return false; + } + + if (!is_null($this->batchId)) { + return false; + } + + if (!is_null($this->scheduledId)) { + return false; + } + + if (!is_null($this->minimumAge)) { + return false; + } + + if (!is_null($this->requireAddress)) { + return false; + } + + if (!is_null($this->bunqmeShareUrl)) { + return false; + } + + if (!is_null($this->redirectUrl)) { + return false; + } + + if (!is_null($this->addressShipping)) { + return false; + } + + if (!is_null($this->addressBilling)) { + return false; + } + + if (!is_null($this->geolocation)) { + return false; + } + + if (!is_null($this->allowChat)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/RequestInquiryBatch.php b/src/Model/Generated/Endpoint/RequestInquiryBatch.php index ed9f109e..da6599d6 100644 --- a/src/Model/Generated/Endpoint/RequestInquiryBatch.php +++ b/src/Model/Generated/Endpoint/RequestInquiryBatch.php @@ -202,4 +202,20 @@ public function setTotalAmountInquired($totalAmountInquired) { $this->totalAmountInquired = $totalAmountInquired; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->requestInquiries)) { + return false; + } + + if (!is_null($this->totalAmountInquired)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/RequestInquiryChat.php b/src/Model/Generated/Endpoint/RequestInquiryChat.php index 6723767e..f08804f4 100644 --- a/src/Model/Generated/Endpoint/RequestInquiryChat.php +++ b/src/Model/Generated/Endpoint/RequestInquiryChat.php @@ -224,4 +224,28 @@ public function setUnreadMessageCount($unreadMessageCount) { $this->unreadMessageCount = $unreadMessageCount; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->id)) { + return false; + } + + if (!is_null($this->created)) { + return false; + } + + if (!is_null($this->updated)) { + return false; + } + + if (!is_null($this->unreadMessageCount)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/RequestResponse.php b/src/Model/Generated/Endpoint/RequestResponse.php index 113f34d9..9ac3555d 100644 --- a/src/Model/Generated/Endpoint/RequestResponse.php +++ b/src/Model/Generated/Endpoint/RequestResponse.php @@ -776,4 +776,112 @@ public function setEligibleWhitelistId($eligibleWhitelistId) { $this->eligibleWhitelistId = $eligibleWhitelistId; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->id)) { + return false; + } + + if (!is_null($this->created)) { + return false; + } + + if (!is_null($this->updated)) { + return false; + } + + if (!is_null($this->timeResponded)) { + return false; + } + + if (!is_null($this->timeExpiry)) { + return false; + } + + if (!is_null($this->monetaryAccountId)) { + return false; + } + + if (!is_null($this->amountInquired)) { + return false; + } + + if (!is_null($this->amountResponded)) { + return false; + } + + if (!is_null($this->status)) { + return false; + } + + if (!is_null($this->description)) { + return false; + } + + if (!is_null($this->alias)) { + return false; + } + + if (!is_null($this->counterpartyAlias)) { + return false; + } + + if (!is_null($this->attachment)) { + return false; + } + + if (!is_null($this->minimumAge)) { + return false; + } + + if (!is_null($this->requireAddress)) { + return false; + } + + if (!is_null($this->geolocation)) { + return false; + } + + if (!is_null($this->type)) { + return false; + } + + if (!is_null($this->subType)) { + return false; + } + + if (!is_null($this->redirectUrl)) { + return false; + } + + if (!is_null($this->addressBilling)) { + return false; + } + + if (!is_null($this->addressShipping)) { + return false; + } + + if (!is_null($this->allowChat)) { + return false; + } + + if (!is_null($this->creditSchemeIdentifier)) { + return false; + } + + if (!is_null($this->mandateIdentifier)) { + return false; + } + + if (!is_null($this->eligibleWhitelistId)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/RequestResponseChat.php b/src/Model/Generated/Endpoint/RequestResponseChat.php index 2e06ca51..1093d9e2 100644 --- a/src/Model/Generated/Endpoint/RequestResponseChat.php +++ b/src/Model/Generated/Endpoint/RequestResponseChat.php @@ -224,4 +224,28 @@ public function setUnreadMessageCount($unreadMessageCount) { $this->unreadMessageCount = $unreadMessageCount; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->id)) { + return false; + } + + if (!is_null($this->created)) { + return false; + } + + if (!is_null($this->updated)) { + return false; + } + + if (!is_null($this->unreadMessageCount)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/Schedule.php b/src/Model/Generated/Endpoint/Schedule.php index 8f213bad..d8c33527 100644 --- a/src/Model/Generated/Endpoint/Schedule.php +++ b/src/Model/Generated/Endpoint/Schedule.php @@ -249,4 +249,36 @@ public function setObject($object) { $this->object = $object; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->timeStart)) { + return false; + } + + if (!is_null($this->timeEnd)) { + return false; + } + + if (!is_null($this->recurrenceUnit)) { + return false; + } + + if (!is_null($this->recurrenceSize)) { + return false; + } + + if (!is_null($this->status)) { + return false; + } + + if (!is_null($this->object)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/ScheduleInstance.php b/src/Model/Generated/Endpoint/ScheduleInstance.php index 2384ba04..ac75af8f 100644 --- a/src/Model/Generated/Endpoint/ScheduleInstance.php +++ b/src/Model/Generated/Endpoint/ScheduleInstance.php @@ -271,4 +271,36 @@ public function setResultObject($resultObject) { $this->resultObject = $resultObject; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->state)) { + return false; + } + + if (!is_null($this->timeStart)) { + return false; + } + + if (!is_null($this->timeEnd)) { + return false; + } + + if (!is_null($this->errorMessage)) { + return false; + } + + if (!is_null($this->scheduledObject)) { + return false; + } + + if (!is_null($this->resultObject)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/SchedulePayment.php b/src/Model/Generated/Endpoint/SchedulePayment.php index 794e42ad..bab958e9 100644 --- a/src/Model/Generated/Endpoint/SchedulePayment.php +++ b/src/Model/Generated/Endpoint/SchedulePayment.php @@ -216,4 +216,20 @@ public function setSchedule($schedule) { $this->schedule = $schedule; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->payment)) { + return false; + } + + if (!is_null($this->schedule)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/SchedulePaymentBatch.php b/src/Model/Generated/Endpoint/SchedulePaymentBatch.php index e5403844..3803a5c2 100644 --- a/src/Model/Generated/Endpoint/SchedulePaymentBatch.php +++ b/src/Model/Generated/Endpoint/SchedulePaymentBatch.php @@ -159,4 +159,20 @@ public function setSchedule($schedule) { $this->schedule = $schedule; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->payments)) { + return false; + } + + if (!is_null($this->schedule)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/ScheduleUser.php b/src/Model/Generated/Endpoint/ScheduleUser.php index 5e57971f..55b45ac1 100644 --- a/src/Model/Generated/Endpoint/ScheduleUser.php +++ b/src/Model/Generated/Endpoint/ScheduleUser.php @@ -57,4 +57,12 @@ public static function listing(ApiContext $apiContext, int $userId, array $param static::fromJsonList($responseRaw, self::OBJECT_TYPE) ); } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + return true; + } } diff --git a/src/Model/Generated/Endpoint/Session.php b/src/Model/Generated/Endpoint/Session.php index 8025a1a4..cbe7f312 100644 --- a/src/Model/Generated/Endpoint/Session.php +++ b/src/Model/Generated/Endpoint/Session.php @@ -47,4 +47,12 @@ public static function delete(ApiContext $apiContext, int $sessionId, array $cus new BunqResponse(null, $responseRaw->getHeaders()) ); } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + return true; + } } diff --git a/src/Model/Generated/Endpoint/ShareInviteBankAmountUsed.php b/src/Model/Generated/Endpoint/ShareInviteBankAmountUsed.php index f077d90b..afcecaee 100644 --- a/src/Model/Generated/Endpoint/ShareInviteBankAmountUsed.php +++ b/src/Model/Generated/Endpoint/ShareInviteBankAmountUsed.php @@ -55,4 +55,12 @@ public static function delete(ApiContext $apiContext, int $userId, int $monetary new BunqResponse(null, $responseRaw->getHeaders()) ); } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + return true; + } } diff --git a/src/Model/Generated/Endpoint/ShareInviteBankInquiry.php b/src/Model/Generated/Endpoint/ShareInviteBankInquiry.php index e92c7002..993028f7 100644 --- a/src/Model/Generated/Endpoint/ShareInviteBankInquiry.php +++ b/src/Model/Generated/Endpoint/ShareInviteBankInquiry.php @@ -468,4 +468,60 @@ public function setId($id) { $this->id = $id; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->alias)) { + return false; + } + + if (!is_null($this->userAliasCreated)) { + return false; + } + + if (!is_null($this->userAliasRevoked)) { + return false; + } + + if (!is_null($this->counterUserAlias)) { + return false; + } + + if (!is_null($this->monetaryAccountId)) { + return false; + } + + if (!is_null($this->draftShareInviteBankId)) { + return false; + } + + if (!is_null($this->shareDetail)) { + return false; + } + + if (!is_null($this->status)) { + return false; + } + + if (!is_null($this->shareType)) { + return false; + } + + if (!is_null($this->startDate)) { + return false; + } + + if (!is_null($this->endDate)) { + return false; + } + + if (!is_null($this->id)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/ShareInviteBankResponse.php b/src/Model/Generated/Endpoint/ShareInviteBankResponse.php index 64be6cb6..09354ded 100644 --- a/src/Model/Generated/Endpoint/ShareInviteBankResponse.php +++ b/src/Model/Generated/Endpoint/ShareInviteBankResponse.php @@ -379,4 +379,52 @@ public function setDescription($description) { $this->description = $description; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->counterAlias)) { + return false; + } + + if (!is_null($this->userAliasCancelled)) { + return false; + } + + if (!is_null($this->monetaryAccountId)) { + return false; + } + + if (!is_null($this->draftShareInviteBankId)) { + return false; + } + + if (!is_null($this->shareDetail)) { + return false; + } + + if (!is_null($this->status)) { + return false; + } + + if (!is_null($this->shareType)) { + return false; + } + + if (!is_null($this->startDate)) { + return false; + } + + if (!is_null($this->endDate)) { + return false; + } + + if (!is_null($this->description)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/Tab.php b/src/Model/Generated/Endpoint/Tab.php index c890c247..a102820f 100644 --- a/src/Model/Generated/Endpoint/Tab.php +++ b/src/Model/Generated/Endpoint/Tab.php @@ -155,4 +155,20 @@ public function getReferencedObject() throw new BunqException(self::ERROR_NULL_FIELDS); } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->tabUsageSingle)) { + return false; + } + + if (!is_null($this->tabUsageMultiple)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/TabAttachmentTab.php b/src/Model/Generated/Endpoint/TabAttachmentTab.php index ec01af97..2d9acb38 100644 --- a/src/Model/Generated/Endpoint/TabAttachmentTab.php +++ b/src/Model/Generated/Endpoint/TabAttachmentTab.php @@ -151,4 +151,28 @@ public function setAttachment($attachment) { $this->attachment = $attachment; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->id)) { + return false; + } + + if (!is_null($this->created)) { + return false; + } + + if (!is_null($this->updated)) { + return false; + } + + if (!is_null($this->attachment)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/TabAttachmentTabContent.php b/src/Model/Generated/Endpoint/TabAttachmentTabContent.php index 5252bd5d..8c8d82a7 100644 --- a/src/Model/Generated/Endpoint/TabAttachmentTabContent.php +++ b/src/Model/Generated/Endpoint/TabAttachmentTabContent.php @@ -53,4 +53,12 @@ public static function listing(ApiContext $apiContext, string $tabUuid, int $att new BunqResponse($responseRaw->getBodyString(), $responseRaw->getHeaders()) ); } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + return true; + } } diff --git a/src/Model/Generated/Endpoint/TabItem.php b/src/Model/Generated/Endpoint/TabItem.php index e2bec03f..bd5a7304 100644 --- a/src/Model/Generated/Endpoint/TabItem.php +++ b/src/Model/Generated/Endpoint/TabItem.php @@ -196,4 +196,40 @@ public function setAmount($amount) { $this->amount = $amount; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->id)) { + return false; + } + + if (!is_null($this->description)) { + return false; + } + + if (!is_null($this->eanCode)) { + return false; + } + + if (!is_null($this->avatarAttachment)) { + return false; + } + + if (!is_null($this->tabAttachment)) { + return false; + } + + if (!is_null($this->quantity)) { + return false; + } + + if (!is_null($this->amount)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/TabItemShop.php b/src/Model/Generated/Endpoint/TabItemShop.php index 0d124c47..deb14aac 100644 --- a/src/Model/Generated/Endpoint/TabItemShop.php +++ b/src/Model/Generated/Endpoint/TabItemShop.php @@ -376,4 +376,40 @@ public function setAmount($amount) { $this->amount = $amount; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->id)) { + return false; + } + + if (!is_null($this->description)) { + return false; + } + + if (!is_null($this->eanCode)) { + return false; + } + + if (!is_null($this->avatarAttachment)) { + return false; + } + + if (!is_null($this->tabAttachment)) { + return false; + } + + if (!is_null($this->quantity)) { + return false; + } + + if (!is_null($this->amount)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/TabItemShopBatch.php b/src/Model/Generated/Endpoint/TabItemShopBatch.php index b8e1ed7f..9f353b42 100644 --- a/src/Model/Generated/Endpoint/TabItemShopBatch.php +++ b/src/Model/Generated/Endpoint/TabItemShopBatch.php @@ -82,4 +82,16 @@ public function setTabItems($tabItems) { $this->tabItems = $tabItems; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->tabItems)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/TabQrCodeContent.php b/src/Model/Generated/Endpoint/TabQrCodeContent.php index 824186c8..1bf99b8d 100644 --- a/src/Model/Generated/Endpoint/TabQrCodeContent.php +++ b/src/Model/Generated/Endpoint/TabQrCodeContent.php @@ -58,4 +58,12 @@ public static function listing(ApiContext $apiContext, int $userId, int $monetar new BunqResponse($responseRaw->getBodyString(), $responseRaw->getHeaders()) ); } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + return true; + } } diff --git a/src/Model/Generated/Endpoint/TabResultInquiry.php b/src/Model/Generated/Endpoint/TabResultInquiry.php index b0189f8e..4aca154e 100644 --- a/src/Model/Generated/Endpoint/TabResultInquiry.php +++ b/src/Model/Generated/Endpoint/TabResultInquiry.php @@ -138,4 +138,20 @@ public function setPayment($payment) { $this->payment = $payment; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->tab)) { + return false; + } + + if (!is_null($this->payment)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/TabResultResponse.php b/src/Model/Generated/Endpoint/TabResultResponse.php index b134ab33..f7bd0ab9 100644 --- a/src/Model/Generated/Endpoint/TabResultResponse.php +++ b/src/Model/Generated/Endpoint/TabResultResponse.php @@ -134,4 +134,20 @@ public function setPayment($payment) { $this->payment = $payment; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->tab)) { + return false; + } + + if (!is_null($this->payment)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/TabUsageMultiple.php b/src/Model/Generated/Endpoint/TabUsageMultiple.php index 963b7a55..2131ee06 100644 --- a/src/Model/Generated/Endpoint/TabUsageMultiple.php +++ b/src/Model/Generated/Endpoint/TabUsageMultiple.php @@ -644,4 +644,80 @@ public function setTabAttachment($tabAttachment) { $this->tabAttachment = $tabAttachment; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->uuid)) { + return false; + } + + if (!is_null($this->created)) { + return false; + } + + if (!is_null($this->updated)) { + return false; + } + + if (!is_null($this->description)) { + return false; + } + + if (!is_null($this->status)) { + return false; + } + + if (!is_null($this->amountTotal)) { + return false; + } + + if (!is_null($this->qrCodeToken)) { + return false; + } + + if (!is_null($this->tabUrl)) { + return false; + } + + if (!is_null($this->visibility)) { + return false; + } + + if (!is_null($this->minimumAge)) { + return false; + } + + if (!is_null($this->requireAddress)) { + return false; + } + + if (!is_null($this->redirectUrl)) { + return false; + } + + if (!is_null($this->expiration)) { + return false; + } + + if (!is_null($this->alias)) { + return false; + } + + if (!is_null($this->cashRegisterLocation)) { + return false; + } + + if (!is_null($this->tabItem)) { + return false; + } + + if (!is_null($this->tabAttachment)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/TabUsageSingle.php b/src/Model/Generated/Endpoint/TabUsageSingle.php index b9de3deb..e66138db 100644 --- a/src/Model/Generated/Endpoint/TabUsageSingle.php +++ b/src/Model/Generated/Endpoint/TabUsageSingle.php @@ -694,4 +694,88 @@ public function setTabAttachment($tabAttachment) { $this->tabAttachment = $tabAttachment; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->uuid)) { + return false; + } + + if (!is_null($this->created)) { + return false; + } + + if (!is_null($this->updated)) { + return false; + } + + if (!is_null($this->merchantReference)) { + return false; + } + + if (!is_null($this->description)) { + return false; + } + + if (!is_null($this->status)) { + return false; + } + + if (!is_null($this->amountTotal)) { + return false; + } + + if (!is_null($this->amountPaid)) { + return false; + } + + if (!is_null($this->qrCodeToken)) { + return false; + } + + if (!is_null($this->tabUrl)) { + return false; + } + + if (!is_null($this->visibility)) { + return false; + } + + if (!is_null($this->minimumAge)) { + return false; + } + + if (!is_null($this->requireAddress)) { + return false; + } + + if (!is_null($this->redirectUrl)) { + return false; + } + + if (!is_null($this->expiration)) { + return false; + } + + if (!is_null($this->alias)) { + return false; + } + + if (!is_null($this->cashRegisterLocation)) { + return false; + } + + if (!is_null($this->tabItem)) { + return false; + } + + if (!is_null($this->tabAttachment)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/TokenQrRequestIdeal.php b/src/Model/Generated/Endpoint/TokenQrRequestIdeal.php index def7294e..6273a31c 100644 --- a/src/Model/Generated/Endpoint/TokenQrRequestIdeal.php +++ b/src/Model/Generated/Endpoint/TokenQrRequestIdeal.php @@ -576,4 +576,92 @@ public function setEligibleWhitelistId($eligibleWhitelistId) { $this->eligibleWhitelistId = $eligibleWhitelistId; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->timeResponded)) { + return false; + } + + if (!is_null($this->timeExpiry)) { + return false; + } + + if (!is_null($this->monetaryAccountId)) { + return false; + } + + if (!is_null($this->amountInquired)) { + return false; + } + + if (!is_null($this->amountResponded)) { + return false; + } + + if (!is_null($this->alias)) { + return false; + } + + if (!is_null($this->counterpartyAlias)) { + return false; + } + + if (!is_null($this->description)) { + return false; + } + + if (!is_null($this->attachment)) { + return false; + } + + if (!is_null($this->status)) { + return false; + } + + if (!is_null($this->minimumAge)) { + return false; + } + + if (!is_null($this->requireAddress)) { + return false; + } + + if (!is_null($this->addressShipping)) { + return false; + } + + if (!is_null($this->addressBilling)) { + return false; + } + + if (!is_null($this->geolocation)) { + return false; + } + + if (!is_null($this->redirectUrl)) { + return false; + } + + if (!is_null($this->type)) { + return false; + } + + if (!is_null($this->subType)) { + return false; + } + + if (!is_null($this->allowChat)) { + return false; + } + + if (!is_null($this->eligibleWhitelistId)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/User.php b/src/Model/Generated/Endpoint/User.php index b2d5ac61..25e9e0e0 100644 --- a/src/Model/Generated/Endpoint/User.php +++ b/src/Model/Generated/Endpoint/User.php @@ -169,4 +169,24 @@ public function getReferencedObject() throw new BunqException(self::ERROR_NULL_FIELDS); } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->userLight)) { + return false; + } + + if (!is_null($this->userPerson)) { + return false; + } + + if (!is_null($this->userCompany)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/UserCompany.php b/src/Model/Generated/Endpoint/UserCompany.php index f6dda727..8f62a196 100644 --- a/src/Model/Generated/Endpoint/UserCompany.php +++ b/src/Model/Generated/Endpoint/UserCompany.php @@ -845,4 +845,128 @@ public function setBillingContract($billingContract) { $this->billingContract = $billingContract; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->id)) { + return false; + } + + if (!is_null($this->created)) { + return false; + } + + if (!is_null($this->updated)) { + return false; + } + + if (!is_null($this->publicUuid)) { + return false; + } + + if (!is_null($this->name)) { + return false; + } + + if (!is_null($this->displayName)) { + return false; + } + + if (!is_null($this->publicNickName)) { + return false; + } + + if (!is_null($this->alias)) { + return false; + } + + if (!is_null($this->chamberOfCommerceNumber)) { + return false; + } + + if (!is_null($this->typeOfBusinessEntity)) { + return false; + } + + if (!is_null($this->sectorOfIndustry)) { + return false; + } + + if (!is_null($this->counterBankIban)) { + return false; + } + + if (!is_null($this->avatar)) { + return false; + } + + if (!is_null($this->addressMain)) { + return false; + } + + if (!is_null($this->addressPostal)) { + return false; + } + + if (!is_null($this->versionTermsOfService)) { + return false; + } + + if (!is_null($this->directorAlias)) { + return false; + } + + if (!is_null($this->language)) { + return false; + } + + if (!is_null($this->country)) { + return false; + } + + if (!is_null($this->region)) { + return false; + } + + if (!is_null($this->ubo)) { + return false; + } + + if (!is_null($this->status)) { + return false; + } + + if (!is_null($this->subStatus)) { + return false; + } + + if (!is_null($this->sessionTimeout)) { + return false; + } + + if (!is_null($this->dailyLimitWithoutConfirmationLogin)) { + return false; + } + + if (!is_null($this->notificationFilters)) { + return false; + } + + if (!is_null($this->customer)) { + return false; + } + + if (!is_null($this->customerLimit)) { + return false; + } + + if (!is_null($this->billingContract)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/UserCredentialPasswordIp.php b/src/Model/Generated/Endpoint/UserCredentialPasswordIp.php index 3f002fc3..c5b1f049 100644 --- a/src/Model/Generated/Endpoint/UserCredentialPasswordIp.php +++ b/src/Model/Generated/Endpoint/UserCredentialPasswordIp.php @@ -255,4 +255,40 @@ public function setPermittedDevice($permittedDevice) { $this->permittedDevice = $permittedDevice; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->id)) { + return false; + } + + if (!is_null($this->created)) { + return false; + } + + if (!is_null($this->updated)) { + return false; + } + + if (!is_null($this->status)) { + return false; + } + + if (!is_null($this->expiryTime)) { + return false; + } + + if (!is_null($this->tokenValue)) { + return false; + } + + if (!is_null($this->permittedDevice)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/UserLight.php b/src/Model/Generated/Endpoint/UserLight.php index 6fad6844..56e9f08d 100644 --- a/src/Model/Generated/Endpoint/UserLight.php +++ b/src/Model/Generated/Endpoint/UserLight.php @@ -902,4 +902,140 @@ public function setNotificationFilters($notificationFilters) { $this->notificationFilters = $notificationFilters; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->id)) { + return false; + } + + if (!is_null($this->created)) { + return false; + } + + if (!is_null($this->updated)) { + return false; + } + + if (!is_null($this->publicUuid)) { + return false; + } + + if (!is_null($this->firstName)) { + return false; + } + + if (!is_null($this->middleName)) { + return false; + } + + if (!is_null($this->lastName)) { + return false; + } + + if (!is_null($this->legalName)) { + return false; + } + + if (!is_null($this->displayName)) { + return false; + } + + if (!is_null($this->publicNickName)) { + return false; + } + + if (!is_null($this->alias)) { + return false; + } + + if (!is_null($this->socialSecurityNumber)) { + return false; + } + + if (!is_null($this->taxResident)) { + return false; + } + + if (!is_null($this->documentType)) { + return false; + } + + if (!is_null($this->documentNumber)) { + return false; + } + + if (!is_null($this->documentCountryOfIssuance)) { + return false; + } + + if (!is_null($this->addressMain)) { + return false; + } + + if (!is_null($this->addressPostal)) { + return false; + } + + if (!is_null($this->dateOfBirth)) { + return false; + } + + if (!is_null($this->placeOfBirth)) { + return false; + } + + if (!is_null($this->countryOfBirth)) { + return false; + } + + if (!is_null($this->nationality)) { + return false; + } + + if (!is_null($this->language)) { + return false; + } + + if (!is_null($this->region)) { + return false; + } + + if (!is_null($this->gender)) { + return false; + } + + if (!is_null($this->avatar)) { + return false; + } + + if (!is_null($this->versionTermsOfService)) { + return false; + } + + if (!is_null($this->status)) { + return false; + } + + if (!is_null($this->subStatus)) { + return false; + } + + if (!is_null($this->sessionTimeout)) { + return false; + } + + if (!is_null($this->dailyLimitWithoutConfirmationLogin)) { + return false; + } + + if (!is_null($this->notificationFilters)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Endpoint/UserPerson.php b/src/Model/Generated/Endpoint/UserPerson.php index f3d7ef03..5a7773e2 100644 --- a/src/Model/Generated/Endpoint/UserPerson.php +++ b/src/Model/Generated/Endpoint/UserPerson.php @@ -909,4 +909,136 @@ public function setNotificationFilters($notificationFilters) { $this->notificationFilters = $notificationFilters; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->id)) { + return false; + } + + if (!is_null($this->created)) { + return false; + } + + if (!is_null($this->updated)) { + return false; + } + + if (!is_null($this->publicUuid)) { + return false; + } + + if (!is_null($this->firstName)) { + return false; + } + + if (!is_null($this->middleName)) { + return false; + } + + if (!is_null($this->lastName)) { + return false; + } + + if (!is_null($this->legalName)) { + return false; + } + + if (!is_null($this->displayName)) { + return false; + } + + if (!is_null($this->publicNickName)) { + return false; + } + + if (!is_null($this->alias)) { + return false; + } + + if (!is_null($this->taxResident)) { + return false; + } + + if (!is_null($this->documentType)) { + return false; + } + + if (!is_null($this->documentNumber)) { + return false; + } + + if (!is_null($this->documentCountryOfIssuance)) { + return false; + } + + if (!is_null($this->addressMain)) { + return false; + } + + if (!is_null($this->addressPostal)) { + return false; + } + + if (!is_null($this->dateOfBirth)) { + return false; + } + + if (!is_null($this->placeOfBirth)) { + return false; + } + + if (!is_null($this->countryOfBirth)) { + return false; + } + + if (!is_null($this->nationality)) { + return false; + } + + if (!is_null($this->language)) { + return false; + } + + if (!is_null($this->region)) { + return false; + } + + if (!is_null($this->gender)) { + return false; + } + + if (!is_null($this->avatar)) { + return false; + } + + if (!is_null($this->versionTermsOfService)) { + return false; + } + + if (!is_null($this->status)) { + return false; + } + + if (!is_null($this->subStatus)) { + return false; + } + + if (!is_null($this->sessionTimeout)) { + return false; + } + + if (!is_null($this->dailyLimitWithoutConfirmationLogin)) { + return false; + } + + if (!is_null($this->notificationFilters)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Object/Address.php b/src/Model/Generated/Object/Address.php index 7a6d6197..ec9a3c99 100644 --- a/src/Model/Generated/Object/Address.php +++ b/src/Model/Generated/Object/Address.php @@ -198,4 +198,40 @@ public function setProvince($province) { $this->province = $province; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->street)) { + return false; + } + + if (!is_null($this->houseNumber)) { + return false; + } + + if (!is_null($this->poBox)) { + return false; + } + + if (!is_null($this->postalCode)) { + return false; + } + + if (!is_null($this->city)) { + return false; + } + + if (!is_null($this->country)) { + return false; + } + + if (!is_null($this->province)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Object/Amount.php b/src/Model/Generated/Object/Amount.php index f698f5b2..3e371386 100644 --- a/src/Model/Generated/Object/Amount.php +++ b/src/Model/Generated/Object/Amount.php @@ -67,4 +67,20 @@ public function setCurrency($currency) { $this->currency = $currency; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->value)) { + return false; + } + + if (!is_null($this->currency)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Object/AnchoredObject.php b/src/Model/Generated/Object/AnchoredObject.php index 86cac134..7e50063f 100644 --- a/src/Model/Generated/Object/AnchoredObject.php +++ b/src/Model/Generated/Object/AnchoredObject.php @@ -490,4 +490,84 @@ public function getReferencedObject() throw new BunqException(self::ERROR_NULL_FIELDS); } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->cardDebit)) { + return false; + } + + if (!is_null($this->cardPinChange)) { + return false; + } + + if (!is_null($this->cardResult)) { + return false; + } + + if (!is_null($this->draftPayment)) { + return false; + } + + if (!is_null($this->idealMerchantTransaction)) { + return false; + } + + if (!is_null($this->invoice)) { + return false; + } + + if (!is_null($this->payment)) { + return false; + } + + if (!is_null($this->paymentBatch)) { + return false; + } + + if (!is_null($this->promotionDisplay)) { + return false; + } + + if (!is_null($this->requestInquiryBatch)) { + return false; + } + + if (!is_null($this->requestInquiry)) { + return false; + } + + if (!is_null($this->requestResponse)) { + return false; + } + + if (!is_null($this->scheduledPaymentBatch)) { + return false; + } + + if (!is_null($this->scheduledPayment)) { + return false; + } + + if (!is_null($this->scheduledInstance)) { + return false; + } + + if (!is_null($this->shareInviteBankInquiry)) { + return false; + } + + if (!is_null($this->shareInviteBankResponse)) { + return false; + } + + if (!is_null($this->userCredentialPasswordIp)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Object/Attachment.php b/src/Model/Generated/Object/Attachment.php index 35be5570..80571111 100644 --- a/src/Model/Generated/Object/Attachment.php +++ b/src/Model/Generated/Object/Attachment.php @@ -57,4 +57,20 @@ public function setContentType($contentType) { $this->contentType = $contentType; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->description)) { + return false; + } + + if (!is_null($this->contentType)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Object/AttachmentMonetaryAccountPayment.php b/src/Model/Generated/Object/AttachmentMonetaryAccountPayment.php index 691fe3da..34c28589 100644 --- a/src/Model/Generated/Object/AttachmentMonetaryAccountPayment.php +++ b/src/Model/Generated/Object/AttachmentMonetaryAccountPayment.php @@ -65,4 +65,20 @@ public function setMonetaryAccountId($monetaryAccountId) { $this->monetaryAccountId = $monetaryAccountId; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->id)) { + return false; + } + + if (!is_null($this->monetaryAccountId)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Object/AttachmentPublic.php b/src/Model/Generated/Object/AttachmentPublic.php index c037d283..f712dc78 100644 --- a/src/Model/Generated/Object/AttachmentPublic.php +++ b/src/Model/Generated/Object/AttachmentPublic.php @@ -82,4 +82,24 @@ public function setContentType($contentType) { $this->contentType = $contentType; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->uuid)) { + return false; + } + + if (!is_null($this->description)) { + return false; + } + + if (!is_null($this->contentType)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Object/AttachmentTab.php b/src/Model/Generated/Object/AttachmentTab.php index cd685600..b6f99432 100644 --- a/src/Model/Generated/Object/AttachmentTab.php +++ b/src/Model/Generated/Object/AttachmentTab.php @@ -82,4 +82,24 @@ public function setContentType($contentType) { $this->contentType = $contentType; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->id)) { + return false; + } + + if (!is_null($this->description)) { + return false; + } + + if (!is_null($this->contentType)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Object/Avatar.php b/src/Model/Generated/Object/Avatar.php index 6f5c9bc5..d5256df1 100644 --- a/src/Model/Generated/Object/Avatar.php +++ b/src/Model/Generated/Object/Avatar.php @@ -90,4 +90,24 @@ public function setImage($image) { $this->image = $image; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->uuid)) { + return false; + } + + if (!is_null($this->anchorUuid)) { + return false; + } + + if (!is_null($this->image)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Object/BudgetRestriction.php b/src/Model/Generated/Object/BudgetRestriction.php index f2475813..d79c1711 100644 --- a/src/Model/Generated/Object/BudgetRestriction.php +++ b/src/Model/Generated/Object/BudgetRestriction.php @@ -59,4 +59,20 @@ public function setFrequency($frequency) { $this->frequency = $frequency; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->amount)) { + return false; + } + + if (!is_null($this->frequency)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Object/BunqId.php b/src/Model/Generated/Object/BunqId.php index f3051b51..030b2374 100644 --- a/src/Model/Generated/Object/BunqId.php +++ b/src/Model/Generated/Object/BunqId.php @@ -40,4 +40,16 @@ public function setId($id) { $this->id = $id; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->id)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Object/BunqMeMerchantAvailable.php b/src/Model/Generated/Object/BunqMeMerchantAvailable.php index e02da794..32f0d714 100644 --- a/src/Model/Generated/Object/BunqMeMerchantAvailable.php +++ b/src/Model/Generated/Object/BunqMeMerchantAvailable.php @@ -57,4 +57,20 @@ public function setAvailable($available) { $this->available = $available; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->merchantType)) { + return false; + } + + if (!is_null($this->available)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Object/CardCountryPermission.php b/src/Model/Generated/Object/CardCountryPermission.php index de24dc85..b9ce7284 100644 --- a/src/Model/Generated/Object/CardCountryPermission.php +++ b/src/Model/Generated/Object/CardCountryPermission.php @@ -90,4 +90,24 @@ public function setExpiryTime($expiryTime) { $this->expiryTime = $expiryTime; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->id)) { + return false; + } + + if (!is_null($this->country)) { + return false; + } + + if (!is_null($this->expiryTime)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Object/CardLimit.php b/src/Model/Generated/Object/CardLimit.php index e513468e..40eb92d7 100644 --- a/src/Model/Generated/Object/CardLimit.php +++ b/src/Model/Generated/Object/CardLimit.php @@ -121,4 +121,28 @@ public function setType($type) { $this->type = $type; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->id)) { + return false; + } + + if (!is_null($this->dailyLimit)) { + return false; + } + + if (!is_null($this->currency)) { + return false; + } + + if (!is_null($this->type)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Object/CardMagStripePermission.php b/src/Model/Generated/Object/CardMagStripePermission.php index 71230a01..7c24f91f 100644 --- a/src/Model/Generated/Object/CardMagStripePermission.php +++ b/src/Model/Generated/Object/CardMagStripePermission.php @@ -32,4 +32,16 @@ public function setExpiryTime($expiryTime) { $this->expiryTime = $expiryTime; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->expiryTime)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Object/CardPinAssignment.php b/src/Model/Generated/Object/CardPinAssignment.php index f0010a10..9ae735b7 100644 --- a/src/Model/Generated/Object/CardPinAssignment.php +++ b/src/Model/Generated/Object/CardPinAssignment.php @@ -72,4 +72,20 @@ public function setMonetaryAccountId($monetaryAccountId) { $this->monetaryAccountId = $monetaryAccountId; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->type)) { + return false; + } + + if (!is_null($this->monetaryAccountId)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Object/Certificate.php b/src/Model/Generated/Object/Certificate.php index 190bca18..2e58f07f 100644 --- a/src/Model/Generated/Object/Certificate.php +++ b/src/Model/Generated/Object/Certificate.php @@ -40,4 +40,16 @@ public function setCertificate($certificate) { $this->certificate = $certificate; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->certificate)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Object/ChatMessageContent.php b/src/Model/Generated/Object/ChatMessageContent.php index 7108b651..b3fdf16c 100644 --- a/src/Model/Generated/Object/ChatMessageContent.php +++ b/src/Model/Generated/Object/ChatMessageContent.php @@ -200,4 +200,40 @@ public function getReferencedObject() throw new BunqException(self::ERROR_NULL_FIELDS); } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->chatMessageContentAnchorEvent)) { + return false; + } + + if (!is_null($this->chatMessageContentAttachment)) { + return false; + } + + if (!is_null($this->chatMessageContentGeolocation)) { + return false; + } + + if (!is_null($this->chatMessageContentStatusConversationTitle)) { + return false; + } + + if (!is_null($this->chatMessageContentStatusConversation)) { + return false; + } + + if (!is_null($this->chatMessageContentStatusMembership)) { + return false; + } + + if (!is_null($this->chatMessageContentText)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Object/ChatMessageContentAnchorEvent.php b/src/Model/Generated/Object/ChatMessageContentAnchorEvent.php index 824d660b..7264ae4c 100644 --- a/src/Model/Generated/Object/ChatMessageContentAnchorEvent.php +++ b/src/Model/Generated/Object/ChatMessageContentAnchorEvent.php @@ -42,4 +42,16 @@ public function setAnchoredObject($anchoredObject) { $this->anchoredObject = $anchoredObject; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->anchoredObject)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Object/ChatMessageContentAttachment.php b/src/Model/Generated/Object/ChatMessageContentAttachment.php index 86884bbd..3dcc6eb9 100644 --- a/src/Model/Generated/Object/ChatMessageContentAttachment.php +++ b/src/Model/Generated/Object/ChatMessageContentAttachment.php @@ -32,4 +32,16 @@ public function setAttachment($attachment) { $this->attachment = $attachment; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->attachment)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Object/ChatMessageContentGeolocation.php b/src/Model/Generated/Object/ChatMessageContentGeolocation.php index 43ae6088..a0245234 100644 --- a/src/Model/Generated/Object/ChatMessageContentGeolocation.php +++ b/src/Model/Generated/Object/ChatMessageContentGeolocation.php @@ -32,4 +32,16 @@ public function setGeolocation($geolocation) { $this->geolocation = $geolocation; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->geolocation)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Object/ChatMessageContentStatusConversation.php b/src/Model/Generated/Object/ChatMessageContentStatusConversation.php index 3ba3e96e..9654f8d2 100644 --- a/src/Model/Generated/Object/ChatMessageContentStatusConversation.php +++ b/src/Model/Generated/Object/ChatMessageContentStatusConversation.php @@ -32,4 +32,16 @@ public function setAction($action) { $this->action = $action; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->action)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Object/ChatMessageContentStatusConversationTitle.php b/src/Model/Generated/Object/ChatMessageContentStatusConversationTitle.php index a124407f..83eed39c 100644 --- a/src/Model/Generated/Object/ChatMessageContentStatusConversationTitle.php +++ b/src/Model/Generated/Object/ChatMessageContentStatusConversationTitle.php @@ -32,4 +32,16 @@ public function setTitle($title) { $this->title = $title; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->title)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Object/ChatMessageContentStatusMembership.php b/src/Model/Generated/Object/ChatMessageContentStatusMembership.php index d4519c74..a3147e10 100644 --- a/src/Model/Generated/Object/ChatMessageContentStatusMembership.php +++ b/src/Model/Generated/Object/ChatMessageContentStatusMembership.php @@ -59,4 +59,20 @@ public function setMember($member) { $this->member = $member; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->action)) { + return false; + } + + if (!is_null($this->member)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Object/ChatMessageContentText.php b/src/Model/Generated/Object/ChatMessageContentText.php index 4128ee4c..9c3473e4 100644 --- a/src/Model/Generated/Object/ChatMessageContentText.php +++ b/src/Model/Generated/Object/ChatMessageContentText.php @@ -32,4 +32,16 @@ public function setText($text) { $this->text = $text; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->text)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Object/DraftPaymentAnchorObject.php b/src/Model/Generated/Object/DraftPaymentAnchorObject.php index 8a7b3bbd..d0c19eca 100644 --- a/src/Model/Generated/Object/DraftPaymentAnchorObject.php +++ b/src/Model/Generated/Object/DraftPaymentAnchorObject.php @@ -74,4 +74,20 @@ public function getReferencedObject() throw new BunqException(self::ERROR_NULL_FIELDS); } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->payment)) { + return false; + } + + if (!is_null($this->paymentBatch)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Object/DraftPaymentEntry.php b/src/Model/Generated/Object/DraftPaymentEntry.php index 97b1c812..200d809f 100644 --- a/src/Model/Generated/Object/DraftPaymentEntry.php +++ b/src/Model/Generated/Object/DraftPaymentEntry.php @@ -234,4 +234,44 @@ public function setAttachment($attachment) { $this->attachment = $attachment; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->id)) { + return false; + } + + if (!is_null($this->amount)) { + return false; + } + + if (!is_null($this->alias)) { + return false; + } + + if (!is_null($this->counterpartyAlias)) { + return false; + } + + if (!is_null($this->description)) { + return false; + } + + if (!is_null($this->merchantReference)) { + return false; + } + + if (!is_null($this->type)) { + return false; + } + + if (!is_null($this->attachment)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Object/DraftPaymentResponse.php b/src/Model/Generated/Object/DraftPaymentResponse.php index a648d0f3..382a91eb 100644 --- a/src/Model/Generated/Object/DraftPaymentResponse.php +++ b/src/Model/Generated/Object/DraftPaymentResponse.php @@ -57,4 +57,20 @@ public function setUserAliasCreated($userAliasCreated) { $this->userAliasCreated = $userAliasCreated; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->status)) { + return false; + } + + if (!is_null($this->userAliasCreated)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Object/DraftShareInviteBankEntry.php b/src/Model/Generated/Object/DraftShareInviteBankEntry.php index 80d0bc66..4e2fd54a 100644 --- a/src/Model/Generated/Object/DraftShareInviteBankEntry.php +++ b/src/Model/Generated/Object/DraftShareInviteBankEntry.php @@ -90,4 +90,24 @@ public function setEndDate($endDate) { $this->endDate = $endDate; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->shareDetail)) { + return false; + } + + if (!is_null($this->startDate)) { + return false; + } + + if (!is_null($this->endDate)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Object/Error.php b/src/Model/Generated/Object/Error.php index d494edff..561f518f 100644 --- a/src/Model/Generated/Object/Error.php +++ b/src/Model/Generated/Object/Error.php @@ -57,4 +57,20 @@ public function setErrorDescriptionTranslated($errorDescriptionTranslated) { $this->errorDescriptionTranslated = $errorDescriptionTranslated; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->errorDescription)) { + return false; + } + + if (!is_null($this->errorDescriptionTranslated)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Object/Geolocation.php b/src/Model/Generated/Object/Geolocation.php index 571c9b24..87549b46 100644 --- a/src/Model/Generated/Object/Geolocation.php +++ b/src/Model/Generated/Object/Geolocation.php @@ -107,4 +107,28 @@ public function setRadius($radius) { $this->radius = $radius; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->latitude)) { + return false; + } + + if (!is_null($this->longitude)) { + return false; + } + + if (!is_null($this->altitude)) { + return false; + } + + if (!is_null($this->radius)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Object/Image.php b/src/Model/Generated/Object/Image.php index 65eb0c87..40b2e75d 100644 --- a/src/Model/Generated/Object/Image.php +++ b/src/Model/Generated/Object/Image.php @@ -107,4 +107,28 @@ public function setWidth($width) { $this->width = $width; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->attachmentPublicUuid)) { + return false; + } + + if (!is_null($this->contentType)) { + return false; + } + + if (!is_null($this->height)) { + return false; + } + + if (!is_null($this->width)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Object/InvoiceItem.php b/src/Model/Generated/Object/InvoiceItem.php index 75d23ae4..668a9d76 100644 --- a/src/Model/Generated/Object/InvoiceItem.php +++ b/src/Model/Generated/Object/InvoiceItem.php @@ -232,4 +232,48 @@ public function setTotalVatInclusive($totalVatInclusive) { $this->totalVatInclusive = $totalVatInclusive; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->billingDate)) { + return false; + } + + if (!is_null($this->typeDescription)) { + return false; + } + + if (!is_null($this->typeDescriptionTranslated)) { + return false; + } + + if (!is_null($this->unitVatExclusive)) { + return false; + } + + if (!is_null($this->unitVatInclusive)) { + return false; + } + + if (!is_null($this->vat)) { + return false; + } + + if (!is_null($this->quantity)) { + return false; + } + + if (!is_null($this->totalVatExclusive)) { + return false; + } + + if (!is_null($this->totalVatInclusive)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Object/InvoiceItemGroup.php b/src/Model/Generated/Object/InvoiceItemGroup.php index 68a0cd71..9f51a678 100644 --- a/src/Model/Generated/Object/InvoiceItemGroup.php +++ b/src/Model/Generated/Object/InvoiceItemGroup.php @@ -182,4 +182,40 @@ public function setItem($item) { $this->item = $item; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->type)) { + return false; + } + + if (!is_null($this->typeDescription)) { + return false; + } + + if (!is_null($this->typeDescriptionTranslated)) { + return false; + } + + if (!is_null($this->instanceDescription)) { + return false; + } + + if (!is_null($this->productVatExclusive)) { + return false; + } + + if (!is_null($this->productVatInclusive)) { + return false; + } + + if (!is_null($this->item)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Object/Issuer.php b/src/Model/Generated/Object/Issuer.php index 178ebc51..5b919629 100644 --- a/src/Model/Generated/Object/Issuer.php +++ b/src/Model/Generated/Object/Issuer.php @@ -65,4 +65,20 @@ public function setName($name) { $this->name = $name; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->bic)) { + return false; + } + + if (!is_null($this->name)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Object/LabelCard.php b/src/Model/Generated/Object/LabelCard.php index e075d0f5..5b5842f3 100644 --- a/src/Model/Generated/Object/LabelCard.php +++ b/src/Model/Generated/Object/LabelCard.php @@ -157,4 +157,36 @@ public function setLabelUser($labelUser) { $this->labelUser = $labelUser; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->uuid)) { + return false; + } + + if (!is_null($this->type)) { + return false; + } + + if (!is_null($this->secondLine)) { + return false; + } + + if (!is_null($this->expiryDate)) { + return false; + } + + if (!is_null($this->status)) { + return false; + } + + if (!is_null($this->labelUser)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Object/LabelMonetaryAccount.php b/src/Model/Generated/Object/LabelMonetaryAccount.php index dc3b7151..fea87cfa 100644 --- a/src/Model/Generated/Object/LabelMonetaryAccount.php +++ b/src/Model/Generated/Object/LabelMonetaryAccount.php @@ -232,4 +232,48 @@ public function setSwiftAccountNumber($swiftAccountNumber) { $this->swiftAccountNumber = $swiftAccountNumber; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->iban)) { + return false; + } + + if (!is_null($this->displayName)) { + return false; + } + + if (!is_null($this->avatar)) { + return false; + } + + if (!is_null($this->labelUser)) { + return false; + } + + if (!is_null($this->country)) { + return false; + } + + if (!is_null($this->bunqMe)) { + return false; + } + + if (!is_null($this->isLight)) { + return false; + } + + if (!is_null($this->swiftBic)) { + return false; + } + + if (!is_null($this->swiftAccountNumber)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Object/LabelUser.php b/src/Model/Generated/Object/LabelUser.php index 3815d634..60cef124 100644 --- a/src/Model/Generated/Object/LabelUser.php +++ b/src/Model/Generated/Object/LabelUser.php @@ -144,4 +144,32 @@ public function setCountry($country) { $this->country = $country; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->uuid)) { + return false; + } + + if (!is_null($this->avatar)) { + return false; + } + + if (!is_null($this->publicNickName)) { + return false; + } + + if (!is_null($this->displayName)) { + return false; + } + + if (!is_null($this->country)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Object/MonetaryAccountProfileDrain.php b/src/Model/Generated/Object/MonetaryAccountProfileDrain.php index f8c5b9e9..4ad7e002 100644 --- a/src/Model/Generated/Object/MonetaryAccountProfileDrain.php +++ b/src/Model/Generated/Object/MonetaryAccountProfileDrain.php @@ -121,4 +121,28 @@ public function setSavingsAccountAlias($savingsAccountAlias) { $this->savingsAccountAlias = $savingsAccountAlias; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->status)) { + return false; + } + + if (!is_null($this->balancePreferred)) { + return false; + } + + if (!is_null($this->balanceThresholdHigh)) { + return false; + } + + if (!is_null($this->savingsAccountAlias)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Object/MonetaryAccountProfileFill.php b/src/Model/Generated/Object/MonetaryAccountProfileFill.php index 24639659..a4177061 100644 --- a/src/Model/Generated/Object/MonetaryAccountProfileFill.php +++ b/src/Model/Generated/Object/MonetaryAccountProfileFill.php @@ -148,4 +148,32 @@ public function setIssuer($issuer) { $this->issuer = $issuer; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->status)) { + return false; + } + + if (!is_null($this->balancePreferred)) { + return false; + } + + if (!is_null($this->balanceThresholdLow)) { + return false; + } + + if (!is_null($this->methodFill)) { + return false; + } + + if (!is_null($this->issuer)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Object/MonetaryAccountSetting.php b/src/Model/Generated/Object/MonetaryAccountSetting.php index a04d4229..b79b0444 100644 --- a/src/Model/Generated/Object/MonetaryAccountSetting.php +++ b/src/Model/Generated/Object/MonetaryAccountSetting.php @@ -86,4 +86,24 @@ public function setRestrictionChat($restrictionChat) { $this->restrictionChat = $restrictionChat; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->color)) { + return false; + } + + if (!is_null($this->defaultAvatarStatus)) { + return false; + } + + if (!is_null($this->restrictionChat)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Object/NotificationAnchorObject.php b/src/Model/Generated/Object/NotificationAnchorObject.php index 2ba5d2b2..bddd00fe 100644 --- a/src/Model/Generated/Object/NotificationAnchorObject.php +++ b/src/Model/Generated/Object/NotificationAnchorObject.php @@ -6,14 +6,12 @@ use bunq\Model\Generated\Endpoint\BunqMeTab; use bunq\Model\Generated\Endpoint\BunqMeTabResultInquiry; use bunq\Model\Generated\Endpoint\BunqMeTabResultResponse; -use bunq\Model\Generated\Endpoint\ChatMessageAnnouncement; -use bunq\Model\Generated\Endpoint\ChatMessageStatus; -use bunq\Model\Generated\Endpoint\ChatMessageUser; +use bunq\Model\Generated\Endpoint\ChatMessage; use bunq\Model\Generated\Endpoint\DraftPayment; use bunq\Model\Generated\Endpoint\IdealMerchantTransaction; use bunq\Model\Generated\Endpoint\Invoice; use bunq\Model\Generated\Endpoint\MasterCardAction; -use bunq\Model\Generated\Endpoint\MonetaryAccountBank; +use bunq\Model\Generated\Endpoint\MonetaryAccount; use bunq\Model\Generated\Endpoint\Payment; use bunq\Model\Generated\Endpoint\PaymentBatch; use bunq\Model\Generated\Endpoint\RequestInquiry; @@ -25,8 +23,7 @@ use bunq\Model\Generated\Endpoint\ShareInviteBankResponse; use bunq\Model\Generated\Endpoint\TabResultInquiry; use bunq\Model\Generated\Endpoint\TabResultResponse; -use bunq\Model\Generated\Endpoint\UserCompany; -use bunq\Model\Generated\Endpoint\UserPerson; +use bunq\Model\Generated\Endpoint\User; /** * @generated @@ -54,19 +51,9 @@ class NotificationAnchorObject extends BunqModel protected $bunqMeTabResultResponse; /** - * @var ChatMessageStatus + * @var ChatMessage */ - protected $chatMessageStatus; - - /** - * @var ChatMessageUser - */ - protected $chatMessageUser; - - /** - * @var ChatMessageAnnouncement - */ - protected $chatMessageAnnouncement; + protected $chatMessage; /** * @var DraftPayment @@ -89,9 +76,9 @@ class NotificationAnchorObject extends BunqModel protected $masterCardAction; /** - * @var MonetaryAccountBank + * @var MonetaryAccount */ - protected $monetaryAccountBank; + protected $monetaryAccount; /** * @var Payment @@ -149,14 +136,12 @@ class NotificationAnchorObject extends BunqModel protected $tabResultResponse; /** - * @var UserPerson + * @var User */ - protected $userPerson; + protected $user; /** - * @var UserCompany */ - protected $userCompany; /** * @return BunqMeTab @@ -207,51 +192,19 @@ public function setBunqMeTabResultResponse($bunqMeTabResultResponse) } /** - * @return ChatMessageStatus - */ - public function getChatMessageStatus() - { - return $this->chatMessageStatus; - } - - /** - * @param ChatMessageStatus $chatMessageStatus + * @return ChatMessage */ - public function setChatMessageStatus($chatMessageStatus) + public function getChatMessage() { - $this->chatMessageStatus = $chatMessageStatus; + return $this->chatMessage; } /** - * @return ChatMessageUser + * @param ChatMessage $chatMessage */ - public function getChatMessageUser() + public function setChatMessage($chatMessage) { - return $this->chatMessageUser; - } - - /** - * @param ChatMessageUser $chatMessageUser - */ - public function setChatMessageUser($chatMessageUser) - { - $this->chatMessageUser = $chatMessageUser; - } - - /** - * @return ChatMessageAnnouncement - */ - public function getChatMessageAnnouncement() - { - return $this->chatMessageAnnouncement; - } - - /** - * @param ChatMessageAnnouncement $chatMessageAnnouncement - */ - public function setChatMessageAnnouncement($chatMessageAnnouncement) - { - $this->chatMessageAnnouncement = $chatMessageAnnouncement; + $this->chatMessage = $chatMessage; } /** @@ -319,19 +272,19 @@ public function setMasterCardAction($masterCardAction) } /** - * @return MonetaryAccountBank + * @return MonetaryAccount */ - public function getMonetaryAccountBank() + public function getMonetaryAccount() { - return $this->monetaryAccountBank; + return $this->monetaryAccount; } /** - * @param MonetaryAccountBank $monetaryAccountBank + * @param MonetaryAccount $monetaryAccount */ - public function setMonetaryAccountBank($monetaryAccountBank) + public function setMonetaryAccount($monetaryAccount) { - $this->monetaryAccountBank = $monetaryAccountBank; + $this->monetaryAccount = $monetaryAccount; } /** @@ -511,35 +464,19 @@ public function setTabResultResponse($tabResultResponse) } /** - * @return UserPerson + * @return User */ - public function getUserPerson() + public function getUser() { - return $this->userPerson; + return $this->user; } /** - * @param UserPerson $userPerson + * @param User $user */ - public function setUserPerson($userPerson) + public function setUser($user) { - $this->userPerson = $userPerson; - } - - /** - * @return UserCompany - */ - public function getUserCompany() - { - return $this->userCompany; - } - - /** - * @param UserCompany $userCompany - */ - public function setUserCompany($userCompany) - { - $this->userCompany = $userCompany; + $this->user = $user; } /** @@ -560,16 +497,8 @@ public function getReferencedObject() return $this->bunqMeTabResultResponse; } - if (!is_null($this->chatMessageStatus)) { - return $this->chatMessageStatus; - } - - if (!is_null($this->chatMessageUser)) { - return $this->chatMessageUser; - } - - if (!is_null($this->chatMessageAnnouncement)) { - return $this->chatMessageAnnouncement; + if (!is_null($this->chatMessage)) { + return $this->chatMessage; } if (!is_null($this->draftPayment)) { @@ -588,8 +517,8 @@ public function getReferencedObject() return $this->masterCardAction; } - if (!is_null($this->monetaryAccountBank)) { - return $this->monetaryAccountBank; + if (!is_null($this->monetaryAccount)) { + return $this->monetaryAccount; } if (!is_null($this->payment)) { @@ -636,14 +565,102 @@ public function getReferencedObject() return $this->tabResultResponse; } - if (!is_null($this->userPerson)) { - return $this->userPerson; + if (!is_null($this->user)) { + return $this->user; } - if (!is_null($this->userCompany)) { - return $this->userCompany; + throw new BunqException(self::ERROR_NULL_FIELDS); + } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->bunqMeTab)) { + return false; } - throw new BunqException(self::ERROR_NULL_FIELDS); + if (!is_null($this->bunqMeTabResultInquiry)) { + return false; + } + + if (!is_null($this->bunqMeTabResultResponse)) { + return false; + } + + if (!is_null($this->chatMessage)) { + return false; + } + + if (!is_null($this->draftPayment)) { + return false; + } + + if (!is_null($this->idealMerchantTransaction)) { + return false; + } + + if (!is_null($this->invoice)) { + return false; + } + + if (!is_null($this->masterCardAction)) { + return false; + } + + if (!is_null($this->monetaryAccount)) { + return false; + } + + if (!is_null($this->payment)) { + return false; + } + + if (!is_null($this->paymentBatch)) { + return false; + } + + if (!is_null($this->requestInquiry)) { + return false; + } + + if (!is_null($this->requestInquiryBatch)) { + return false; + } + + if (!is_null($this->requestResponse)) { + return false; + } + + if (!is_null($this->shareInviteBankInquiry)) { + return false; + } + + if (!is_null($this->shareInviteBankResponse)) { + return false; + } + + if (!is_null($this->scheduledPayment)) { + return false; + } + + if (!is_null($this->scheduledInstance)) { + return false; + } + + if (!is_null($this->tabResultInquiry)) { + return false; + } + + if (!is_null($this->tabResultResponse)) { + return false; + } + + if (!is_null($this->user)) { + return false; + } + + return true; } } diff --git a/src/Model/Generated/Object/NotificationFilter.php b/src/Model/Generated/Object/NotificationFilter.php index 343ca6a4..819ebce9 100644 --- a/src/Model/Generated/Object/NotificationFilter.php +++ b/src/Model/Generated/Object/NotificationFilter.php @@ -112,4 +112,24 @@ public function setCategory($category) { $this->category = $category; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->notificationDeliveryMethod)) { + return false; + } + + if (!is_null($this->notificationTarget)) { + return false; + } + + if (!is_null($this->category)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Object/NotificationUrl.php b/src/Model/Generated/Object/NotificationUrl.php index 5b7238d2..7aafa8c5 100644 --- a/src/Model/Generated/Object/NotificationUrl.php +++ b/src/Model/Generated/Object/NotificationUrl.php @@ -91,4 +91,28 @@ public function setObject($object) { $this->object = $object; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->targetUrl)) { + return false; + } + + if (!is_null($this->category)) { + return false; + } + + if (!is_null($this->eventType)) { + return false; + } + + if (!is_null($this->object)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Object/PermittedDevice.php b/src/Model/Generated/Object/PermittedDevice.php index 022ce1e1..9b337b8a 100644 --- a/src/Model/Generated/Object/PermittedDevice.php +++ b/src/Model/Generated/Object/PermittedDevice.php @@ -57,4 +57,20 @@ public function setIp($ip) { $this->ip = $ip; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->description)) { + return false; + } + + if (!is_null($this->ip)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Object/Pointer.php b/src/Model/Generated/Object/Pointer.php index 904d3e2f..7249935a 100644 --- a/src/Model/Generated/Object/Pointer.php +++ b/src/Model/Generated/Object/Pointer.php @@ -92,4 +92,24 @@ public function setName($name) { $this->name = $name; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->type)) { + return false; + } + + if (!is_null($this->value)) { + return false; + } + + if (!is_null($this->name)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Object/ScheduleAnchorObject.php b/src/Model/Generated/Object/ScheduleAnchorObject.php index 33323ff6..03bb1807 100644 --- a/src/Model/Generated/Object/ScheduleAnchorObject.php +++ b/src/Model/Generated/Object/ScheduleAnchorObject.php @@ -74,4 +74,20 @@ public function getReferencedObject() throw new BunqException(self::ERROR_NULL_FIELDS); } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->payment)) { + return false; + } + + if (!is_null($this->paymentBatch)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Object/ScheduleInstanceAnchorObject.php b/src/Model/Generated/Object/ScheduleInstanceAnchorObject.php index 620d799a..33967692 100644 --- a/src/Model/Generated/Object/ScheduleInstanceAnchorObject.php +++ b/src/Model/Generated/Object/ScheduleInstanceAnchorObject.php @@ -74,4 +74,20 @@ public function getReferencedObject() throw new BunqException(self::ERROR_NULL_FIELDS); } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->payment)) { + return false; + } + + if (!is_null($this->paymentBatch)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Object/SchedulePaymentEntry.php b/src/Model/Generated/Object/SchedulePaymentEntry.php index 3e894c7e..833a52e4 100644 --- a/src/Model/Generated/Object/SchedulePaymentEntry.php +++ b/src/Model/Generated/Object/SchedulePaymentEntry.php @@ -189,4 +189,36 @@ public function setMerchantReference($merchantReference) { $this->merchantReference = $merchantReference; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->amount)) { + return false; + } + + if (!is_null($this->alias)) { + return false; + } + + if (!is_null($this->counterpartyAlias)) { + return false; + } + + if (!is_null($this->description)) { + return false; + } + + if (!is_null($this->attachment)) { + return false; + } + + if (!is_null($this->merchantReference)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Object/ShareDetail.php b/src/Model/Generated/Object/ShareDetail.php index f6514067..cb2560d8 100644 --- a/src/Model/Generated/Object/ShareDetail.php +++ b/src/Model/Generated/Object/ShareDetail.php @@ -98,4 +98,24 @@ public function setDraftPayment($draftPayment) { $this->draftPayment = $draftPayment; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->payment)) { + return false; + } + + if (!is_null($this->readOnly)) { + return false; + } + + if (!is_null($this->draftPayment)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Object/ShareDetailDraftPayment.php b/src/Model/Generated/Object/ShareDetailDraftPayment.php index de24ac00..27c0d408 100644 --- a/src/Model/Generated/Object/ShareDetailDraftPayment.php +++ b/src/Model/Generated/Object/ShareDetailDraftPayment.php @@ -129,4 +129,28 @@ public function setViewNewEvents($viewNewEvents) { $this->viewNewEvents = $viewNewEvents; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->makeDraftPayments)) { + return false; + } + + if (!is_null($this->viewBalance)) { + return false; + } + + if (!is_null($this->viewOldEvents)) { + return false; + } + + if (!is_null($this->viewNewEvents)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Object/ShareDetailPayment.php b/src/Model/Generated/Object/ShareDetailPayment.php index 222abd91..cf180632 100644 --- a/src/Model/Generated/Object/ShareDetailPayment.php +++ b/src/Model/Generated/Object/ShareDetailPayment.php @@ -181,4 +181,36 @@ public function setBudget($budget) { $this->budget = $budget; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->makePayments)) { + return false; + } + + if (!is_null($this->makeDraftPayments)) { + return false; + } + + if (!is_null($this->viewBalance)) { + return false; + } + + if (!is_null($this->viewOldEvents)) { + return false; + } + + if (!is_null($this->viewNewEvents)) { + return false; + } + + if (!is_null($this->budget)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Object/ShareDetailReadOnly.php b/src/Model/Generated/Object/ShareDetailReadOnly.php index 41fdc5fa..bcd05746 100644 --- a/src/Model/Generated/Object/ShareDetailReadOnly.php +++ b/src/Model/Generated/Object/ShareDetailReadOnly.php @@ -100,4 +100,24 @@ public function setViewNewEvents($viewNewEvents) { $this->viewNewEvents = $viewNewEvents; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->viewBalance)) { + return false; + } + + if (!is_null($this->viewOldEvents)) { + return false; + } + + if (!is_null($this->viewNewEvents)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Object/TabTextWaitingScreen.php b/src/Model/Generated/Object/TabTextWaitingScreen.php index 32f8b674..159f3473 100644 --- a/src/Model/Generated/Object/TabTextWaitingScreen.php +++ b/src/Model/Generated/Object/TabTextWaitingScreen.php @@ -67,4 +67,20 @@ public function setDescription($description) { $this->description = $description; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->language)) { + return false; + } + + if (!is_null($this->description)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Object/TabVisibility.php b/src/Model/Generated/Object/TabVisibility.php index 6683561e..28165913 100644 --- a/src/Model/Generated/Object/TabVisibility.php +++ b/src/Model/Generated/Object/TabVisibility.php @@ -94,4 +94,24 @@ public function setLocation($location) { $this->location = $location; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->cashRegisterQrCode)) { + return false; + } + + if (!is_null($this->tabQrCode)) { + return false; + } + + if (!is_null($this->location)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Object/TaxResident.php b/src/Model/Generated/Object/TaxResident.php index 71468d3e..17ad08f5 100644 --- a/src/Model/Generated/Object/TaxResident.php +++ b/src/Model/Generated/Object/TaxResident.php @@ -67,4 +67,20 @@ public function setTaxNumber($taxNumber) { $this->taxNumber = $taxNumber; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->country)) { + return false; + } + + if (!is_null($this->taxNumber)) { + return false; + } + + return true; + } } diff --git a/src/Model/Generated/Object/Ubo.php b/src/Model/Generated/Object/Ubo.php index d32aa891..27bf4ca8 100644 --- a/src/Model/Generated/Object/Ubo.php +++ b/src/Model/Generated/Object/Ubo.php @@ -82,4 +82,24 @@ public function setNationality($nationality) { $this->nationality = $nationality; } + + /** + * @return bool + */ + public function areAllFieldsNull() + { + if (!is_null($this->name)) { + return false; + } + + if (!is_null($this->dateOfBirth)) { + return false; + } + + if (!is_null($this->nationality)) { + return false; + } + + return true; + } } From 363748f8ab71ee7002aa6c26ea73b0d108262263 Mon Sep 17 00:00:00 2001 From: Kevin Hellemun Date: Fri, 17 Nov 2017 23:54:01 +0100 Subject: [PATCH 13/27] Changed NotificationUrlTest to use Parent classes. (bunq/sdk_php#68) --- .../Generated/Object/NotificationUrlTest.php | 17 ++++++++--------- 1 file changed, 8 insertions(+), 9 deletions(-) diff --git a/tests/Model/Generated/Object/NotificationUrlTest.php b/tests/Model/Generated/Object/NotificationUrlTest.php index 8f9190b4..489fcc3a 100644 --- a/tests/Model/Generated/Object/NotificationUrlTest.php +++ b/tests/Model/Generated/Object/NotificationUrlTest.php @@ -1,13 +1,12 @@ executeNotificationUrlTest( self::JSON_PATH_MONETARY_ACCOUNT_BANK_MODEL, - MonetaryAccountBank::class, - self::GETTER_MONETARY_ACCOUNT_BANK + MonetaryAccount::class, + self::GETTER_MONETARY_ACCOUNT ); } @@ -199,8 +198,8 @@ public function testChatMessageAnnouncementModel() { $this->executeNotificationUrlTest( self::JSON_PATH_CHAT_MESSAGE_ANNOUNCEMENT_MODEL, - ChatMessageAnnouncement::class, - self::GETTER_CHAT_MESSAGE_ANNOUNCEMENT + ChatMessage::class, + self::GETTER_CHAT_MESSAGE ); } From 2a66b1c17df009010e78c18cc54c43150d5c9999 Mon Sep 17 00:00:00 2001 From: Kevin Hellemun Date: Sat, 18 Nov 2017 08:51:07 +0100 Subject: [PATCH 14/27] Extracted field decoding in seperate method. (bunq/sdk_php#68) --- src/Model/Core/BunqModel.php | 56 ++++++++++++++++++++++-------------- 1 file changed, 35 insertions(+), 21 deletions(-) diff --git a/src/Model/Core/BunqModel.php b/src/Model/Core/BunqModel.php index 37377993..dce054c6 100644 --- a/src/Model/Core/BunqModel.php +++ b/src/Model/Core/BunqModel.php @@ -154,28 +154,42 @@ protected static function createFromResponseArray( $model = self::createInstanceFromResponseArray($responseArray); if ($model->areAllFieldsNull() && $depthCounter < self::DEPTH_COUNTER_MAX) { - $modelFields = (array_keys(get_object_vars($model))); - - foreach ($modelFields as $field) { - try { - $fieldClass = ModelUtil::determineModelClassNameQualified($field); - $reflectionClass = new ReflectionClass($fieldClass); - /** @var BunqModel $bunqModelSubClass */ - $bunqModelSubClass = $reflectionClass->newInstanceWithoutConstructor(); - $fieldContents = $bunqModelSubClass::createFromResponseArray( - $responseArray, - null, - $depthCounter + self::DEPTH_COUNTER_INCREMENTER - ); - - if ($fieldContents->areAllFieldsNull()) { - $model->{$field} = null; - } else { - $model->{$field} = $fieldContents; - } - } catch (BunqException $exception) { - continue; + $model = self::decodeInsideModelFields($responseArray, $model, $depthCounter); + } + + return $model; + } + + /** + * @param array $responseArray + * @param BunqModel $model + * @param int $depthCounter + * + * @return BunqModel + */ + private static function decodeInsideModelFields(array $responseArray, BunqModel $model, int $depthCounter) + { + $modelFields = (array_keys(get_object_vars($model))); + + foreach ($modelFields as $field) { + try { + $fieldClass = ModelUtil::determineModelClassNameQualified($field); + $reflectionClass = new ReflectionClass($fieldClass); + /** @var BunqModel $bunqModelSubClass */ + $bunqModelSubClass = $reflectionClass->newInstanceWithoutConstructor(); + $fieldContents = $bunqModelSubClass::createFromResponseArray( + $responseArray, + null, + $depthCounter + self::DEPTH_COUNTER_INCREMENTER + ); + + if ($fieldContents->areAllFieldsNull()) { + $model->{$field} = null; + } else { + $model->{$field} = $fieldContents; } + } catch (BunqException $exception) { + continue; } } From cd7e169ec988aa8bb90ec066e5f3b5140fb84ea2 Mon Sep 17 00:00:00 2001 From: Kevin Hellemun Date: Sat, 18 Nov 2017 09:36:56 +0100 Subject: [PATCH 15/27] Added subClass assertion check to notificationUrlTest. (bunq/sdk_php#68) --- .../Generated/Object/NotificationUrlTest.php | 25 ++++++++++++++++--- 1 file changed, 22 insertions(+), 3 deletions(-) diff --git a/tests/Model/Generated/Object/NotificationUrlTest.php b/tests/Model/Generated/Object/NotificationUrlTest.php index 489fcc3a..8547fb60 100644 --- a/tests/Model/Generated/Object/NotificationUrlTest.php +++ b/tests/Model/Generated/Object/NotificationUrlTest.php @@ -4,9 +4,11 @@ use bunq\Model\Core\BunqModel; use bunq\Model\Generated\Endpoint\BunqMeTab; use bunq\Model\Generated\Endpoint\ChatMessage; +use bunq\Model\Generated\Endpoint\ChatMessageAnnouncement; use bunq\Model\Generated\Endpoint\DraftPayment; use bunq\Model\Generated\Endpoint\MasterCardAction; use bunq\Model\Generated\Endpoint\MonetaryAccount; +use bunq\Model\Generated\Endpoint\MonetaryAccountBank; use bunq\Model\Generated\Endpoint\Payment; use bunq\Model\Generated\Endpoint\PaymentBatch; use bunq\Model\Generated\Endpoint\RequestInquiry; @@ -37,9 +39,11 @@ class NotificationUrlTest extends BunqSdkTestBase const GETTER_PAYMENT = 'getPayment'; const GETTER_BUNQ_ME_TAB = 'getBunqMeTab'; const GETTER_CHAT_MESSAGE = 'getChatMessage'; + const GETTER_CHAT_MESSAGE_ANNOUNCEMENT = 'getChatMessageAnnouncement'; const GETTER_DRAFT_PAYMENT = 'getDraftPayment'; const GETTER_MASTER_CARD_ACTION = 'getMasterCardAction'; const GETTER_MONETARY_ACCOUNT = 'getMonetaryAccount'; + const GETTER_MONETARY_ACCOUNT_BANK= 'getMonetaryAccountBank'; const GETTER_PAYMENT_BATCH = 'getPaymentBatch'; const GETTER_REQUEST_INQUIRY = 'getRequestInquiry'; const GETTER_REQUEST_RESPONSE = 'getRequestResponse'; @@ -100,7 +104,9 @@ public function testGetMonetaryAccountModel() $this->executeNotificationUrlTest( self::JSON_PATH_MONETARY_ACCOUNT_BANK_MODEL, MonetaryAccount::class, - self::GETTER_MONETARY_ACCOUNT + self::GETTER_MONETARY_ACCOUNT, + self::GETTER_MONETARY_ACCOUNT_BANK, + MonetaryAccountBank::class ); } @@ -199,7 +205,9 @@ public function testChatMessageAnnouncementModel() $this->executeNotificationUrlTest( self::JSON_PATH_CHAT_MESSAGE_ANNOUNCEMENT_MODEL, ChatMessage::class, - self::GETTER_CHAT_MESSAGE + self::GETTER_CHAT_MESSAGE, + self::GETTER_CHAT_MESSAGE_ANNOUNCEMENT, + ChatMessageAnnouncement::class ); } @@ -218,11 +226,15 @@ public function testDraftPaymentModel() * @param string $expectedJsonFileName * @param string $classNameExpected * @param string $referencedObjectGetterName + * @param string|null $subClassObjectGetterName + * @param string|null $subClassNameExpected */ private function executeNotificationUrlTest( string $expectedJsonFileName, string $classNameExpected, - string $referencedObjectGetterName + string $referencedObjectGetterName, + string $subClassObjectGetterName = null, + string $subClassNameExpected = null ) { $jsonExpectedString = FileUtil::getFileContents($expectedJsonFileName); $notificationUrl = $this->getNotificationUrlFromJson($jsonExpectedString); @@ -233,6 +245,13 @@ private function executeNotificationUrlTest( static::assertNotNull($model); static::assertNotNull($referencedModel); static::assertInstanceOf($classNameExpected, $referencedModel); + + if (!is_null($subClassObjectGetterName)) { + $subClassModel = $referencedModel->$subClassObjectGetterName(); + + static::assertNotNull($subClassModel); + static::assertInstanceOf($subClassNameExpected, $subClassModel); + } } /** From 06b1bb6780687631d288e23bc72574308ea407a6 Mon Sep 17 00:00:00 2001 From: Kevin Hellemun Date: Tue, 21 Nov 2017 15:30:37 +0100 Subject: [PATCH 16/27] Created seperate resposne array method for anchored object. (bunq/sdk_php#68) --- src/Model/Core/BunqModel.php | 28 +++++++++++++++++++++++----- src/Model/Core/ServerPublicKey.php | 4 +--- 2 files changed, 24 insertions(+), 8 deletions(-) diff --git a/src/Model/Core/BunqModel.php b/src/Model/Core/BunqModel.php index dce054c6..d06f9c72 100644 --- a/src/Model/Core/BunqModel.php +++ b/src/Model/Core/BunqModel.php @@ -130,15 +130,17 @@ protected static function createListFromResponseArray( /** * @param mixed[] $responseArray * @param string $wrapper - * @param int $depthCounter * * @return BunqModel|null */ protected static function createFromResponseArray( array $responseArray, - string $wrapper = null, - int $depthCounter = null + string $wrapper = null ) { + if (is_subclass_of(get_called_class(), AnchorObjectInterface::class)) { + return self::createFromResponseArrayAnchorObject($responseArray); + } + if (is_string($wrapper)) { $responseArray = $responseArray[$wrapper]; } @@ -147,6 +149,23 @@ protected static function createFromResponseArray( return null; } + return self::createInstanceFromResponseArray($responseArray); + } + + /** + * @param array $responseArray + * @param int|null $depthCounter + * + * @return BunqModel|null + */ + private static function createFromResponseArrayAnchorObject( + array $responseArray, + int $depthCounter = null + ) { + if (is_null($responseArray)) { + return null; + } + if (is_null($depthCounter)) { $depthCounter = self::DEPTH_COUNTER_BEGIN; } @@ -177,9 +196,8 @@ private static function decodeInsideModelFields(array $responseArray, BunqModel $reflectionClass = new ReflectionClass($fieldClass); /** @var BunqModel $bunqModelSubClass */ $bunqModelSubClass = $reflectionClass->newInstanceWithoutConstructor(); - $fieldContents = $bunqModelSubClass::createFromResponseArray( + $fieldContents = $bunqModelSubClass::createFromResponseArrayAnchorObject( $responseArray, - null, $depthCounter + self::DEPTH_COUNTER_INCREMENTER ); diff --git a/src/Model/Core/ServerPublicKey.php b/src/Model/Core/ServerPublicKey.php index 930d6874..ac956f7b 100644 --- a/src/Model/Core/ServerPublicKey.php +++ b/src/Model/Core/ServerPublicKey.php @@ -36,14 +36,12 @@ public function getServerPublicKey(): PublicKey /** * @param array $responseArray * @param string|null $wrapper - * @param int|null $depthCounter * * @return static */ protected static function createFromResponseArray( array $responseArray, - string $wrapper = null, - int $depthCounter = null + string $wrapper = null ) { return new static($responseArray[self::FIELD_SERVER_PUBLIC_KEY]); } From 606cd7dd0bf937ba069e9fa48a069d2a309ee5de Mon Sep 17 00:00:00 2001 From: Kevin Hellemun Date: Tue, 21 Nov 2017 15:32:03 +0100 Subject: [PATCH 17/27] Added new AnchoredObjectInterface. (bunq/sdk_php#68) --- src/Model/Core/AnchorObjectInterface.php | 9 +++++++++ 1 file changed, 9 insertions(+) create mode 100644 src/Model/Core/AnchorObjectInterface.php diff --git a/src/Model/Core/AnchorObjectInterface.php b/src/Model/Core/AnchorObjectInterface.php new file mode 100644 index 00000000..eaf2a6a7 --- /dev/null +++ b/src/Model/Core/AnchorObjectInterface.php @@ -0,0 +1,9 @@ + Date: Tue, 21 Nov 2017 16:28:42 +0100 Subject: [PATCH 18/27] Added new anchored object interface. (bunq/sdk_php#68) --- src/Model/Generated/Endpoint/ChatConversation.php | 3 ++- src/Model/Generated/Endpoint/ChatMessage.php | 3 ++- src/Model/Generated/Endpoint/Device.php | 3 ++- src/Model/Generated/Endpoint/MonetaryAccount.php | 3 ++- src/Model/Generated/Endpoint/Tab.php | 3 ++- src/Model/Generated/Endpoint/User.php | 3 ++- src/Model/Generated/Object/AnchoredObject.php | 3 ++- src/Model/Generated/Object/ChatMessageContent.php | 3 ++- src/Model/Generated/Object/DraftPaymentAnchorObject.php | 3 ++- src/Model/Generated/Object/NotificationAnchorObject.php | 2 +- src/Model/Generated/Object/ScheduleAnchorObject.php | 3 ++- src/Model/Generated/Object/ScheduleInstanceAnchorObject.php | 3 ++- 12 files changed, 23 insertions(+), 12 deletions(-) diff --git a/src/Model/Generated/Endpoint/ChatConversation.php b/src/Model/Generated/Endpoint/ChatConversation.php index 6f802d3a..f06bc480 100644 --- a/src/Model/Generated/Endpoint/ChatConversation.php +++ b/src/Model/Generated/Endpoint/ChatConversation.php @@ -5,6 +5,7 @@ use bunq\exception\BunqException; use bunq\Http\ApiClient; use bunq\Http\BunqResponse; +use bunq\Model\Core\AnchorObjectInterface; use bunq\Model\Core\BunqModel; /** @@ -12,7 +13,7 @@ * * @generated */ -class ChatConversation extends BunqModel +class ChatConversation extends BunqModel implements AnchorObjectInterface { /** * Error constants. diff --git a/src/Model/Generated/Endpoint/ChatMessage.php b/src/Model/Generated/Endpoint/ChatMessage.php index 17c619a5..579b5ab1 100644 --- a/src/Model/Generated/Endpoint/ChatMessage.php +++ b/src/Model/Generated/Endpoint/ChatMessage.php @@ -5,6 +5,7 @@ use bunq\exception\BunqException; use bunq\Http\ApiClient; use bunq\Http\BunqResponse; +use bunq\Model\Core\AnchorObjectInterface; use bunq\Model\Core\BunqModel; /** @@ -12,7 +13,7 @@ * * @generated */ -class ChatMessage extends BunqModel +class ChatMessage extends BunqModel implements AnchorObjectInterface { /** * Error constants. diff --git a/src/Model/Generated/Endpoint/Device.php b/src/Model/Generated/Endpoint/Device.php index c6f49635..1c6e2e01 100644 --- a/src/Model/Generated/Endpoint/Device.php +++ b/src/Model/Generated/Endpoint/Device.php @@ -5,6 +5,7 @@ use bunq\exception\BunqException; use bunq\Http\ApiClient; use bunq\Http\BunqResponse; +use bunq\Model\Core\AnchorObjectInterface; use bunq\Model\Core\BunqModel; /** @@ -13,7 +14,7 @@ * * @generated */ -class Device extends BunqModel +class Device extends BunqModel implements AnchorObjectInterface { /** * Error constants. diff --git a/src/Model/Generated/Endpoint/MonetaryAccount.php b/src/Model/Generated/Endpoint/MonetaryAccount.php index 1e660b78..686bbba0 100644 --- a/src/Model/Generated/Endpoint/MonetaryAccount.php +++ b/src/Model/Generated/Endpoint/MonetaryAccount.php @@ -5,6 +5,7 @@ use bunq\exception\BunqException; use bunq\Http\ApiClient; use bunq\Http\BunqResponse; +use bunq\Model\Core\AnchorObjectInterface; use bunq\Model\Core\BunqModel; /** @@ -16,7 +17,7 @@ * * @generated */ -class MonetaryAccount extends BunqModel +class MonetaryAccount extends BunqModel implements AnchorObjectInterface { /** * Error constants. diff --git a/src/Model/Generated/Endpoint/Tab.php b/src/Model/Generated/Endpoint/Tab.php index a102820f..c57b5f64 100644 --- a/src/Model/Generated/Endpoint/Tab.php +++ b/src/Model/Generated/Endpoint/Tab.php @@ -5,6 +5,7 @@ use bunq\exception\BunqException; use bunq\Http\ApiClient; use bunq\Http\BunqResponse; +use bunq\Model\Core\AnchorObjectInterface; use bunq\Model\Core\BunqModel; /** @@ -18,7 +19,7 @@ * * @generated */ -class Tab extends BunqModel +class Tab extends BunqModel implements AnchorObjectInterface { /** * Error constants. diff --git a/src/Model/Generated/Endpoint/User.php b/src/Model/Generated/Endpoint/User.php index 25e9e0e0..3fc4f63a 100644 --- a/src/Model/Generated/Endpoint/User.php +++ b/src/Model/Generated/Endpoint/User.php @@ -5,6 +5,7 @@ use bunq\exception\BunqException; use bunq\Http\ApiClient; use bunq\Http\BunqResponse; +use bunq\Model\Core\AnchorObjectInterface; use bunq\Model\Core\BunqModel; /** @@ -13,7 +14,7 @@ * * @generated */ -class User extends BunqModel +class User extends BunqModel implements AnchorObjectInterface { /** * Error constants. diff --git a/src/Model/Generated/Object/AnchoredObject.php b/src/Model/Generated/Object/AnchoredObject.php index 7e50063f..fdb8a346 100644 --- a/src/Model/Generated/Object/AnchoredObject.php +++ b/src/Model/Generated/Object/AnchoredObject.php @@ -2,6 +2,7 @@ namespace bunq\Model\Generated\Object; use bunq\exception\BunqException; +use bunq\Model\Core\AnchorObjectInterface; use bunq\Model\Core\BunqModel; use bunq\Model\Generated\Endpoint\CardDebit; use bunq\Model\Generated\Endpoint\CardPinChange; @@ -25,7 +26,7 @@ /** * @generated */ -class AnchoredObject extends BunqModel +class AnchoredObject extends BunqModel implements AnchorObjectInterface { /** * Error constants. diff --git a/src/Model/Generated/Object/ChatMessageContent.php b/src/Model/Generated/Object/ChatMessageContent.php index b3fdf16c..91de2464 100644 --- a/src/Model/Generated/Object/ChatMessageContent.php +++ b/src/Model/Generated/Object/ChatMessageContent.php @@ -2,12 +2,13 @@ namespace bunq\Model\Generated\Object; use bunq\exception\BunqException; +use bunq\Model\Core\AnchorObjectInterface; use bunq\Model\Core\BunqModel; /** * @generated */ -class ChatMessageContent extends BunqModel +class ChatMessageContent extends BunqModel implements AnchorObjectInterface { /** * Error constants. diff --git a/src/Model/Generated/Object/DraftPaymentAnchorObject.php b/src/Model/Generated/Object/DraftPaymentAnchorObject.php index d0c19eca..d3265400 100644 --- a/src/Model/Generated/Object/DraftPaymentAnchorObject.php +++ b/src/Model/Generated/Object/DraftPaymentAnchorObject.php @@ -2,6 +2,7 @@ namespace bunq\Model\Generated\Object; use bunq\exception\BunqException; +use bunq\Model\Core\AnchorObjectInterface; use bunq\Model\Core\BunqModel; use bunq\Model\Generated\Endpoint\Payment; use bunq\Model\Generated\Endpoint\PaymentBatch; @@ -9,7 +10,7 @@ /** * @generated */ -class DraftPaymentAnchorObject extends BunqModel +class DraftPaymentAnchorObject extends BunqModel implements AnchorObjectInterface { /** * Error constants. diff --git a/src/Model/Generated/Object/NotificationAnchorObject.php b/src/Model/Generated/Object/NotificationAnchorObject.php index bddd00fe..2f91da5f 100644 --- a/src/Model/Generated/Object/NotificationAnchorObject.php +++ b/src/Model/Generated/Object/NotificationAnchorObject.php @@ -28,7 +28,7 @@ /** * @generated */ -class NotificationAnchorObject extends BunqModel +class NotificationAnchorObject extends BunqModel implements AnchorObjectInterface { /** * Error constants. diff --git a/src/Model/Generated/Object/ScheduleAnchorObject.php b/src/Model/Generated/Object/ScheduleAnchorObject.php index 03bb1807..9f4f4621 100644 --- a/src/Model/Generated/Object/ScheduleAnchorObject.php +++ b/src/Model/Generated/Object/ScheduleAnchorObject.php @@ -2,6 +2,7 @@ namespace bunq\Model\Generated\Object; use bunq\exception\BunqException; +use bunq\Model\Core\AnchorObjectInterface; use bunq\Model\Core\BunqModel; use bunq\Model\Generated\Endpoint\Payment; use bunq\Model\Generated\Endpoint\PaymentBatch; @@ -9,7 +10,7 @@ /** * @generated */ -class ScheduleAnchorObject extends BunqModel +class ScheduleAnchorObject extends BunqModel implements AnchorObjectInterface { /** * Error constants. diff --git a/src/Model/Generated/Object/ScheduleInstanceAnchorObject.php b/src/Model/Generated/Object/ScheduleInstanceAnchorObject.php index 33967692..0ece6079 100644 --- a/src/Model/Generated/Object/ScheduleInstanceAnchorObject.php +++ b/src/Model/Generated/Object/ScheduleInstanceAnchorObject.php @@ -2,6 +2,7 @@ namespace bunq\Model\Generated\Object; use bunq\exception\BunqException; +use bunq\Model\Core\AnchorObjectInterface; use bunq\Model\Core\BunqModel; use bunq\Model\Generated\Endpoint\Payment; use bunq\Model\Generated\Endpoint\PaymentBatch; @@ -9,7 +10,7 @@ /** * @generated */ -class ScheduleInstanceAnchorObject extends BunqModel +class ScheduleInstanceAnchorObject extends BunqModel implements AnchorObjectInterface { /** * Error constants. From f532ac81ec8360cde4c487e1393f1758625c3c85 Mon Sep 17 00:00:00 2001 From: Kevin Hellemun Date: Wed, 20 Dec 2017 16:07:27 +0100 Subject: [PATCH 19/27] Regenerated code. (bunq/sdk_php#68) --- .../AttachmentConversationContent.php | 2 +- .../Endpoint/AttachmentMonetaryAccount.php | 2 +- .../Generated/Endpoint/AttachmentPublic.php | 2 +- .../Endpoint/AttachmentPublicContent.php | 2 +- .../Generated/Endpoint/AttachmentTab.php | 2 +- .../Endpoint/AttachmentTabContent.php | 2 +- src/Model/Generated/Endpoint/Avatar.php | 2 +- .../Endpoint/BillingContractSubscription.php | 2 +- .../Endpoint/BunqMeFundraiserProfile.php | 244 ++++++++++++++++++ .../Endpoint/BunqMeFundraiserResult.php | 170 ++++++++++++ src/Model/Generated/Endpoint/BunqMeTab.php | 2 +- .../Generated/Endpoint/BunqMeTabEntry.php | 2 +- .../Endpoint/BunqMeTabResultInquiry.php | 2 +- .../Endpoint/BunqMeTabResultResponse.php | 2 +- src/Model/Generated/Endpoint/Card.php | 2 +- src/Model/Generated/Endpoint/CardDebit.php | 2 +- .../Generated/Endpoint/CardGeneratedCvc2.php | 2 +- src/Model/Generated/Endpoint/CardName.php | 2 +- .../Generated/Endpoint/CardPinChange.php | 2 +- src/Model/Generated/Endpoint/CardReplace.php | 2 +- src/Model/Generated/Endpoint/CardResult.php | 2 +- src/Model/Generated/Endpoint/CashRegister.php | 2 +- .../Generated/Endpoint/CashRegisterQrCode.php | 2 +- .../Endpoint/CashRegisterQrCodeContent.php | 2 +- .../Generated/Endpoint/CertificatePinned.php | 2 +- .../Generated/Endpoint/ChatConversation.php | 2 +- .../Endpoint/ChatConversationReference.php | 2 +- .../ChatConversationSupportExternal.php | 2 +- src/Model/Generated/Endpoint/ChatMessage.php | 2 +- .../Endpoint/ChatMessageAnnouncement.php | 2 +- .../Endpoint/ChatMessageAttachment.php | 2 +- .../Generated/Endpoint/ChatMessageStatus.php | 2 +- .../Generated/Endpoint/ChatMessageText.php | 2 +- .../Generated/Endpoint/ChatMessageUser.php | 2 +- src/Model/Generated/Endpoint/Customer.php | 2 +- .../Generated/Endpoint/CustomerLimit.php | 2 +- .../Endpoint/CustomerStatementExport.php | 2 +- .../CustomerStatementExportContent.php | 2 +- src/Model/Generated/Endpoint/Device.php | 2 +- src/Model/Generated/Endpoint/DeviceServer.php | 2 +- src/Model/Generated/Endpoint/DraftPayment.php | 2 +- .../Endpoint/DraftShareInviteBank.php | 2 +- .../DraftShareInviteBankQrCodeContent.php | 2 +- .../Endpoint/ExportAnnualOverview.php | 2 +- .../Endpoint/ExportAnnualOverviewContent.php | 2 +- .../Endpoint/IdealMerchantTransaction.php | 2 +- .../Endpoint/InstallationServerPublicKey.php | 2 +- src/Model/Generated/Endpoint/Invoice.php | 2 +- .../Generated/Endpoint/InvoiceByUser.php | 2 +- .../Generated/Endpoint/MasterCardAction.php | 2 +- .../Generated/Endpoint/MonetaryAccount.php | 2 +- .../Endpoint/MonetaryAccountBank.php | 2 +- .../Endpoint/MonetaryAccountProfile.php | 2 +- src/Model/Generated/Endpoint/Payment.php | 2 +- src/Model/Generated/Endpoint/PaymentBatch.php | 2 +- src/Model/Generated/Endpoint/PaymentChat.php | 2 +- src/Model/Generated/Endpoint/PermittedIp.php | 2 +- .../Generated/Endpoint/PromotionDisplay.php | 2 +- .../Generated/Endpoint/RequestInquiry.php | 2 +- .../Endpoint/RequestInquiryBatch.php | 2 +- .../Generated/Endpoint/RequestInquiryChat.php | 2 +- .../Generated/Endpoint/RequestResponse.php | 2 +- .../Endpoint/RequestResponseChat.php | 2 +- src/Model/Generated/Endpoint/Schedule.php | 2 +- .../Generated/Endpoint/ScheduleInstance.php | 2 +- .../Generated/Endpoint/SchedulePayment.php | 2 +- .../Endpoint/SchedulePaymentBatch.php | 2 +- src/Model/Generated/Endpoint/ScheduleUser.php | 2 +- src/Model/Generated/Endpoint/Session.php | 2 +- .../Endpoint/ShareInviteBankAmountUsed.php | 2 +- .../Endpoint/ShareInviteBankInquiry.php | 2 +- .../Endpoint/ShareInviteBankResponse.php | 2 +- src/Model/Generated/Endpoint/Tab.php | 2 +- .../Generated/Endpoint/TabAttachmentTab.php | 2 +- .../Endpoint/TabAttachmentTabContent.php | 2 +- src/Model/Generated/Endpoint/TabItem.php | 2 +- src/Model/Generated/Endpoint/TabItemShop.php | 2 +- .../Generated/Endpoint/TabItemShopBatch.php | 2 +- .../Generated/Endpoint/TabQrCodeContent.php | 2 +- .../Generated/Endpoint/TabResultInquiry.php | 2 +- .../Generated/Endpoint/TabResultResponse.php | 2 +- .../Generated/Endpoint/TabUsageMultiple.php | 2 +- .../Generated/Endpoint/TabUsageSingle.php | 2 +- .../Endpoint/TokenQrRequestIdeal.php | 2 +- src/Model/Generated/Endpoint/User.php | 2 +- src/Model/Generated/Endpoint/UserCompany.php | 2 +- .../Endpoint/UserCredentialPasswordIp.php | 2 +- src/Model/Generated/Endpoint/UserLight.php | 2 +- src/Model/Generated/Endpoint/UserPerson.php | 2 +- src/Model/Generated/Object/Address.php | 2 +- src/Model/Generated/Object/Amount.php | 2 +- src/Model/Generated/Object/AnchoredObject.php | 2 +- src/Model/Generated/Object/Attachment.php | 2 +- .../AttachmentMonetaryAccountPayment.php | 2 +- .../Generated/Object/AttachmentPublic.php | 2 +- src/Model/Generated/Object/AttachmentTab.php | 2 +- src/Model/Generated/Object/Avatar.php | 2 +- .../Generated/Object/BudgetRestriction.php | 2 +- src/Model/Generated/Object/BunqId.php | 2 +- .../Object/BunqMeMerchantAvailable.php | 2 +- .../Object/CardCountryPermission.php | 2 +- src/Model/Generated/Object/CardLimit.php | 2 +- .../Object/CardMagStripePermission.php | 2 +- .../Generated/Object/CardPinAssignment.php | 2 +- src/Model/Generated/Object/Certificate.php | 2 +- .../Generated/Object/ChatMessageContent.php | 2 +- .../Object/ChatMessageContentAnchorEvent.php | 2 +- .../Object/ChatMessageContentAttachment.php | 2 +- .../Object/ChatMessageContentGeolocation.php | 2 +- .../ChatMessageContentStatusConversation.php | 2 +- ...tMessageContentStatusConversationTitle.php | 2 +- .../ChatMessageContentStatusMembership.php | 2 +- .../Object/ChatMessageContentText.php | 2 +- .../Object/DraftPaymentAnchorObject.php | 2 +- .../Generated/Object/DraftPaymentEntry.php | 2 +- .../Generated/Object/DraftPaymentResponse.php | 2 +- .../Object/DraftShareInviteBankEntry.php | 2 +- src/Model/Generated/Object/Error.php | 2 +- src/Model/Generated/Object/Geolocation.php | 2 +- src/Model/Generated/Object/Image.php | 2 +- src/Model/Generated/Object/InvoiceItem.php | 2 +- .../Generated/Object/InvoiceItemGroup.php | 2 +- src/Model/Generated/Object/Issuer.php | 2 +- src/Model/Generated/Object/LabelCard.php | 2 +- .../Generated/Object/LabelMonetaryAccount.php | 2 +- src/Model/Generated/Object/LabelUser.php | 2 +- .../Object/MonetaryAccountProfileDrain.php | 2 +- .../Object/MonetaryAccountProfileFill.php | 2 +- .../Object/MonetaryAccountSetting.php | 2 +- .../Object/NotificationAnchorObject.php | 30 ++- .../Generated/Object/NotificationFilter.php | 2 +- .../Generated/Object/NotificationUrl.php | 2 +- .../Generated/Object/PermittedDevice.php | 2 +- src/Model/Generated/Object/Pointer.php | 2 +- .../Generated/Object/ScheduleAnchorObject.php | 2 +- .../Object/ScheduleInstanceAnchorObject.php | 2 +- .../Generated/Object/SchedulePaymentEntry.php | 2 +- src/Model/Generated/Object/ShareDetail.php | 2 +- .../Object/ShareDetailDraftPayment.php | 2 +- .../Generated/Object/ShareDetailPayment.php | 2 +- .../Generated/Object/ShareDetailReadOnly.php | 2 +- .../Generated/Object/TabTextWaitingScreen.php | 2 +- src/Model/Generated/Object/TabVisibility.php | 2 +- src/Model/Generated/Object/TaxResident.php | 2 +- src/Model/Generated/Object/Ubo.php | 2 +- 145 files changed, 585 insertions(+), 143 deletions(-) create mode 100644 src/Model/Generated/Endpoint/BunqMeFundraiserProfile.php create mode 100644 src/Model/Generated/Endpoint/BunqMeFundraiserResult.php diff --git a/src/Model/Generated/Endpoint/AttachmentConversationContent.php b/src/Model/Generated/Endpoint/AttachmentConversationContent.php index 5734df5d..a7f5c19d 100644 --- a/src/Model/Generated/Endpoint/AttachmentConversationContent.php +++ b/src/Model/Generated/Endpoint/AttachmentConversationContent.php @@ -58,7 +58,7 @@ public static function listing(ApiContext $apiContext, int $userId, int $chatCon /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { return true; } diff --git a/src/Model/Generated/Endpoint/AttachmentMonetaryAccount.php b/src/Model/Generated/Endpoint/AttachmentMonetaryAccount.php index a6cf2d07..96a2c10d 100644 --- a/src/Model/Generated/Endpoint/AttachmentMonetaryAccount.php +++ b/src/Model/Generated/Endpoint/AttachmentMonetaryAccount.php @@ -119,7 +119,7 @@ public function setId($id) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->attachment)) { return false; diff --git a/src/Model/Generated/Endpoint/AttachmentPublic.php b/src/Model/Generated/Endpoint/AttachmentPublic.php index 7aadf01a..3239cb8f 100644 --- a/src/Model/Generated/Endpoint/AttachmentPublic.php +++ b/src/Model/Generated/Endpoint/AttachmentPublic.php @@ -196,7 +196,7 @@ public function setAttachment($attachment) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->uuid)) { return false; diff --git a/src/Model/Generated/Endpoint/AttachmentPublicContent.php b/src/Model/Generated/Endpoint/AttachmentPublicContent.php index 1e5d94b5..e810c5ef 100644 --- a/src/Model/Generated/Endpoint/AttachmentPublicContent.php +++ b/src/Model/Generated/Endpoint/AttachmentPublicContent.php @@ -57,7 +57,7 @@ public static function listing(ApiContext $apiContext, string $attachmentPublicU /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { return true; } diff --git a/src/Model/Generated/Endpoint/AttachmentTab.php b/src/Model/Generated/Endpoint/AttachmentTab.php index e850a763..4a1373ed 100644 --- a/src/Model/Generated/Endpoint/AttachmentTab.php +++ b/src/Model/Generated/Endpoint/AttachmentTab.php @@ -200,7 +200,7 @@ public function setAttachment($attachment) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->id)) { return false; diff --git a/src/Model/Generated/Endpoint/AttachmentTabContent.php b/src/Model/Generated/Endpoint/AttachmentTabContent.php index 94b3f6a5..9fc20684 100644 --- a/src/Model/Generated/Endpoint/AttachmentTabContent.php +++ b/src/Model/Generated/Endpoint/AttachmentTabContent.php @@ -58,7 +58,7 @@ public static function listing(ApiContext $apiContext, int $userId, int $monetar /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { return true; } diff --git a/src/Model/Generated/Endpoint/Avatar.php b/src/Model/Generated/Endpoint/Avatar.php index 619d7f6b..668c188b 100644 --- a/src/Model/Generated/Endpoint/Avatar.php +++ b/src/Model/Generated/Endpoint/Avatar.php @@ -137,7 +137,7 @@ public function setImage($image) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->uuid)) { return false; diff --git a/src/Model/Generated/Endpoint/BillingContractSubscription.php b/src/Model/Generated/Endpoint/BillingContractSubscription.php index b3b20259..342b6ca3 100644 --- a/src/Model/Generated/Endpoint/BillingContractSubscription.php +++ b/src/Model/Generated/Endpoint/BillingContractSubscription.php @@ -266,7 +266,7 @@ public function setSubscriptionType($subscriptionType) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->id)) { return false; diff --git a/src/Model/Generated/Endpoint/BunqMeFundraiserProfile.php b/src/Model/Generated/Endpoint/BunqMeFundraiserProfile.php new file mode 100644 index 00000000..3961d8de --- /dev/null +++ b/src/Model/Generated/Endpoint/BunqMeFundraiserProfile.php @@ -0,0 +1,244 @@ +color; + } + + /** + * @param string $color + */ + public function setColor($color) + { + $this->color = $color; + } + + /** + * The LabelMonetaryAccount with the public information of the User and the + * MonetaryAccount that created the bunq.me fundraiser profile. + * + * @return LabelMonetaryAccount + */ + public function getAlias() + { + return $this->alias; + } + + /** + * @param LabelMonetaryAccount $alias + */ + public function setAlias($alias) + { + $this->alias = $alias; + } + + /** + * The description of the bunq.me fundraiser profile. + * + * @return string + */ + public function getDescription() + { + return $this->description; + } + + /** + * @param string $description + */ + public function setDescription($description) + { + $this->description = $description; + } + + /** + * The attachments attached to the fundraiser profile. + * + * @return AttachmentPublic[] + */ + public function getAttachment() + { + return $this->attachment; + } + + /** + * @param AttachmentPublic[] $attachment + */ + public function setAttachment($attachment) + { + $this->attachment = $attachment; + } + + /** + * The pointer (url) which will be used to access the bunq.me fundraiser + * profile. + * + * @return Pointer + */ + public function getPointer() + { + return $this->pointer; + } + + /** + * @param Pointer $pointer + */ + public function setPointer($pointer) + { + $this->pointer = $pointer; + } + + /** + * The status of the bunq.me fundraiser profile, can be ACTIVE or + * DEACTIVATED. + * + * @return string + */ + public function getStatus() + { + return $this->status; + } + + /** + * @param string $status + */ + public function setStatus($status) + { + $this->status = $status; + } + + /** + * The URL which the user is sent to when a payment is completed. + * + * @return string + */ + public function getRedirectUrl() + { + return $this->redirectUrl; + } + + /** + * @param string $redirectUrl + */ + public function setRedirectUrl($redirectUrl) + { + $this->redirectUrl = $redirectUrl; + } + + /** + * @return bool + */ + public function isAllFieldNull() + { + if (!is_null($this->color)) { + return false; + } + + if (!is_null($this->alias)) { + return false; + } + + if (!is_null($this->description)) { + return false; + } + + if (!is_null($this->attachment)) { + return false; + } + + if (!is_null($this->pointer)) { + return false; + } + + if (!is_null($this->status)) { + return false; + } + + if (!is_null($this->redirectUrl)) { + return false; + } + + return true; + } +} diff --git a/src/Model/Generated/Endpoint/BunqMeFundraiserResult.php b/src/Model/Generated/Endpoint/BunqMeFundraiserResult.php new file mode 100644 index 00000000..e6796b31 --- /dev/null +++ b/src/Model/Generated/Endpoint/BunqMeFundraiserResult.php @@ -0,0 +1,170 @@ +id; + } + + /** + * @param int $id + */ + public function setId($id) + { + $this->id = $id; + } + + /** + * The timestamp when the bunq.me was created. + * + * @return string + */ + public function getCreated() + { + return $this->created; + } + + /** + * @param string $created + */ + public function setCreated($created) + { + $this->created = $created; + } + + /** + * The timestamp when the bunq.me was last updated. + * + * @return string + */ + public function getUpdated() + { + return $this->updated; + } + + /** + * @param string $updated + */ + public function setUpdated($updated) + { + $this->updated = $updated; + } + + /** + * The bunq.me fundraiser profile. + * + * @return BunqMeFundraiserProfile + */ + public function getBunqmeFundraiserProfile() + { + return $this->bunqmeFundraiserProfile; + } + + /** + * @param BunqMeFundraiserProfile $bunqmeFundraiserProfile + */ + public function setBunqmeFundraiserProfile($bunqmeFundraiserProfile) + { + $this->bunqmeFundraiserProfile = $bunqmeFundraiserProfile; + } + + /** + * The list of payments, paid to the bunq.me fundraiser profile. + * + * @return Payment[] + */ + public function getPayments() + { + return $this->payments; + } + + /** + * @param Payment[] $payments + */ + public function setPayments($payments) + { + $this->payments = $payments; + } + + /** + * @return bool + */ + public function isAllFieldNull() + { + if (!is_null($this->id)) { + return false; + } + + if (!is_null($this->created)) { + return false; + } + + if (!is_null($this->updated)) { + return false; + } + + if (!is_null($this->bunqmeFundraiserProfile)) { + return false; + } + + if (!is_null($this->payments)) { + return false; + } + + return true; + } +} diff --git a/src/Model/Generated/Endpoint/BunqMeTab.php b/src/Model/Generated/Endpoint/BunqMeTab.php index 973ee46e..61532f1a 100644 --- a/src/Model/Generated/Endpoint/BunqMeTab.php +++ b/src/Model/Generated/Endpoint/BunqMeTab.php @@ -372,7 +372,7 @@ public function setResultInquiries($resultInquiries) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->id)) { return false; diff --git a/src/Model/Generated/Endpoint/BunqMeTabEntry.php b/src/Model/Generated/Endpoint/BunqMeTabEntry.php index 04fa5294..2fac81d2 100644 --- a/src/Model/Generated/Endpoint/BunqMeTabEntry.php +++ b/src/Model/Generated/Endpoint/BunqMeTabEntry.php @@ -209,7 +209,7 @@ public function setMerchantAvailable($merchantAvailable) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->uuid)) { return false; diff --git a/src/Model/Generated/Endpoint/BunqMeTabResultInquiry.php b/src/Model/Generated/Endpoint/BunqMeTabResultInquiry.php index 51cad454..8f152b77 100644 --- a/src/Model/Generated/Endpoint/BunqMeTabResultInquiry.php +++ b/src/Model/Generated/Endpoint/BunqMeTabResultInquiry.php @@ -45,7 +45,7 @@ public function setPayment($payment) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->payment)) { return false; diff --git a/src/Model/Generated/Endpoint/BunqMeTabResultResponse.php b/src/Model/Generated/Endpoint/BunqMeTabResultResponse.php index 52ee40dd..053e7b27 100644 --- a/src/Model/Generated/Endpoint/BunqMeTabResultResponse.php +++ b/src/Model/Generated/Endpoint/BunqMeTabResultResponse.php @@ -45,7 +45,7 @@ public function setPayment($payment) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->payment)) { return false; diff --git a/src/Model/Generated/Endpoint/Card.php b/src/Model/Generated/Endpoint/Card.php index 315699f1..133c363c 100644 --- a/src/Model/Generated/Endpoint/Card.php +++ b/src/Model/Generated/Endpoint/Card.php @@ -678,7 +678,7 @@ public function setCountry($country) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->id)) { return false; diff --git a/src/Model/Generated/Endpoint/CardDebit.php b/src/Model/Generated/Endpoint/CardDebit.php index dd09ce0a..22a74521 100644 --- a/src/Model/Generated/Endpoint/CardDebit.php +++ b/src/Model/Generated/Endpoint/CardDebit.php @@ -587,7 +587,7 @@ public function setCountry($country) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->id)) { return false; diff --git a/src/Model/Generated/Endpoint/CardGeneratedCvc2.php b/src/Model/Generated/Endpoint/CardGeneratedCvc2.php index fd697d80..c6b72dce 100644 --- a/src/Model/Generated/Endpoint/CardGeneratedCvc2.php +++ b/src/Model/Generated/Endpoint/CardGeneratedCvc2.php @@ -266,7 +266,7 @@ public function setExpiryTime($expiryTime) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->id)) { return false; diff --git a/src/Model/Generated/Endpoint/CardName.php b/src/Model/Generated/Endpoint/CardName.php index 663dbea3..f342e8b5 100644 --- a/src/Model/Generated/Endpoint/CardName.php +++ b/src/Model/Generated/Endpoint/CardName.php @@ -86,7 +86,7 @@ public function setPossibleCardNameArray($possibleCardNameArray) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->possibleCardNameArray)) { return false; diff --git a/src/Model/Generated/Endpoint/CardPinChange.php b/src/Model/Generated/Endpoint/CardPinChange.php index d545e217..0a19b094 100644 --- a/src/Model/Generated/Endpoint/CardPinChange.php +++ b/src/Model/Generated/Endpoint/CardPinChange.php @@ -238,7 +238,7 @@ public function setStatus($status) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->id)) { return false; diff --git a/src/Model/Generated/Endpoint/CardReplace.php b/src/Model/Generated/Endpoint/CardReplace.php index 59be2903..05f63477 100644 --- a/src/Model/Generated/Endpoint/CardReplace.php +++ b/src/Model/Generated/Endpoint/CardReplace.php @@ -91,7 +91,7 @@ public function setId($id) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->id)) { return false; diff --git a/src/Model/Generated/Endpoint/CardResult.php b/src/Model/Generated/Endpoint/CardResult.php index bc3dbb6e..67ac8ff1 100644 --- a/src/Model/Generated/Endpoint/CardResult.php +++ b/src/Model/Generated/Endpoint/CardResult.php @@ -489,7 +489,7 @@ public function setReservationExpiryTime($reservationExpiryTime) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->monetaryAccountId)) { return false; diff --git a/src/Model/Generated/Endpoint/CashRegister.php b/src/Model/Generated/Endpoint/CashRegister.php index 1e1ef406..10109ba6 100644 --- a/src/Model/Generated/Endpoint/CashRegister.php +++ b/src/Model/Generated/Endpoint/CashRegister.php @@ -401,7 +401,7 @@ public function setTabTextWaitingScreen($tabTextWaitingScreen) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->id)) { return false; diff --git a/src/Model/Generated/Endpoint/CashRegisterQrCode.php b/src/Model/Generated/Endpoint/CashRegisterQrCode.php index a1e42cb0..01b07b3b 100644 --- a/src/Model/Generated/Endpoint/CashRegisterQrCode.php +++ b/src/Model/Generated/Endpoint/CashRegisterQrCode.php @@ -316,7 +316,7 @@ public function setTabObject($tabObject) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->id)) { return false; diff --git a/src/Model/Generated/Endpoint/CashRegisterQrCodeContent.php b/src/Model/Generated/Endpoint/CashRegisterQrCodeContent.php index dac4013a..44668124 100644 --- a/src/Model/Generated/Endpoint/CashRegisterQrCodeContent.php +++ b/src/Model/Generated/Endpoint/CashRegisterQrCodeContent.php @@ -59,7 +59,7 @@ public static function listing(ApiContext $apiContext, int $userId, int $monetar /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { return true; } diff --git a/src/Model/Generated/Endpoint/CertificatePinned.php b/src/Model/Generated/Endpoint/CertificatePinned.php index 8c1a9eaa..a68f02cf 100644 --- a/src/Model/Generated/Endpoint/CertificatePinned.php +++ b/src/Model/Generated/Endpoint/CertificatePinned.php @@ -198,7 +198,7 @@ public function setId($id) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->certificateChain)) { return false; diff --git a/src/Model/Generated/Endpoint/ChatConversation.php b/src/Model/Generated/Endpoint/ChatConversation.php index f06bc480..f61455a1 100644 --- a/src/Model/Generated/Endpoint/ChatConversation.php +++ b/src/Model/Generated/Endpoint/ChatConversation.php @@ -146,7 +146,7 @@ public function getReferencedObject() /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->supportConversationExternal)) { return false; diff --git a/src/Model/Generated/Endpoint/ChatConversationReference.php b/src/Model/Generated/Endpoint/ChatConversationReference.php index 1bd7fe89..b28e8ac1 100644 --- a/src/Model/Generated/Endpoint/ChatConversationReference.php +++ b/src/Model/Generated/Endpoint/ChatConversationReference.php @@ -93,7 +93,7 @@ public function setUpdated($updated) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->id)) { return false; diff --git a/src/Model/Generated/Endpoint/ChatConversationSupportExternal.php b/src/Model/Generated/Endpoint/ChatConversationSupportExternal.php index 5ebe108d..cd392d8e 100644 --- a/src/Model/Generated/Endpoint/ChatConversationSupportExternal.php +++ b/src/Model/Generated/Endpoint/ChatConversationSupportExternal.php @@ -118,7 +118,7 @@ public function setLastMessage($lastMessage) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->id)) { return false; diff --git a/src/Model/Generated/Endpoint/ChatMessage.php b/src/Model/Generated/Endpoint/ChatMessage.php index 579b5ab1..dd3a04f4 100644 --- a/src/Model/Generated/Endpoint/ChatMessage.php +++ b/src/Model/Generated/Endpoint/ChatMessage.php @@ -148,7 +148,7 @@ public function getReferencedObject() /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->chatMessageAnnouncement)) { return false; diff --git a/src/Model/Generated/Endpoint/ChatMessageAnnouncement.php b/src/Model/Generated/Endpoint/ChatMessageAnnouncement.php index a5b2af92..0e56fabf 100644 --- a/src/Model/Generated/Endpoint/ChatMessageAnnouncement.php +++ b/src/Model/Generated/Endpoint/ChatMessageAnnouncement.php @@ -170,7 +170,7 @@ public function setContent($content) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->id)) { return false; diff --git a/src/Model/Generated/Endpoint/ChatMessageAttachment.php b/src/Model/Generated/Endpoint/ChatMessageAttachment.php index 140784ab..ef1da508 100644 --- a/src/Model/Generated/Endpoint/ChatMessageAttachment.php +++ b/src/Model/Generated/Endpoint/ChatMessageAttachment.php @@ -86,7 +86,7 @@ public function setId($id) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->id)) { return false; diff --git a/src/Model/Generated/Endpoint/ChatMessageStatus.php b/src/Model/Generated/Endpoint/ChatMessageStatus.php index a2e9ef23..1b58e381 100644 --- a/src/Model/Generated/Endpoint/ChatMessageStatus.php +++ b/src/Model/Generated/Endpoint/ChatMessageStatus.php @@ -170,7 +170,7 @@ public function setContent($content) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->id)) { return false; diff --git a/src/Model/Generated/Endpoint/ChatMessageText.php b/src/Model/Generated/Endpoint/ChatMessageText.php index 2b068bc1..5c06fb6a 100644 --- a/src/Model/Generated/Endpoint/ChatMessageText.php +++ b/src/Model/Generated/Endpoint/ChatMessageText.php @@ -85,7 +85,7 @@ public function setId($id) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->id)) { return false; diff --git a/src/Model/Generated/Endpoint/ChatMessageUser.php b/src/Model/Generated/Endpoint/ChatMessageUser.php index 1876b04c..d77441e1 100644 --- a/src/Model/Generated/Endpoint/ChatMessageUser.php +++ b/src/Model/Generated/Endpoint/ChatMessageUser.php @@ -195,7 +195,7 @@ public function setContent($content) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->id)) { return false; diff --git a/src/Model/Generated/Endpoint/Customer.php b/src/Model/Generated/Endpoint/Customer.php index bee3f6a8..4f25d881 100644 --- a/src/Model/Generated/Endpoint/Customer.php +++ b/src/Model/Generated/Endpoint/Customer.php @@ -212,7 +212,7 @@ public function setBillingAccountId($billingAccountId) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->id)) { return false; diff --git a/src/Model/Generated/Endpoint/CustomerLimit.php b/src/Model/Generated/Endpoint/CustomerLimit.php index a3ca3f13..1c5c6303 100644 --- a/src/Model/Generated/Endpoint/CustomerLimit.php +++ b/src/Model/Generated/Endpoint/CustomerLimit.php @@ -181,7 +181,7 @@ public function setLimitCardDebitReplacement($limitCardDebitReplacement) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->limitMonetaryAccount)) { return false; diff --git a/src/Model/Generated/Endpoint/CustomerStatementExport.php b/src/Model/Generated/Endpoint/CustomerStatementExport.php index 5c9e8295..8279fa9f 100644 --- a/src/Model/Generated/Endpoint/CustomerStatementExport.php +++ b/src/Model/Generated/Endpoint/CustomerStatementExport.php @@ -395,7 +395,7 @@ public function setAliasMonetaryAccount($aliasMonetaryAccount) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->id)) { return false; diff --git a/src/Model/Generated/Endpoint/CustomerStatementExportContent.php b/src/Model/Generated/Endpoint/CustomerStatementExportContent.php index 4a29b5a2..9e849581 100644 --- a/src/Model/Generated/Endpoint/CustomerStatementExportContent.php +++ b/src/Model/Generated/Endpoint/CustomerStatementExportContent.php @@ -58,7 +58,7 @@ public static function listing(ApiContext $apiContext, int $userId, int $monetar /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { return true; } diff --git a/src/Model/Generated/Endpoint/Device.php b/src/Model/Generated/Endpoint/Device.php index 1c6e2e01..8ff92e5f 100644 --- a/src/Model/Generated/Endpoint/Device.php +++ b/src/Model/Generated/Endpoint/Device.php @@ -125,7 +125,7 @@ public function getReferencedObject() /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->deviceServer)) { return false; diff --git a/src/Model/Generated/Endpoint/DeviceServer.php b/src/Model/Generated/Endpoint/DeviceServer.php index 4b2c56c6..3d9c12dc 100644 --- a/src/Model/Generated/Endpoint/DeviceServer.php +++ b/src/Model/Generated/Endpoint/DeviceServer.php @@ -276,7 +276,7 @@ public function setStatus($status) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->id)) { return false; diff --git a/src/Model/Generated/Endpoint/DraftPayment.php b/src/Model/Generated/Endpoint/DraftPayment.php index 94effb7e..9d06550c 100644 --- a/src/Model/Generated/Endpoint/DraftPayment.php +++ b/src/Model/Generated/Endpoint/DraftPayment.php @@ -360,7 +360,7 @@ public function setObject($object) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->id)) { return false; diff --git a/src/Model/Generated/Endpoint/DraftShareInviteBank.php b/src/Model/Generated/Endpoint/DraftShareInviteBank.php index 4b9bcbea..6df5a1e7 100644 --- a/src/Model/Generated/Endpoint/DraftShareInviteBank.php +++ b/src/Model/Generated/Endpoint/DraftShareInviteBank.php @@ -327,7 +327,7 @@ public function setId($id) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->userAliasCreated)) { return false; diff --git a/src/Model/Generated/Endpoint/DraftShareInviteBankQrCodeContent.php b/src/Model/Generated/Endpoint/DraftShareInviteBankQrCodeContent.php index 9a46a789..d4c1df62 100644 --- a/src/Model/Generated/Endpoint/DraftShareInviteBankQrCodeContent.php +++ b/src/Model/Generated/Endpoint/DraftShareInviteBankQrCodeContent.php @@ -60,7 +60,7 @@ public static function listing(ApiContext $apiContext, int $userId, int $draftSh /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { return true; } diff --git a/src/Model/Generated/Endpoint/ExportAnnualOverview.php b/src/Model/Generated/Endpoint/ExportAnnualOverview.php index de6eda8e..8252d3c7 100644 --- a/src/Model/Generated/Endpoint/ExportAnnualOverview.php +++ b/src/Model/Generated/Endpoint/ExportAnnualOverview.php @@ -246,7 +246,7 @@ public function setAliasUser($aliasUser) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->id)) { return false; diff --git a/src/Model/Generated/Endpoint/ExportAnnualOverviewContent.php b/src/Model/Generated/Endpoint/ExportAnnualOverviewContent.php index 406aa4b5..d3aa9491 100644 --- a/src/Model/Generated/Endpoint/ExportAnnualOverviewContent.php +++ b/src/Model/Generated/Endpoint/ExportAnnualOverviewContent.php @@ -58,7 +58,7 @@ public static function listing(ApiContext $apiContext, int $userId, int $exportA /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { return true; } diff --git a/src/Model/Generated/Endpoint/IdealMerchantTransaction.php b/src/Model/Generated/Endpoint/IdealMerchantTransaction.php index 37dab98d..a7f58ae2 100644 --- a/src/Model/Generated/Endpoint/IdealMerchantTransaction.php +++ b/src/Model/Generated/Endpoint/IdealMerchantTransaction.php @@ -469,7 +469,7 @@ public function setAllowChat($allowChat) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->monetaryAccountId)) { return false; diff --git a/src/Model/Generated/Endpoint/InstallationServerPublicKey.php b/src/Model/Generated/Endpoint/InstallationServerPublicKey.php index ffa410dd..ec77d621 100644 --- a/src/Model/Generated/Endpoint/InstallationServerPublicKey.php +++ b/src/Model/Generated/Endpoint/InstallationServerPublicKey.php @@ -83,7 +83,7 @@ public function setServerPublicKey($serverPublicKey) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->serverPublicKey)) { return false; diff --git a/src/Model/Generated/Endpoint/Invoice.php b/src/Model/Generated/Endpoint/Invoice.php index ba2cac74..7ab32142 100644 --- a/src/Model/Generated/Endpoint/Invoice.php +++ b/src/Model/Generated/Endpoint/Invoice.php @@ -495,7 +495,7 @@ public function setVatNumber($vatNumber) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->id)) { return false; diff --git a/src/Model/Generated/Endpoint/InvoiceByUser.php b/src/Model/Generated/Endpoint/InvoiceByUser.php index 0182c630..87bb6ab7 100644 --- a/src/Model/Generated/Endpoint/InvoiceByUser.php +++ b/src/Model/Generated/Endpoint/InvoiceByUser.php @@ -486,7 +486,7 @@ public function setVatNumber($vatNumber) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->id)) { return false; diff --git a/src/Model/Generated/Endpoint/MasterCardAction.php b/src/Model/Generated/Endpoint/MasterCardAction.php index 7364e32a..a8efce6e 100644 --- a/src/Model/Generated/Endpoint/MasterCardAction.php +++ b/src/Model/Generated/Endpoint/MasterCardAction.php @@ -670,7 +670,7 @@ public function setEligibleWhitelistId($eligibleWhitelistId) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->monetaryAccountId)) { return false; diff --git a/src/Model/Generated/Endpoint/MonetaryAccount.php b/src/Model/Generated/Endpoint/MonetaryAccount.php index 686bbba0..b0b4f397 100644 --- a/src/Model/Generated/Endpoint/MonetaryAccount.php +++ b/src/Model/Generated/Endpoint/MonetaryAccount.php @@ -129,7 +129,7 @@ public function getReferencedObject() /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->monetaryAccountBank)) { return false; diff --git a/src/Model/Generated/Endpoint/MonetaryAccountBank.php b/src/Model/Generated/Endpoint/MonetaryAccountBank.php index 6f655b05..9a62785f 100644 --- a/src/Model/Generated/Endpoint/MonetaryAccountBank.php +++ b/src/Model/Generated/Endpoint/MonetaryAccountBank.php @@ -689,7 +689,7 @@ public function setSetting($setting) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->id)) { return false; diff --git a/src/Model/Generated/Endpoint/MonetaryAccountProfile.php b/src/Model/Generated/Endpoint/MonetaryAccountProfile.php index 966d0e92..cbdc9eee 100644 --- a/src/Model/Generated/Endpoint/MonetaryAccountProfile.php +++ b/src/Model/Generated/Endpoint/MonetaryAccountProfile.php @@ -77,7 +77,7 @@ public function setProfileDrain($profileDrain) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->profileFill)) { return false; diff --git a/src/Model/Generated/Endpoint/Payment.php b/src/Model/Generated/Endpoint/Payment.php index 346406eb..47891a0f 100644 --- a/src/Model/Generated/Endpoint/Payment.php +++ b/src/Model/Generated/Endpoint/Payment.php @@ -732,7 +732,7 @@ public function setAllowChat($allowChat) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->id)) { return false; diff --git a/src/Model/Generated/Endpoint/PaymentBatch.php b/src/Model/Generated/Endpoint/PaymentBatch.php index d0d06d30..750a97e7 100644 --- a/src/Model/Generated/Endpoint/PaymentBatch.php +++ b/src/Model/Generated/Endpoint/PaymentBatch.php @@ -179,7 +179,7 @@ public function setPayments($payments) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->payments)) { return false; diff --git a/src/Model/Generated/Endpoint/PaymentChat.php b/src/Model/Generated/Endpoint/PaymentChat.php index b19025cf..cfbc9d30 100644 --- a/src/Model/Generated/Endpoint/PaymentChat.php +++ b/src/Model/Generated/Endpoint/PaymentChat.php @@ -224,7 +224,7 @@ public function setUnreadMessageCount($unreadMessageCount) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->id)) { return false; diff --git a/src/Model/Generated/Endpoint/PermittedIp.php b/src/Model/Generated/Endpoint/PermittedIp.php index 9028c99f..dc91b46a 100644 --- a/src/Model/Generated/Endpoint/PermittedIp.php +++ b/src/Model/Generated/Endpoint/PermittedIp.php @@ -198,7 +198,7 @@ public function setStatus($status) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->ip)) { return false; diff --git a/src/Model/Generated/Endpoint/PromotionDisplay.php b/src/Model/Generated/Endpoint/PromotionDisplay.php index 621f5f59..5e0ea07a 100644 --- a/src/Model/Generated/Endpoint/PromotionDisplay.php +++ b/src/Model/Generated/Endpoint/PromotionDisplay.php @@ -185,7 +185,7 @@ public function setStatus($status) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->id)) { return false; diff --git a/src/Model/Generated/Endpoint/RequestInquiry.php b/src/Model/Generated/Endpoint/RequestInquiry.php index 9e8a6358..e0ed4fa7 100644 --- a/src/Model/Generated/Endpoint/RequestInquiry.php +++ b/src/Model/Generated/Endpoint/RequestInquiry.php @@ -812,7 +812,7 @@ public function setAllowChat($allowChat) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->id)) { return false; diff --git a/src/Model/Generated/Endpoint/RequestInquiryBatch.php b/src/Model/Generated/Endpoint/RequestInquiryBatch.php index da6599d6..f5ad5c89 100644 --- a/src/Model/Generated/Endpoint/RequestInquiryBatch.php +++ b/src/Model/Generated/Endpoint/RequestInquiryBatch.php @@ -206,7 +206,7 @@ public function setTotalAmountInquired($totalAmountInquired) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->requestInquiries)) { return false; diff --git a/src/Model/Generated/Endpoint/RequestInquiryChat.php b/src/Model/Generated/Endpoint/RequestInquiryChat.php index f08804f4..f9bd6000 100644 --- a/src/Model/Generated/Endpoint/RequestInquiryChat.php +++ b/src/Model/Generated/Endpoint/RequestInquiryChat.php @@ -228,7 +228,7 @@ public function setUnreadMessageCount($unreadMessageCount) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->id)) { return false; diff --git a/src/Model/Generated/Endpoint/RequestResponse.php b/src/Model/Generated/Endpoint/RequestResponse.php index 9ac3555d..f0f45a50 100644 --- a/src/Model/Generated/Endpoint/RequestResponse.php +++ b/src/Model/Generated/Endpoint/RequestResponse.php @@ -780,7 +780,7 @@ public function setEligibleWhitelistId($eligibleWhitelistId) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->id)) { return false; diff --git a/src/Model/Generated/Endpoint/RequestResponseChat.php b/src/Model/Generated/Endpoint/RequestResponseChat.php index 1093d9e2..98bfb4a2 100644 --- a/src/Model/Generated/Endpoint/RequestResponseChat.php +++ b/src/Model/Generated/Endpoint/RequestResponseChat.php @@ -228,7 +228,7 @@ public function setUnreadMessageCount($unreadMessageCount) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->id)) { return false; diff --git a/src/Model/Generated/Endpoint/Schedule.php b/src/Model/Generated/Endpoint/Schedule.php index d8c33527..78eb4037 100644 --- a/src/Model/Generated/Endpoint/Schedule.php +++ b/src/Model/Generated/Endpoint/Schedule.php @@ -253,7 +253,7 @@ public function setObject($object) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->timeStart)) { return false; diff --git a/src/Model/Generated/Endpoint/ScheduleInstance.php b/src/Model/Generated/Endpoint/ScheduleInstance.php index ac75af8f..48f41204 100644 --- a/src/Model/Generated/Endpoint/ScheduleInstance.php +++ b/src/Model/Generated/Endpoint/ScheduleInstance.php @@ -275,7 +275,7 @@ public function setResultObject($resultObject) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->state)) { return false; diff --git a/src/Model/Generated/Endpoint/SchedulePayment.php b/src/Model/Generated/Endpoint/SchedulePayment.php index bab958e9..59057587 100644 --- a/src/Model/Generated/Endpoint/SchedulePayment.php +++ b/src/Model/Generated/Endpoint/SchedulePayment.php @@ -220,7 +220,7 @@ public function setSchedule($schedule) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->payment)) { return false; diff --git a/src/Model/Generated/Endpoint/SchedulePaymentBatch.php b/src/Model/Generated/Endpoint/SchedulePaymentBatch.php index 3803a5c2..e0116ffb 100644 --- a/src/Model/Generated/Endpoint/SchedulePaymentBatch.php +++ b/src/Model/Generated/Endpoint/SchedulePaymentBatch.php @@ -163,7 +163,7 @@ public function setSchedule($schedule) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->payments)) { return false; diff --git a/src/Model/Generated/Endpoint/ScheduleUser.php b/src/Model/Generated/Endpoint/ScheduleUser.php index 55b45ac1..e40fedfc 100644 --- a/src/Model/Generated/Endpoint/ScheduleUser.php +++ b/src/Model/Generated/Endpoint/ScheduleUser.php @@ -61,7 +61,7 @@ public static function listing(ApiContext $apiContext, int $userId, array $param /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { return true; } diff --git a/src/Model/Generated/Endpoint/Session.php b/src/Model/Generated/Endpoint/Session.php index cbe7f312..034c92ab 100644 --- a/src/Model/Generated/Endpoint/Session.php +++ b/src/Model/Generated/Endpoint/Session.php @@ -51,7 +51,7 @@ public static function delete(ApiContext $apiContext, int $sessionId, array $cus /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { return true; } diff --git a/src/Model/Generated/Endpoint/ShareInviteBankAmountUsed.php b/src/Model/Generated/Endpoint/ShareInviteBankAmountUsed.php index afcecaee..7db9c0cc 100644 --- a/src/Model/Generated/Endpoint/ShareInviteBankAmountUsed.php +++ b/src/Model/Generated/Endpoint/ShareInviteBankAmountUsed.php @@ -59,7 +59,7 @@ public static function delete(ApiContext $apiContext, int $userId, int $monetary /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { return true; } diff --git a/src/Model/Generated/Endpoint/ShareInviteBankInquiry.php b/src/Model/Generated/Endpoint/ShareInviteBankInquiry.php index 993028f7..38405792 100644 --- a/src/Model/Generated/Endpoint/ShareInviteBankInquiry.php +++ b/src/Model/Generated/Endpoint/ShareInviteBankInquiry.php @@ -472,7 +472,7 @@ public function setId($id) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->alias)) { return false; diff --git a/src/Model/Generated/Endpoint/ShareInviteBankResponse.php b/src/Model/Generated/Endpoint/ShareInviteBankResponse.php index 09354ded..449e82e0 100644 --- a/src/Model/Generated/Endpoint/ShareInviteBankResponse.php +++ b/src/Model/Generated/Endpoint/ShareInviteBankResponse.php @@ -383,7 +383,7 @@ public function setDescription($description) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->counterAlias)) { return false; diff --git a/src/Model/Generated/Endpoint/Tab.php b/src/Model/Generated/Endpoint/Tab.php index c57b5f64..5fb37b6a 100644 --- a/src/Model/Generated/Endpoint/Tab.php +++ b/src/Model/Generated/Endpoint/Tab.php @@ -160,7 +160,7 @@ public function getReferencedObject() /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->tabUsageSingle)) { return false; diff --git a/src/Model/Generated/Endpoint/TabAttachmentTab.php b/src/Model/Generated/Endpoint/TabAttachmentTab.php index 2d9acb38..80bad5e1 100644 --- a/src/Model/Generated/Endpoint/TabAttachmentTab.php +++ b/src/Model/Generated/Endpoint/TabAttachmentTab.php @@ -155,7 +155,7 @@ public function setAttachment($attachment) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->id)) { return false; diff --git a/src/Model/Generated/Endpoint/TabAttachmentTabContent.php b/src/Model/Generated/Endpoint/TabAttachmentTabContent.php index 8c8d82a7..b2757137 100644 --- a/src/Model/Generated/Endpoint/TabAttachmentTabContent.php +++ b/src/Model/Generated/Endpoint/TabAttachmentTabContent.php @@ -57,7 +57,7 @@ public static function listing(ApiContext $apiContext, string $tabUuid, int $att /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { return true; } diff --git a/src/Model/Generated/Endpoint/TabItem.php b/src/Model/Generated/Endpoint/TabItem.php index bd5a7304..a0aac48b 100644 --- a/src/Model/Generated/Endpoint/TabItem.php +++ b/src/Model/Generated/Endpoint/TabItem.php @@ -200,7 +200,7 @@ public function setAmount($amount) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->id)) { return false; diff --git a/src/Model/Generated/Endpoint/TabItemShop.php b/src/Model/Generated/Endpoint/TabItemShop.php index deb14aac..45d55f52 100644 --- a/src/Model/Generated/Endpoint/TabItemShop.php +++ b/src/Model/Generated/Endpoint/TabItemShop.php @@ -380,7 +380,7 @@ public function setAmount($amount) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->id)) { return false; diff --git a/src/Model/Generated/Endpoint/TabItemShopBatch.php b/src/Model/Generated/Endpoint/TabItemShopBatch.php index 9f353b42..8c2a3d73 100644 --- a/src/Model/Generated/Endpoint/TabItemShopBatch.php +++ b/src/Model/Generated/Endpoint/TabItemShopBatch.php @@ -86,7 +86,7 @@ public function setTabItems($tabItems) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->tabItems)) { return false; diff --git a/src/Model/Generated/Endpoint/TabQrCodeContent.php b/src/Model/Generated/Endpoint/TabQrCodeContent.php index 1bf99b8d..d9c10648 100644 --- a/src/Model/Generated/Endpoint/TabQrCodeContent.php +++ b/src/Model/Generated/Endpoint/TabQrCodeContent.php @@ -62,7 +62,7 @@ public static function listing(ApiContext $apiContext, int $userId, int $monetar /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { return true; } diff --git a/src/Model/Generated/Endpoint/TabResultInquiry.php b/src/Model/Generated/Endpoint/TabResultInquiry.php index 4aca154e..c02dd3fb 100644 --- a/src/Model/Generated/Endpoint/TabResultInquiry.php +++ b/src/Model/Generated/Endpoint/TabResultInquiry.php @@ -142,7 +142,7 @@ public function setPayment($payment) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->tab)) { return false; diff --git a/src/Model/Generated/Endpoint/TabResultResponse.php b/src/Model/Generated/Endpoint/TabResultResponse.php index f7bd0ab9..2938a023 100644 --- a/src/Model/Generated/Endpoint/TabResultResponse.php +++ b/src/Model/Generated/Endpoint/TabResultResponse.php @@ -138,7 +138,7 @@ public function setPayment($payment) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->tab)) { return false; diff --git a/src/Model/Generated/Endpoint/TabUsageMultiple.php b/src/Model/Generated/Endpoint/TabUsageMultiple.php index 2131ee06..37ac71f0 100644 --- a/src/Model/Generated/Endpoint/TabUsageMultiple.php +++ b/src/Model/Generated/Endpoint/TabUsageMultiple.php @@ -648,7 +648,7 @@ public function setTabAttachment($tabAttachment) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->uuid)) { return false; diff --git a/src/Model/Generated/Endpoint/TabUsageSingle.php b/src/Model/Generated/Endpoint/TabUsageSingle.php index e66138db..a56f0b59 100644 --- a/src/Model/Generated/Endpoint/TabUsageSingle.php +++ b/src/Model/Generated/Endpoint/TabUsageSingle.php @@ -698,7 +698,7 @@ public function setTabAttachment($tabAttachment) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->uuid)) { return false; diff --git a/src/Model/Generated/Endpoint/TokenQrRequestIdeal.php b/src/Model/Generated/Endpoint/TokenQrRequestIdeal.php index 6273a31c..a6d4b48e 100644 --- a/src/Model/Generated/Endpoint/TokenQrRequestIdeal.php +++ b/src/Model/Generated/Endpoint/TokenQrRequestIdeal.php @@ -580,7 +580,7 @@ public function setEligibleWhitelistId($eligibleWhitelistId) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->timeResponded)) { return false; diff --git a/src/Model/Generated/Endpoint/User.php b/src/Model/Generated/Endpoint/User.php index 3fc4f63a..d2a56f90 100644 --- a/src/Model/Generated/Endpoint/User.php +++ b/src/Model/Generated/Endpoint/User.php @@ -174,7 +174,7 @@ public function getReferencedObject() /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->userLight)) { return false; diff --git a/src/Model/Generated/Endpoint/UserCompany.php b/src/Model/Generated/Endpoint/UserCompany.php index 8f62a196..c7ed3d88 100644 --- a/src/Model/Generated/Endpoint/UserCompany.php +++ b/src/Model/Generated/Endpoint/UserCompany.php @@ -849,7 +849,7 @@ public function setBillingContract($billingContract) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->id)) { return false; diff --git a/src/Model/Generated/Endpoint/UserCredentialPasswordIp.php b/src/Model/Generated/Endpoint/UserCredentialPasswordIp.php index c5b1f049..4260f7c7 100644 --- a/src/Model/Generated/Endpoint/UserCredentialPasswordIp.php +++ b/src/Model/Generated/Endpoint/UserCredentialPasswordIp.php @@ -259,7 +259,7 @@ public function setPermittedDevice($permittedDevice) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->id)) { return false; diff --git a/src/Model/Generated/Endpoint/UserLight.php b/src/Model/Generated/Endpoint/UserLight.php index 56e9f08d..dfb451ea 100644 --- a/src/Model/Generated/Endpoint/UserLight.php +++ b/src/Model/Generated/Endpoint/UserLight.php @@ -906,7 +906,7 @@ public function setNotificationFilters($notificationFilters) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->id)) { return false; diff --git a/src/Model/Generated/Endpoint/UserPerson.php b/src/Model/Generated/Endpoint/UserPerson.php index 5a7773e2..34a60a70 100644 --- a/src/Model/Generated/Endpoint/UserPerson.php +++ b/src/Model/Generated/Endpoint/UserPerson.php @@ -913,7 +913,7 @@ public function setNotificationFilters($notificationFilters) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->id)) { return false; diff --git a/src/Model/Generated/Object/Address.php b/src/Model/Generated/Object/Address.php index ec9a3c99..8cc7ae0c 100644 --- a/src/Model/Generated/Object/Address.php +++ b/src/Model/Generated/Object/Address.php @@ -202,7 +202,7 @@ public function setProvince($province) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->street)) { return false; diff --git a/src/Model/Generated/Object/Amount.php b/src/Model/Generated/Object/Amount.php index 3e371386..b2cd8329 100644 --- a/src/Model/Generated/Object/Amount.php +++ b/src/Model/Generated/Object/Amount.php @@ -71,7 +71,7 @@ public function setCurrency($currency) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->value)) { return false; diff --git a/src/Model/Generated/Object/AnchoredObject.php b/src/Model/Generated/Object/AnchoredObject.php index fdb8a346..2edbde97 100644 --- a/src/Model/Generated/Object/AnchoredObject.php +++ b/src/Model/Generated/Object/AnchoredObject.php @@ -495,7 +495,7 @@ public function getReferencedObject() /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->cardDebit)) { return false; diff --git a/src/Model/Generated/Object/Attachment.php b/src/Model/Generated/Object/Attachment.php index 80571111..85ba6dbe 100644 --- a/src/Model/Generated/Object/Attachment.php +++ b/src/Model/Generated/Object/Attachment.php @@ -61,7 +61,7 @@ public function setContentType($contentType) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->description)) { return false; diff --git a/src/Model/Generated/Object/AttachmentMonetaryAccountPayment.php b/src/Model/Generated/Object/AttachmentMonetaryAccountPayment.php index 34c28589..62e69ace 100644 --- a/src/Model/Generated/Object/AttachmentMonetaryAccountPayment.php +++ b/src/Model/Generated/Object/AttachmentMonetaryAccountPayment.php @@ -69,7 +69,7 @@ public function setMonetaryAccountId($monetaryAccountId) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->id)) { return false; diff --git a/src/Model/Generated/Object/AttachmentPublic.php b/src/Model/Generated/Object/AttachmentPublic.php index f712dc78..ac292eb0 100644 --- a/src/Model/Generated/Object/AttachmentPublic.php +++ b/src/Model/Generated/Object/AttachmentPublic.php @@ -86,7 +86,7 @@ public function setContentType($contentType) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->uuid)) { return false; diff --git a/src/Model/Generated/Object/AttachmentTab.php b/src/Model/Generated/Object/AttachmentTab.php index b6f99432..c6981bb7 100644 --- a/src/Model/Generated/Object/AttachmentTab.php +++ b/src/Model/Generated/Object/AttachmentTab.php @@ -86,7 +86,7 @@ public function setContentType($contentType) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->id)) { return false; diff --git a/src/Model/Generated/Object/Avatar.php b/src/Model/Generated/Object/Avatar.php index d5256df1..e63a1c87 100644 --- a/src/Model/Generated/Object/Avatar.php +++ b/src/Model/Generated/Object/Avatar.php @@ -94,7 +94,7 @@ public function setImage($image) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->uuid)) { return false; diff --git a/src/Model/Generated/Object/BudgetRestriction.php b/src/Model/Generated/Object/BudgetRestriction.php index d79c1711..3b3ee1cd 100644 --- a/src/Model/Generated/Object/BudgetRestriction.php +++ b/src/Model/Generated/Object/BudgetRestriction.php @@ -63,7 +63,7 @@ public function setFrequency($frequency) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->amount)) { return false; diff --git a/src/Model/Generated/Object/BunqId.php b/src/Model/Generated/Object/BunqId.php index 030b2374..18e20112 100644 --- a/src/Model/Generated/Object/BunqId.php +++ b/src/Model/Generated/Object/BunqId.php @@ -44,7 +44,7 @@ public function setId($id) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->id)) { return false; diff --git a/src/Model/Generated/Object/BunqMeMerchantAvailable.php b/src/Model/Generated/Object/BunqMeMerchantAvailable.php index 32f0d714..56b874b3 100644 --- a/src/Model/Generated/Object/BunqMeMerchantAvailable.php +++ b/src/Model/Generated/Object/BunqMeMerchantAvailable.php @@ -61,7 +61,7 @@ public function setAvailable($available) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->merchantType)) { return false; diff --git a/src/Model/Generated/Object/CardCountryPermission.php b/src/Model/Generated/Object/CardCountryPermission.php index b9ce7284..5af4e47e 100644 --- a/src/Model/Generated/Object/CardCountryPermission.php +++ b/src/Model/Generated/Object/CardCountryPermission.php @@ -94,7 +94,7 @@ public function setExpiryTime($expiryTime) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->id)) { return false; diff --git a/src/Model/Generated/Object/CardLimit.php b/src/Model/Generated/Object/CardLimit.php index 40eb92d7..5a96284e 100644 --- a/src/Model/Generated/Object/CardLimit.php +++ b/src/Model/Generated/Object/CardLimit.php @@ -125,7 +125,7 @@ public function setType($type) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->id)) { return false; diff --git a/src/Model/Generated/Object/CardMagStripePermission.php b/src/Model/Generated/Object/CardMagStripePermission.php index 7c24f91f..518383a1 100644 --- a/src/Model/Generated/Object/CardMagStripePermission.php +++ b/src/Model/Generated/Object/CardMagStripePermission.php @@ -36,7 +36,7 @@ public function setExpiryTime($expiryTime) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->expiryTime)) { return false; diff --git a/src/Model/Generated/Object/CardPinAssignment.php b/src/Model/Generated/Object/CardPinAssignment.php index 9ae735b7..2cc67db8 100644 --- a/src/Model/Generated/Object/CardPinAssignment.php +++ b/src/Model/Generated/Object/CardPinAssignment.php @@ -76,7 +76,7 @@ public function setMonetaryAccountId($monetaryAccountId) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->type)) { return false; diff --git a/src/Model/Generated/Object/Certificate.php b/src/Model/Generated/Object/Certificate.php index 2e58f07f..659d2121 100644 --- a/src/Model/Generated/Object/Certificate.php +++ b/src/Model/Generated/Object/Certificate.php @@ -44,7 +44,7 @@ public function setCertificate($certificate) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->certificate)) { return false; diff --git a/src/Model/Generated/Object/ChatMessageContent.php b/src/Model/Generated/Object/ChatMessageContent.php index 91de2464..6ae43e2e 100644 --- a/src/Model/Generated/Object/ChatMessageContent.php +++ b/src/Model/Generated/Object/ChatMessageContent.php @@ -205,7 +205,7 @@ public function getReferencedObject() /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->chatMessageContentAnchorEvent)) { return false; diff --git a/src/Model/Generated/Object/ChatMessageContentAnchorEvent.php b/src/Model/Generated/Object/ChatMessageContentAnchorEvent.php index 7264ae4c..118621fc 100644 --- a/src/Model/Generated/Object/ChatMessageContentAnchorEvent.php +++ b/src/Model/Generated/Object/ChatMessageContentAnchorEvent.php @@ -46,7 +46,7 @@ public function setAnchoredObject($anchoredObject) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->anchoredObject)) { return false; diff --git a/src/Model/Generated/Object/ChatMessageContentAttachment.php b/src/Model/Generated/Object/ChatMessageContentAttachment.php index 3dcc6eb9..81b0d0a0 100644 --- a/src/Model/Generated/Object/ChatMessageContentAttachment.php +++ b/src/Model/Generated/Object/ChatMessageContentAttachment.php @@ -36,7 +36,7 @@ public function setAttachment($attachment) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->attachment)) { return false; diff --git a/src/Model/Generated/Object/ChatMessageContentGeolocation.php b/src/Model/Generated/Object/ChatMessageContentGeolocation.php index a0245234..c3d99029 100644 --- a/src/Model/Generated/Object/ChatMessageContentGeolocation.php +++ b/src/Model/Generated/Object/ChatMessageContentGeolocation.php @@ -36,7 +36,7 @@ public function setGeolocation($geolocation) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->geolocation)) { return false; diff --git a/src/Model/Generated/Object/ChatMessageContentStatusConversation.php b/src/Model/Generated/Object/ChatMessageContentStatusConversation.php index 9654f8d2..165ee3fc 100644 --- a/src/Model/Generated/Object/ChatMessageContentStatusConversation.php +++ b/src/Model/Generated/Object/ChatMessageContentStatusConversation.php @@ -36,7 +36,7 @@ public function setAction($action) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->action)) { return false; diff --git a/src/Model/Generated/Object/ChatMessageContentStatusConversationTitle.php b/src/Model/Generated/Object/ChatMessageContentStatusConversationTitle.php index 83eed39c..1fae3877 100644 --- a/src/Model/Generated/Object/ChatMessageContentStatusConversationTitle.php +++ b/src/Model/Generated/Object/ChatMessageContentStatusConversationTitle.php @@ -36,7 +36,7 @@ public function setTitle($title) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->title)) { return false; diff --git a/src/Model/Generated/Object/ChatMessageContentStatusMembership.php b/src/Model/Generated/Object/ChatMessageContentStatusMembership.php index a3147e10..a264ddfe 100644 --- a/src/Model/Generated/Object/ChatMessageContentStatusMembership.php +++ b/src/Model/Generated/Object/ChatMessageContentStatusMembership.php @@ -63,7 +63,7 @@ public function setMember($member) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->action)) { return false; diff --git a/src/Model/Generated/Object/ChatMessageContentText.php b/src/Model/Generated/Object/ChatMessageContentText.php index 9c3473e4..fa71b002 100644 --- a/src/Model/Generated/Object/ChatMessageContentText.php +++ b/src/Model/Generated/Object/ChatMessageContentText.php @@ -36,7 +36,7 @@ public function setText($text) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->text)) { return false; diff --git a/src/Model/Generated/Object/DraftPaymentAnchorObject.php b/src/Model/Generated/Object/DraftPaymentAnchorObject.php index d3265400..5b06ddf2 100644 --- a/src/Model/Generated/Object/DraftPaymentAnchorObject.php +++ b/src/Model/Generated/Object/DraftPaymentAnchorObject.php @@ -79,7 +79,7 @@ public function getReferencedObject() /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->payment)) { return false; diff --git a/src/Model/Generated/Object/DraftPaymentEntry.php b/src/Model/Generated/Object/DraftPaymentEntry.php index 200d809f..532caf24 100644 --- a/src/Model/Generated/Object/DraftPaymentEntry.php +++ b/src/Model/Generated/Object/DraftPaymentEntry.php @@ -238,7 +238,7 @@ public function setAttachment($attachment) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->id)) { return false; diff --git a/src/Model/Generated/Object/DraftPaymentResponse.php b/src/Model/Generated/Object/DraftPaymentResponse.php index 382a91eb..b178f8fd 100644 --- a/src/Model/Generated/Object/DraftPaymentResponse.php +++ b/src/Model/Generated/Object/DraftPaymentResponse.php @@ -61,7 +61,7 @@ public function setUserAliasCreated($userAliasCreated) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->status)) { return false; diff --git a/src/Model/Generated/Object/DraftShareInviteBankEntry.php b/src/Model/Generated/Object/DraftShareInviteBankEntry.php index 4e2fd54a..c9f5ac16 100644 --- a/src/Model/Generated/Object/DraftShareInviteBankEntry.php +++ b/src/Model/Generated/Object/DraftShareInviteBankEntry.php @@ -94,7 +94,7 @@ public function setEndDate($endDate) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->shareDetail)) { return false; diff --git a/src/Model/Generated/Object/Error.php b/src/Model/Generated/Object/Error.php index 561f518f..2f73bbdd 100644 --- a/src/Model/Generated/Object/Error.php +++ b/src/Model/Generated/Object/Error.php @@ -61,7 +61,7 @@ public function setErrorDescriptionTranslated($errorDescriptionTranslated) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->errorDescription)) { return false; diff --git a/src/Model/Generated/Object/Geolocation.php b/src/Model/Generated/Object/Geolocation.php index 87549b46..6a3e85e9 100644 --- a/src/Model/Generated/Object/Geolocation.php +++ b/src/Model/Generated/Object/Geolocation.php @@ -111,7 +111,7 @@ public function setRadius($radius) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->latitude)) { return false; diff --git a/src/Model/Generated/Object/Image.php b/src/Model/Generated/Object/Image.php index 40b2e75d..ea5993cd 100644 --- a/src/Model/Generated/Object/Image.php +++ b/src/Model/Generated/Object/Image.php @@ -111,7 +111,7 @@ public function setWidth($width) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->attachmentPublicUuid)) { return false; diff --git a/src/Model/Generated/Object/InvoiceItem.php b/src/Model/Generated/Object/InvoiceItem.php index 668a9d76..4ff32ca9 100644 --- a/src/Model/Generated/Object/InvoiceItem.php +++ b/src/Model/Generated/Object/InvoiceItem.php @@ -236,7 +236,7 @@ public function setTotalVatInclusive($totalVatInclusive) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->billingDate)) { return false; diff --git a/src/Model/Generated/Object/InvoiceItemGroup.php b/src/Model/Generated/Object/InvoiceItemGroup.php index 9f51a678..2403f379 100644 --- a/src/Model/Generated/Object/InvoiceItemGroup.php +++ b/src/Model/Generated/Object/InvoiceItemGroup.php @@ -186,7 +186,7 @@ public function setItem($item) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->type)) { return false; diff --git a/src/Model/Generated/Object/Issuer.php b/src/Model/Generated/Object/Issuer.php index 5b919629..739b84ce 100644 --- a/src/Model/Generated/Object/Issuer.php +++ b/src/Model/Generated/Object/Issuer.php @@ -69,7 +69,7 @@ public function setName($name) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->bic)) { return false; diff --git a/src/Model/Generated/Object/LabelCard.php b/src/Model/Generated/Object/LabelCard.php index 5b5842f3..824aa79b 100644 --- a/src/Model/Generated/Object/LabelCard.php +++ b/src/Model/Generated/Object/LabelCard.php @@ -161,7 +161,7 @@ public function setLabelUser($labelUser) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->uuid)) { return false; diff --git a/src/Model/Generated/Object/LabelMonetaryAccount.php b/src/Model/Generated/Object/LabelMonetaryAccount.php index fea87cfa..9f5f9052 100644 --- a/src/Model/Generated/Object/LabelMonetaryAccount.php +++ b/src/Model/Generated/Object/LabelMonetaryAccount.php @@ -236,7 +236,7 @@ public function setSwiftAccountNumber($swiftAccountNumber) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->iban)) { return false; diff --git a/src/Model/Generated/Object/LabelUser.php b/src/Model/Generated/Object/LabelUser.php index 60cef124..a0187428 100644 --- a/src/Model/Generated/Object/LabelUser.php +++ b/src/Model/Generated/Object/LabelUser.php @@ -148,7 +148,7 @@ public function setCountry($country) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->uuid)) { return false; diff --git a/src/Model/Generated/Object/MonetaryAccountProfileDrain.php b/src/Model/Generated/Object/MonetaryAccountProfileDrain.php index 4ad7e002..a471ab2a 100644 --- a/src/Model/Generated/Object/MonetaryAccountProfileDrain.php +++ b/src/Model/Generated/Object/MonetaryAccountProfileDrain.php @@ -125,7 +125,7 @@ public function setSavingsAccountAlias($savingsAccountAlias) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->status)) { return false; diff --git a/src/Model/Generated/Object/MonetaryAccountProfileFill.php b/src/Model/Generated/Object/MonetaryAccountProfileFill.php index a4177061..26861b03 100644 --- a/src/Model/Generated/Object/MonetaryAccountProfileFill.php +++ b/src/Model/Generated/Object/MonetaryAccountProfileFill.php @@ -152,7 +152,7 @@ public function setIssuer($issuer) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->status)) { return false; diff --git a/src/Model/Generated/Object/MonetaryAccountSetting.php b/src/Model/Generated/Object/MonetaryAccountSetting.php index b79b0444..fdf21441 100644 --- a/src/Model/Generated/Object/MonetaryAccountSetting.php +++ b/src/Model/Generated/Object/MonetaryAccountSetting.php @@ -90,7 +90,7 @@ public function setRestrictionChat($restrictionChat) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->color)) { return false; diff --git a/src/Model/Generated/Object/NotificationAnchorObject.php b/src/Model/Generated/Object/NotificationAnchorObject.php index 2f91da5f..fc283423 100644 --- a/src/Model/Generated/Object/NotificationAnchorObject.php +++ b/src/Model/Generated/Object/NotificationAnchorObject.php @@ -2,7 +2,9 @@ namespace bunq\Model\Generated\Object; use bunq\exception\BunqException; +use bunq\Model\Core\AnchorObjectInterface; use bunq\Model\Core\BunqModel; +use bunq\Model\Generated\Endpoint\BunqMeFundraiserResult; use bunq\Model\Generated\Endpoint\BunqMeTab; use bunq\Model\Generated\Endpoint\BunqMeTabResultInquiry; use bunq\Model\Generated\Endpoint\BunqMeTabResultResponse; @@ -35,6 +37,11 @@ class NotificationAnchorObject extends BunqModel implements AnchorObjectInterfac */ const ERROR_NULL_FIELDS = 'All fields of an extended model or object are null.'; + /** + * @var BunqMeFundraiserResult + */ + protected $bunqMeFundraiserResult; + /** * @var BunqMeTab */ @@ -141,7 +148,20 @@ class NotificationAnchorObject extends BunqModel implements AnchorObjectInterfac protected $user; /** + * @return BunqMeFundraiserResult */ + public function getBunqMeFundraiserResult() + { + return $this->bunqMeFundraiserResult; + } + + /** + * @param BunqMeFundraiserResult $bunqMeFundraiserResult + */ + public function setBunqMeFundraiserResult($bunqMeFundraiserResult) + { + $this->bunqMeFundraiserResult = $bunqMeFundraiserResult; + } /** * @return BunqMeTab @@ -485,6 +505,10 @@ public function setUser($user) */ public function getReferencedObject() { + if (!is_null($this->bunqMeFundraiserResult)) { + return $this->bunqMeFundraiserResult; + } + if (!is_null($this->bunqMeTab)) { return $this->bunqMeTab; } @@ -575,8 +599,12 @@ public function getReferencedObject() /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { + if (!is_null($this->bunqMeFundraiserResult)) { + return false; + } + if (!is_null($this->bunqMeTab)) { return false; } diff --git a/src/Model/Generated/Object/NotificationFilter.php b/src/Model/Generated/Object/NotificationFilter.php index 819ebce9..6f408c02 100644 --- a/src/Model/Generated/Object/NotificationFilter.php +++ b/src/Model/Generated/Object/NotificationFilter.php @@ -116,7 +116,7 @@ public function setCategory($category) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->notificationDeliveryMethod)) { return false; diff --git a/src/Model/Generated/Object/NotificationUrl.php b/src/Model/Generated/Object/NotificationUrl.php index 7aafa8c5..dfc80982 100644 --- a/src/Model/Generated/Object/NotificationUrl.php +++ b/src/Model/Generated/Object/NotificationUrl.php @@ -95,7 +95,7 @@ public function setObject($object) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->targetUrl)) { return false; diff --git a/src/Model/Generated/Object/PermittedDevice.php b/src/Model/Generated/Object/PermittedDevice.php index 9b337b8a..95e99c97 100644 --- a/src/Model/Generated/Object/PermittedDevice.php +++ b/src/Model/Generated/Object/PermittedDevice.php @@ -61,7 +61,7 @@ public function setIp($ip) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->description)) { return false; diff --git a/src/Model/Generated/Object/Pointer.php b/src/Model/Generated/Object/Pointer.php index 7249935a..c3d31983 100644 --- a/src/Model/Generated/Object/Pointer.php +++ b/src/Model/Generated/Object/Pointer.php @@ -96,7 +96,7 @@ public function setName($name) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->type)) { return false; diff --git a/src/Model/Generated/Object/ScheduleAnchorObject.php b/src/Model/Generated/Object/ScheduleAnchorObject.php index 9f4f4621..3fa55f76 100644 --- a/src/Model/Generated/Object/ScheduleAnchorObject.php +++ b/src/Model/Generated/Object/ScheduleAnchorObject.php @@ -79,7 +79,7 @@ public function getReferencedObject() /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->payment)) { return false; diff --git a/src/Model/Generated/Object/ScheduleInstanceAnchorObject.php b/src/Model/Generated/Object/ScheduleInstanceAnchorObject.php index 0ece6079..93046628 100644 --- a/src/Model/Generated/Object/ScheduleInstanceAnchorObject.php +++ b/src/Model/Generated/Object/ScheduleInstanceAnchorObject.php @@ -79,7 +79,7 @@ public function getReferencedObject() /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->payment)) { return false; diff --git a/src/Model/Generated/Object/SchedulePaymentEntry.php b/src/Model/Generated/Object/SchedulePaymentEntry.php index 833a52e4..946c2507 100644 --- a/src/Model/Generated/Object/SchedulePaymentEntry.php +++ b/src/Model/Generated/Object/SchedulePaymentEntry.php @@ -193,7 +193,7 @@ public function setMerchantReference($merchantReference) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->amount)) { return false; diff --git a/src/Model/Generated/Object/ShareDetail.php b/src/Model/Generated/Object/ShareDetail.php index cb2560d8..b17f9a48 100644 --- a/src/Model/Generated/Object/ShareDetail.php +++ b/src/Model/Generated/Object/ShareDetail.php @@ -102,7 +102,7 @@ public function setDraftPayment($draftPayment) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->payment)) { return false; diff --git a/src/Model/Generated/Object/ShareDetailDraftPayment.php b/src/Model/Generated/Object/ShareDetailDraftPayment.php index 27c0d408..832b4f86 100644 --- a/src/Model/Generated/Object/ShareDetailDraftPayment.php +++ b/src/Model/Generated/Object/ShareDetailDraftPayment.php @@ -133,7 +133,7 @@ public function setViewNewEvents($viewNewEvents) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->makeDraftPayments)) { return false; diff --git a/src/Model/Generated/Object/ShareDetailPayment.php b/src/Model/Generated/Object/ShareDetailPayment.php index cf180632..ad697c27 100644 --- a/src/Model/Generated/Object/ShareDetailPayment.php +++ b/src/Model/Generated/Object/ShareDetailPayment.php @@ -185,7 +185,7 @@ public function setBudget($budget) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->makePayments)) { return false; diff --git a/src/Model/Generated/Object/ShareDetailReadOnly.php b/src/Model/Generated/Object/ShareDetailReadOnly.php index bcd05746..7a9fb1ba 100644 --- a/src/Model/Generated/Object/ShareDetailReadOnly.php +++ b/src/Model/Generated/Object/ShareDetailReadOnly.php @@ -104,7 +104,7 @@ public function setViewNewEvents($viewNewEvents) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->viewBalance)) { return false; diff --git a/src/Model/Generated/Object/TabTextWaitingScreen.php b/src/Model/Generated/Object/TabTextWaitingScreen.php index 159f3473..71d1cc82 100644 --- a/src/Model/Generated/Object/TabTextWaitingScreen.php +++ b/src/Model/Generated/Object/TabTextWaitingScreen.php @@ -71,7 +71,7 @@ public function setDescription($description) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->language)) { return false; diff --git a/src/Model/Generated/Object/TabVisibility.php b/src/Model/Generated/Object/TabVisibility.php index 28165913..3c8e2caa 100644 --- a/src/Model/Generated/Object/TabVisibility.php +++ b/src/Model/Generated/Object/TabVisibility.php @@ -98,7 +98,7 @@ public function setLocation($location) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->cashRegisterQrCode)) { return false; diff --git a/src/Model/Generated/Object/TaxResident.php b/src/Model/Generated/Object/TaxResident.php index 17ad08f5..2c64c0a3 100644 --- a/src/Model/Generated/Object/TaxResident.php +++ b/src/Model/Generated/Object/TaxResident.php @@ -71,7 +71,7 @@ public function setTaxNumber($taxNumber) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->country)) { return false; diff --git a/src/Model/Generated/Object/Ubo.php b/src/Model/Generated/Object/Ubo.php index 27bf4ca8..222388a0 100644 --- a/src/Model/Generated/Object/Ubo.php +++ b/src/Model/Generated/Object/Ubo.php @@ -86,7 +86,7 @@ public function setNationality($nationality) /** * @return bool */ - public function areAllFieldsNull() + public function isAllFieldNull() { if (!is_null($this->name)) { return false; From 1205e5378e84542f8b491ed88752176c4fe18eef Mon Sep 17 00:00:00 2001 From: Kevin Hellemun Date: Wed, 20 Dec 2017 16:11:45 +0100 Subject: [PATCH 20/27] Renamed abstract method to isAllFieldNull(). (bunq/sdk_php#68) --- src/Model/Core/BunqModel.php | 6 ++++-- src/Model/Core/Id.php | 2 +- src/Model/Core/Installation.php | 2 +- src/Model/Core/ServerPublicKey.php | 2 +- src/Model/Core/SessionServer.php | 2 +- src/Model/Core/Token.php | 2 +- src/Model/Core/Uuid.php | 2 +- 7 files changed, 10 insertions(+), 8 deletions(-) diff --git a/src/Model/Core/BunqModel.php b/src/Model/Core/BunqModel.php index d06f9c72..5151cfc3 100644 --- a/src/Model/Core/BunqModel.php +++ b/src/Model/Core/BunqModel.php @@ -56,10 +56,12 @@ abstract class BunqModel implements JsonSerializable const SCALAR_TYPE_BOOL = 'bool'; const SCALAR_TYPE_INT = 'int'; const SCALAR_TYPE_FLOAT = 'float'; + /** * @var string[] */ protected static $fieldNameOverrideMap = []; + /** * Set of the PHP scalar types. Mimicking a constant, and therefore should be used with self::. * @@ -172,7 +174,7 @@ private static function createFromResponseArrayAnchorObject( $model = self::createInstanceFromResponseArray($responseArray); - if ($model->areAllFieldsNull() && $depthCounter < self::DEPTH_COUNTER_MAX) { + if ($model->isAllFieldNull() && $depthCounter < self::DEPTH_COUNTER_MAX) { $model = self::decodeInsideModelFields($responseArray, $model, $depthCounter); } @@ -201,7 +203,7 @@ private static function decodeInsideModelFields(array $responseArray, BunqModel $depthCounter + self::DEPTH_COUNTER_INCREMENTER ); - if ($fieldContents->areAllFieldsNull()) { + if ($fieldContents->isAllFieldNull()) { $model->{$field} = null; } else { $model->{$field} = $fieldContents; diff --git a/src/Model/Core/Id.php b/src/Model/Core/Id.php index 42a32f88..a055e527 100644 --- a/src/Model/Core/Id.php +++ b/src/Model/Core/Id.php @@ -21,7 +21,7 @@ public function getId(): int /** * @return bool */ - protected function areAllFieldsNull() + protected function isAllFieldNull() { if (!is_null($this->id)) { return false; diff --git a/src/Model/Core/Installation.php b/src/Model/Core/Installation.php index 8e574af9..97171139 100644 --- a/src/Model/Core/Installation.php +++ b/src/Model/Core/Installation.php @@ -109,7 +109,7 @@ public function jsonSerialize(): array /** * @return bool */ - protected function areAllFieldsNull() + protected function isAllFieldNull() { if (!is_null($this->id)) { return false; diff --git a/src/Model/Core/ServerPublicKey.php b/src/Model/Core/ServerPublicKey.php index ac956f7b..7e3e61e5 100644 --- a/src/Model/Core/ServerPublicKey.php +++ b/src/Model/Core/ServerPublicKey.php @@ -51,7 +51,7 @@ protected static function createFromResponseArray( /** * @return bool */ - protected function areAllFieldsNull() + protected function isAllFieldNull() { if (!is_null($this->serverPublicKey)) { return false; diff --git a/src/Model/Core/SessionServer.php b/src/Model/Core/SessionServer.php index c72fc679..add38743 100644 --- a/src/Model/Core/SessionServer.php +++ b/src/Model/Core/SessionServer.php @@ -90,7 +90,7 @@ public function getUserPerson() /** * @return bool */ - protected function areAllFieldsNull() + protected function isAllFieldNull() { if (!is_null($this->token)) { return false; diff --git a/src/Model/Core/Token.php b/src/Model/Core/Token.php index 9d51c7e9..9cda22af 100644 --- a/src/Model/Core/Token.php +++ b/src/Model/Core/Token.php @@ -44,7 +44,7 @@ public function getToken(): string /** * @return bool */ - protected function areAllFieldsNull() + protected function isAllFieldNull() { if (!is_null($this->id)) { return false; diff --git a/src/Model/Core/Uuid.php b/src/Model/Core/Uuid.php index 4d51b057..b7fe6b39 100644 --- a/src/Model/Core/Uuid.php +++ b/src/Model/Core/Uuid.php @@ -21,7 +21,7 @@ public function getUuid(): string /** * @return bool */ - protected function areAllFieldsNull() + protected function isAllFieldNull() { if (!is_null($this->uuid)) { return false; From ed5485d520a51555aec5b835a6fb0a2b5553f771 Mon Sep 17 00:00:00 2001 From: Kevin Hellemun Date: Wed, 20 Dec 2017 16:18:03 +0100 Subject: [PATCH 21/27] Added missing array types. (bunq/sdk_php#68) --- src/Model/Core/BunqModel.php | 4 ++-- src/Model/Core/ServerPublicKey.php | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/Model/Core/BunqModel.php b/src/Model/Core/BunqModel.php index 5151cfc3..4386f788 100644 --- a/src/Model/Core/BunqModel.php +++ b/src/Model/Core/BunqModel.php @@ -155,7 +155,7 @@ protected static function createFromResponseArray( } /** - * @param array $responseArray + * @param mixed[] $responseArray * @param int|null $depthCounter * * @return BunqModel|null @@ -182,7 +182,7 @@ private static function createFromResponseArrayAnchorObject( } /** - * @param array $responseArray + * @param mixed[] $responseArray * @param BunqModel $model * @param int $depthCounter * diff --git a/src/Model/Core/ServerPublicKey.php b/src/Model/Core/ServerPublicKey.php index 7e3e61e5..883563f2 100644 --- a/src/Model/Core/ServerPublicKey.php +++ b/src/Model/Core/ServerPublicKey.php @@ -34,7 +34,7 @@ public function getServerPublicKey(): PublicKey } /** - * @param array $responseArray + * @param mixed[] $responseArray * @param string|null $wrapper * * @return static From 19bdc99177fd3d2413093ff8a4d7b9e1440b60bb Mon Sep 17 00:00:00 2001 From: Kevin Hellemun Date: Thu, 21 Dec 2017 10:43:14 +0100 Subject: [PATCH 22/27] Removed ulgy exception catch. Added new method to return null instead. (bunq/sdk_php#68) --- src/Model/Core/BunqModel.php | 33 +++++++++++++++++---------------- src/Util/ModelUtil.php | 14 ++++++++++++++ 2 files changed, 31 insertions(+), 16 deletions(-) diff --git a/src/Model/Core/BunqModel.php b/src/Model/Core/BunqModel.php index 4386f788..24ed0560 100644 --- a/src/Model/Core/BunqModel.php +++ b/src/Model/Core/BunqModel.php @@ -193,24 +193,25 @@ private static function decodeInsideModelFields(array $responseArray, BunqModel $modelFields = (array_keys(get_object_vars($model))); foreach ($modelFields as $field) { - try { - $fieldClass = ModelUtil::determineModelClassNameQualified($field); - $reflectionClass = new ReflectionClass($fieldClass); - /** @var BunqModel $bunqModelSubClass */ - $bunqModelSubClass = $reflectionClass->newInstanceWithoutConstructor(); - $fieldContents = $bunqModelSubClass::createFromResponseArrayAnchorObject( - $responseArray, - $depthCounter + self::DEPTH_COUNTER_INCREMENTER - ); - - if ($fieldContents->isAllFieldNull()) { - $model->{$field} = null; - } else { - $model->{$field} = $fieldContents; - } - } catch (BunqException $exception) { + $fieldClass = ModelUtil::getModelClassNameQualifiedOrNull($field); + + if (is_null($fieldClass)) { continue; } + + $reflectionClass = new ReflectionClass($fieldClass); + /** @var BunqModel $bunqModelSubClass */ + $bunqModelSubClass = $reflectionClass->newInstanceWithoutConstructor(); + $fieldContents = $bunqModelSubClass::createFromResponseArrayAnchorObject( + $responseArray, + $depthCounter + self::DEPTH_COUNTER_INCREMENTER + ); + + if ($fieldContents->isAllFieldNull()) { + $model->{$field} = null; + } else { + $model->{$field} = $fieldContents; + } } return $model; diff --git a/src/Util/ModelUtil.php b/src/Util/ModelUtil.php index 5855a369..2b41fc8d 100644 --- a/src/Util/ModelUtil.php +++ b/src/Util/ModelUtil.php @@ -61,6 +61,20 @@ public static function determineModelClassNameQualified(string $model): string } } + /** + * @param string $model + * + * @return null|string + */ + public static function getModelClassNameQualifiedOrNull(string $model) + { + try { + return static::determineModelClassNameQualified($model); + } catch (BunqException $exception) { + return null; + } + } + /** * @param string $className * From 9a855e8671e98b614274cd95586fcc7a7ff34d0a Mon Sep 17 00:00:00 2001 From: Kevin Hellemun Date: Thu, 21 Dec 2017 10:55:12 +0100 Subject: [PATCH 23/27] Empty() instead of is_null() or array. (bunq/sdk_php#68) --- src/Model/Core/BunqModel.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Model/Core/BunqModel.php b/src/Model/Core/BunqModel.php index 24ed0560..5c0a4dd7 100644 --- a/src/Model/Core/BunqModel.php +++ b/src/Model/Core/BunqModel.php @@ -147,7 +147,7 @@ protected static function createFromResponseArray( $responseArray = $responseArray[$wrapper]; } - if (is_null($responseArray)) { + if (empty($responseArray)) { return null; } @@ -164,7 +164,7 @@ private static function createFromResponseArrayAnchorObject( array $responseArray, int $depthCounter = null ) { - if (is_null($responseArray)) { + if (empty($responseArray)) { return null; } From cd2f910996138286d79c51220c1a38a907d546cc Mon Sep 17 00:00:00 2001 From: Kevin Hellemun Date: Thu, 21 Dec 2017 11:07:20 +0100 Subject: [PATCH 24/27] Fliped the methods to remove try catch block. (bunq/sdk_php#68) --- src/Model/Core/BunqModel.php | 2 +- src/Util/ModelUtil.php | 28 +++++++++++++++------------- 2 files changed, 16 insertions(+), 14 deletions(-) diff --git a/src/Model/Core/BunqModel.php b/src/Model/Core/BunqModel.php index 5c0a4dd7..b5a0c3d9 100644 --- a/src/Model/Core/BunqModel.php +++ b/src/Model/Core/BunqModel.php @@ -193,7 +193,7 @@ private static function decodeInsideModelFields(array $responseArray, BunqModel $modelFields = (array_keys(get_object_vars($model))); foreach ($modelFields as $field) { - $fieldClass = ModelUtil::getModelClassNameQualifiedOrNull($field); + $fieldClass = ModelUtil::getModelClassNameQualifiedOrNull($field); if (is_null($fieldClass)) { continue; diff --git a/src/Util/ModelUtil.php b/src/Util/ModelUtil.php index 2b41fc8d..9694321e 100644 --- a/src/Util/ModelUtil.php +++ b/src/Util/ModelUtil.php @@ -46,19 +46,13 @@ public static function deserializeResponseArray(string $json): array */ public static function determineModelClassNameQualified(string $model): string { - $classNameOverride = vsprintf(self::FORMAT_QUALIFIED_OVERRIDE_TYPE, [$model]); - $classNameModel = vsprintf(self::FORMAT_QUALIFIED_MODEL_TYPE, [$model]); - $classNameObject = vsprintf(self::FORMAT_QUALIFIED_OBJECT_TYPE, [$model]); + $classNameModel = static::getModelClassNameQualifiedOrNull($model); - if (static::isClassSubClassOfBunqModel($classNameOverride)) { - return $classNameOverride; - } elseif (static::isClassSubClassOfBunqModel($classNameModel)) { - return $classNameModel; - } elseif (static::isClassSubClassOfBunqModel($classNameObject)) { - return $classNameObject; - } else { + if (is_null($classNameModel)) { throw new BunqException(self::ERROR_MODEL_NOT_DEFINED, [$model]); } + + return $classNameModel; } /** @@ -68,9 +62,17 @@ public static function determineModelClassNameQualified(string $model): string */ public static function getModelClassNameQualifiedOrNull(string $model) { - try { - return static::determineModelClassNameQualified($model); - } catch (BunqException $exception) { + $classNameOverride = vsprintf(self::FORMAT_QUALIFIED_OVERRIDE_TYPE, [$model]); + $classNameModel = vsprintf(self::FORMAT_QUALIFIED_MODEL_TYPE, [$model]); + $classNameObject = vsprintf(self::FORMAT_QUALIFIED_OBJECT_TYPE, [$model]); + + if (static::isClassSubClassOfBunqModel($classNameOverride)) { + return $classNameOverride; + } elseif (static::isClassSubClassOfBunqModel($classNameModel)) { + return $classNameModel; + } elseif (static::isClassSubClassOfBunqModel($classNameObject)) { + return $classNameObject; + } else { return null; } } From ace996f2ffb02dbf3ff9d375973ea2e3ec404aee Mon Sep 17 00:00:00 2001 From: Kevin Hellemun Date: Thu, 21 Dec 2017 17:03:25 +0100 Subject: [PATCH 25/27] Removed mixed from doc block. (bunq/sdk_php#75) --- src/Http/Handler/ResponseHandlerSignature.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Http/Handler/ResponseHandlerSignature.php b/src/Http/Handler/ResponseHandlerSignature.php index 1d4531d2..7ca69f5b 100644 --- a/src/Http/Handler/ResponseHandlerSignature.php +++ b/src/Http/Handler/ResponseHandlerSignature.php @@ -122,7 +122,7 @@ private function determineHeaderStringForSignedResponse(array $headers) /** * @param string $headerName * - * @return mixed|string + * @return string */ private function ensureHeaderIsCorrectlyCased(string $headerName) { From 6a1f2af92085eea62c919f1df47b7ebf31e59c65 Mon Sep 17 00:00:00 2001 From: Kevin Hellemun Date: Thu, 21 Dec 2017 17:29:45 +0100 Subject: [PATCH 26/27] Version bump to 0.12.4. :muscle: --- src/Http/ApiClient.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Http/ApiClient.php b/src/Http/ApiClient.php index a01fa1f3..1060f534 100644 --- a/src/Http/ApiClient.php +++ b/src/Http/ApiClient.php @@ -71,7 +71,7 @@ class ApiClient /** * User agent constants. */ - const HEADER_USER_AGENT_BUNQ_SDK_DEFAULT = 'bunq-sdk-php/0.11.0'; + const HEADER_USER_AGENT_BUNQ_SDK_DEFAULT = 'bunq-sdk-php/0.12.4'; /** * Binary request constants. From 20116564d303000c1a99a9a848e18fa7b86dd0f7 Mon Sep 17 00:00:00 2001 From: Kevin Hellemun Date: Thu, 21 Dec 2017 17:32:18 +0100 Subject: [PATCH 27/27] Updated CHANGELOG.md for 0.12.4 :clap: --- CHANGELOG.md | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index b4600ee0..47720b61 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,30 @@ # Change Log +## [0.12.4](https://github.com/bunq/sdk_php/tree/0.12.4) (2017-12-21) +[Full Changelog](https://github.com/bunq/sdk_php/compare/0.12.3...0.12.4) + +**Implemented enhancements:** + +- Introduce fromJson method.  [\#84](https://github.com/bunq/sdk_php/issues/84) +- Make sure received signatures headers are correctly cased [\#75](https://github.com/bunq/sdk_php/issues/75) +- Return base class from createFromJsonString [\#73](https://github.com/bunq/sdk_php/issues/73) +- CHANGELOG.md is empty [\#71](https://github.com/bunq/sdk_php/issues/71) +- Improve decoder to recognise child objects [\#68](https://github.com/bunq/sdk_php/issues/68) +- Return static. \(bunq/sdk\_php\#73\) [\#74](https://github.com/bunq/sdk_php/pull/74) ([OGKevin](https://github.com/OGKevin)) +- Generated CHANGELOG.md :clap:. \(bunq/sdk\_php\#71\) [\#72](https://github.com/bunq/sdk_php/pull/72) ([OGKevin](https://github.com/OGKevin)) + +**Fixed bugs:** + +- Fatal error in the interactive installer when no allowed IP is given [\#79](https://github.com/bunq/sdk_php/issues/79) +- Fatal when using MonetaryAccountBank class [\#38](https://github.com/bunq/sdk_php/issues/38) +- Add specific php version to composer. \(bunq/sdk\_php\#38\) [\#77](https://github.com/bunq/sdk_php/pull/77) ([OGKevin](https://github.com/OGKevin)) + +**Merged pull requests:** + +- Feature/make sure headers are correctly cased bunq/sdk php\#75 [\#85](https://github.com/bunq/sdk_php/pull/85) ([OGKevin](https://github.com/OGKevin)) +- Feature/decode child object in parent object bunq/sdk php\#68 [\#83](https://github.com/bunq/sdk_php/pull/83) ([OGKevin](https://github.com/OGKevin)) +- Allow permitted IPs to be null in the interactive installer [\#78](https://github.com/bunq/sdk_php/pull/78) ([mbernson](https://github.com/mbernson)) + ## [0.12.3](https://github.com/bunq/sdk_php/tree/0.12.3) (2017-11-15) [Full Changelog](https://github.com/bunq/sdk_php/compare/0.12.2...0.12.3)