diff --git a/clients/GitHubEnterpriseCloud/etc/openapi-client-generator.state b/clients/GitHubEnterpriseCloud/etc/openapi-client-generator.state index bcf0685e8d9..d606081f76e 100644 --- a/clients/GitHubEnterpriseCloud/etc/openapi-client-generator.state +++ b/clients/GitHubEnterpriseCloud/etc/openapi-client-generator.state @@ -1,5 +1,5 @@ { - "specHash": "454299d93067cd461297e15605df4d94", + "specHash": "197765ae314cd6366887510a47df29dc", "generatedFiles": { "files": [ { @@ -220,7 +220,7 @@ }, { "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Schema\/CodeScanningAlertState.php", - "hash": "de61c5f7e38dc7e4db60961b8a301aad" + "hash": "9ebf7329168c9eb7f1bb78668e0870f2" }, { "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Schema\/AlertNumber.php", @@ -300,7 +300,7 @@ }, { "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Schema\/CodeScanningAlertInstance.php", - "hash": "997a0d55fc1dc2230b8f3ad16e898e9a" + "hash": "ca14a1db18c02d67e6fae3f847ba6d5e" }, { "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Schema\/SimpleRepository.php", @@ -308,7 +308,7 @@ }, { "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Schema\/CodeScanningOrganizationAlertItems.php", - "hash": "68632b0b06e802dde260e72d0c47da83" + "hash": "9fb878fcdc3870c101565c89a28940e9" }, { "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Schema\/EnterpriseSecurityAnalysisSettings.php", @@ -952,11 +952,11 @@ }, { "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Schema\/CodeScanningAlertItems.php", - "hash": "2dae00400e5ba459a57793b664214431" + "hash": "23ff930d97763750a7c6b98878a1a81a" }, { "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Schema\/CodeScanningAlert.php", - "hash": "d061f79a88243942898b004ce080f5a3" + "hash": "3442a484882398168decb0e5d7c49887" }, { "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Schema\/CodeScanningAlertSetState.php", @@ -1400,7 +1400,7 @@ }, { "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Schema\/PullRequest.php", - "hash": "f74bd7649e0491ce4f9fccb8b6b7efe0" + "hash": "044ec3329a9f91733628bf9e20a072a8" }, { "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Schema\/PullRequestMergeResult.php", @@ -1748,7 +1748,7 @@ }, { "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Schema\/WebhookCodeScanningAlertCreated.php", - "hash": "2bee679e229ac9d7480b1646898c219f" + "hash": "c55c7f38a87ebee5660d269d817bbb24" }, { "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Schema\/WebhookCodeScanningAlertFixed.php", @@ -1816,7 +1816,7 @@ }, { "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Schema\/WebhookDeploymentProtectionRuleRequested.php", - "hash": "a1e0b5e3d3236757e78ac75947bca457" + "hash": "c461bf7cac29d459de2f21bf8649c1ff" }, { "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Schema\/WebhookDeploymentStatusCreated.php", @@ -2288,11 +2288,11 @@ }, { "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Schema\/WebhookPullRequestClosed.php", - "hash": "377ae9486b3552786bc2d1d6970c593c" + "hash": "82c2e3982be9dd55888af40957e20f23" }, { "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Schema\/WebhookPullRequestConvertedToDraft.php", - "hash": "28ebe8b47149359eecf54a0708f72129" + "hash": "1fb1d37865bafab63cf602ce408710b9" }, { "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Schema\/WebhookPullRequestDemilestoned.php", @@ -2304,7 +2304,7 @@ }, { "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Schema\/WebhookPullRequestEdited.php", - "hash": "40f29712cb4fbfad15cb7ca2c4ad4b63" + "hash": "96e6483efa2704c3d33bcb3a1cd0c026" }, { "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Schema\/WebhookPullRequestEnqueued.php", @@ -2324,15 +2324,15 @@ }, { "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Schema\/WebhookPullRequestOpened.php", - "hash": "077f5aa8cda40ddc247b4043c94e906e" + "hash": "75bd468ec1a87115a205db62efcdc671" }, { "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Schema\/WebhookPullRequestReadyForReview.php", - "hash": "3b5d203da1cb07c5138601a0e7996843" + "hash": "c5b55efb99007fbda4b0e15f7127e26e" }, { "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Schema\/WebhookPullRequestReopened.php", - "hash": "f3e6be23c1af26fb7130a6e7c8d03022" + "hash": "fcdfa1fc884196881038f03997d5a2c5" }, { "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Schema\/WebhookPullRequestReviewCommentCreated.php", @@ -3356,27 +3356,11 @@ }, { "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Schema\/PullRequest\/Head.php", - "hash": "abde5fb887d2ca3c33aa039fb233fd3f" - }, - { - "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Schema\/PullRequest\/Head\/Repo.php", - "hash": "0d14a856c5f283575c4af96f784e0d46" - }, - { - "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Schema\/PullRequest\/Head\/Repo\/Owner.php", - "hash": "ff9da43af6d9dbafa6d50d2d4e09bb29" - }, - { - "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Schema\/PullRequest\/Head\/Repo\/License.php", - "hash": "efc23a200734021d83ef54d4aa8f9390" + "hash": "f7d47c1ed3fb828b2c81834fb71e724a" }, { "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Schema\/PullRequest\/Base.php", - "hash": "720c241f88c668f31174a7916c1a4c88" - }, - { - "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Schema\/PullRequest\/Base\/Repo.php", - "hash": "6b7ac1fcfc1e294b9e7203feb9fbf428" + "hash": "052a8440bdca19fd309c441f6499b4ba" }, { "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Schema\/ReviewComment\/Links.php", @@ -3616,7 +3600,7 @@ }, { "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Schema\/WebhookCodeScanningAlertCreated\/Alert.php", - "hash": "8bb4b55dcd1a070c316b1cbe98ce2b48" + "hash": "3576c9619c4af8b9fcf65b09b67a3a62" }, { "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Schema\/WebhookCodeScanningAlertCreated\/Alert\/Tool.php", @@ -5912,11 +5896,11 @@ }, { "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Operation\/SecretScanning.php", - "hash": "2508262605c8877e0c90a8cf0ced784b" + "hash": "1e6bb400d98499572d5d1b327d331079" }, { "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Operation\/Dependabot.php", - "hash": "7e64255352b873a6ff08166c8d0b540f" + "hash": "3f996f89d2d6176e728b16cc1f5301f4" }, { "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Operation\/Billing.php", @@ -6016,7 +6000,7 @@ }, { "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Operation\/Search.php", - "hash": "a94802418df540d8f3bc4e1526d8c9d4" + "hash": "6e79dd91af0b91c25fa3816e7fb3a7f4" }, { "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Operation\/Users.php", @@ -6546,14 +6530,6 @@ "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Schema\/AliasAbstract\/Tiet205818DE\/Tiet09BC5C97\/TietDE84B773\/TietBE223C26.php", "hash": "bfa400617abb0c358f813818c1ef0edb" }, - { - "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Schema\/PullRequest\/Head\/Repo\/Permissions.php", - "hash": "c605d14daf28bb4ee666799c498f3882" - }, - { - "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Schema\/PullRequest\/Base\/Repo\/Permissions.php", - "hash": "d4851a3eee5a60b2cfa49855d3f8bc7f" - }, { "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Schema\/RepoSearchResultItem\/Permissions.php", "hash": "6c5e9b8a55c6e3b70e5c8d3153cfe233" @@ -6814,18 +6790,6 @@ "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Schema\/WebhookPageBuild\/Build\/Error.php", "hash": "bb8cf917cafb0395d68d8ec228ffa75e" }, - { - "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Schema\/PullRequest\/Head\/User.php", - "hash": "6eab38c745c981302f70c51cdc87d9a6" - }, - { - "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Schema\/PullRequest\/Base\/Repo\/Owner.php", - "hash": "ecb2d7385401ebba63f5da59b59857a4" - }, - { - "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Schema\/PullRequest\/Base\/User.php", - "hash": "22c1d272cc18b78aa9e2765760cc0ada" - }, { "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Schema\/PrivateVulnerabilityReportCreate\/Vulnerabilities.php", "hash": "a428c7e2d09fb0520c8f3580373b7be1" @@ -27904,7 +27868,7 @@ }, { "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Internal\/Hydrator\/Operation\/Repos\/Owner\/Repo\/CodeScanning\/Alerts\/AlertNumber.php", - "hash": "d87d478d17d51fc581ff7b40f8520f56" + "hash": "337c6751c431784770293c4191a023de" }, { "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Internal\/Hydrator\/Operation\/Repos\/Owner\/Repo\/CodeScanning\/Alerts\/AlertNumber\/Instances.php", @@ -28372,7 +28336,7 @@ }, { "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Internal\/Hydrator\/Operation\/Repos\/Owner\/Repo\/Pulls.php", - "hash": "7e492e273663d6ea5f42add53da76c99" + "hash": "22e289cdced9381fca270281f053d86e" }, { "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Internal\/Hydrator\/Operation\/Repos\/Owner\/Repo\/Pulls\/Comments\/CommentId.php", @@ -28384,7 +28348,7 @@ }, { "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Internal\/Hydrator\/Operation\/Repos\/Owner\/Repo\/Pulls\/PullNumber.php", - "hash": "5b2b2ad1aeda85255ddc0405aba5925c" + "hash": "32af2924e10400184e8ed74a421a4b14" }, { "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Internal\/Hydrator\/Operation\/Repos\/Owner\/Repo\/Pulls\/PullNumber\/Codespaces.php", @@ -28976,7 +28940,7 @@ }, { "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Internal\/Hydrators.php", - "hash": "ab571a13939aa2f458bae35c7ebf0146" + "hash": "c8fa9a38d3127018425cf92e62b8a407" }, { "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Internal\/Operation\/EnterpriseAdmin\/ListProvisionedGroupsEnterprise.php", @@ -30088,7 +30052,7 @@ }, { "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Internal\/Hydrator\/WebHook\/CodeScanningAlert.php", - "hash": "63c3e21babc5235d86a24a735953532b" + "hash": "df362d4ab3e14516d979aa673434dea3" }, { "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Internal\/Hydrator\/WebHook\/CommitComment.php", @@ -30252,7 +30216,7 @@ }, { "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Internal\/Hydrator\/WebHook\/PullRequest.php", - "hash": "52ffe9f9ee0800d4e3a073415d039ff3" + "hash": "9eef922f400ffb46f8cb99310db6b26b" }, { "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Internal\/Hydrator\/WebHook\/PullRequestReviewComment.php", @@ -30872,7 +30836,7 @@ }, { "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Schema\/PullRequestWebhook.php", - "hash": "7bea85abd0b1f4f20214cc7ef4744e30" + "hash": "a399ad318abd4b591333a1590ebbc55e" }, { "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Schema\/Vulnerability\/Package.php", @@ -32020,7 +31984,7 @@ }, { "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Schema\/CodeSecurity\/AttachConfiguration\/Request\/ApplicationJson.php", - "hash": "1934c3b21aa51e613db14e95ba5a62e9" + "hash": "2260efb3c3ce03adfb40d21d457cf872" }, { "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Schema\/CodeSecurity\/SetConfigurationAsDefault\/Request\/ApplicationJson.php", @@ -32702,14 +32666,6 @@ "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Schema\/AliasAbstract\/Tiet33AB0ED9\/Tiet45DEC305\/TietCF9E75E5\/Tiet163E6BD8.php", "hash": "457e342c5e0ec530be6f7cde23ce4eab" }, - { - "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Schema\/AliasAbstract\/Tiet51848752\/TietF5AFF89A\/Tiet1BF2E786\/Tiet3454ABD5.php", - "hash": "47cd54bbb7af71da125f67d59d9ed1e0" - }, - { - "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Schema\/AliasAbstract\/Tiet74CB63F2\/Tiet418A3C81\/TietBF5296EB\/Tiet7F2EFE97.php", - "hash": "a45b4ee63ad29b8367fa2e4cb68c83f6" - }, { "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Schema\/AliasAbstract\/Tiet43D49F44\/TietAE60624E\/Tiet6F859A9C\/Tiet1D52E2C1.php", "hash": "f0bd5a41b77c71a4acdb728a4c0c4f23" @@ -32861,6 +32817,10 @@ { "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Schema\/CodeSecurityConfiguration\/SecretScanningDelegatedBypassOptions\/Reviewers.php", "hash": "1763dbbf8f4d9ddccf06bf2c2033e90b" + }, + { + "name": ".\/clients\/GitHubEnterpriseCloud\/etc\/..\/\/src\/\/Schema\/AliasAbstract\/TietF9118D54\/Tiet0348F141\/Tiet9D635D6C\/TietE7315EF1.php", + "hash": "ec5620cd0ddd8fd35d3f720fd62de8fb" } ] }, diff --git a/clients/GitHubEnterpriseCloud/src/Internal/Hydrator/Operation/Repos/Owner/Repo/CodeScanning/Alerts/AlertNumber.php b/clients/GitHubEnterpriseCloud/src/Internal/Hydrator/Operation/Repos/Owner/Repo/CodeScanning/Alerts/AlertNumber.php index f18e6e7b691..df61f467e1c 100644 --- a/clients/GitHubEnterpriseCloud/src/Internal/Hydrator/Operation/Repos/Owner/Repo/CodeScanning/Alerts/AlertNumber.php +++ b/clients/GitHubEnterpriseCloud/src/Internal/Hydrator/Operation/Repos/Owner/Repo/CodeScanning/Alerts/AlertNumber.php @@ -135,7 +135,7 @@ private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️S $value = $payload['state'] ?? null; if ($value === null) { - $missingFields[] = 'state'; + $properties['state'] = null; goto after_state; } @@ -1208,7 +1208,12 @@ private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseClou $instancesUrl = $object->instancesUrl; after_instancesUrl: $result['instances_url'] = $instancesUrl; - $state = $object->state; + $state = $object->state; + + if ($state === null) { + goto after_state; + } + after_state: $result['state'] = $state; $fixedAt = $object->fixedAt; diff --git a/clients/GitHubEnterpriseCloud/src/Internal/Hydrator/Operation/Repos/Owner/Repo/Pulls.php b/clients/GitHubEnterpriseCloud/src/Internal/Hydrator/Operation/Repos/Owner/Repo/Pulls.php index 6f862d42900..cfbba1ce105 100644 --- a/clients/GitHubEnterpriseCloud/src/Internal/Hydrator/Operation/Repos/Owner/Repo/Pulls.php +++ b/clients/GitHubEnterpriseCloud/src/Internal/Hydrator/Operation/Repos/Owner/Repo/Pulls.php @@ -12,12 +12,9 @@ use ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest; use ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base; use ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head; -use ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo; -use ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo\License; -use ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo\Owner; -use ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo\Permissions; -use ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\User; use ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Links; +use ApiClients\Client\GitHubEnterpriseCloud\Schema\Repository; +use ApiClients\Client\GitHubEnterpriseCloud\Schema\Repository\Permissions; use ApiClients\Client\GitHubEnterpriseCloud\Schema\SimpleUser; use ApiClients\Client\GitHubEnterpriseCloud\Schema\ValidationError; use EventSauce\ObjectHydrator\IterableList; @@ -60,17 +57,10 @@ public function hydrateObject(string $className, array $payload): object 'ApiClients\Client\GitHubEnterpriseCloud\Schema\SimpleUser' => $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleUser($payload), 'ApiClients\Client\GitHubEnterpriseCloud\Schema\Milestone' => $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Milestone($payload), 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head' => $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head($payload), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo' => $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo($payload), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo\Owner' => $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo⚡️Owner($payload), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo\Permissions' => $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo⚡️Permissions($payload), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo\License' => $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo⚡️License($payload), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\User' => $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️User($payload), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base' => $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base($payload), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo' => $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️Repo($payload), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo\Owner' => $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️Repo⚡️Owner($payload), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo\Permissions' => $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️Repo⚡️Permissions($payload), + 'ApiClients\Client\GitHubEnterpriseCloud\Schema\Repository' => $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Repository($payload), 'ApiClients\Client\GitHubEnterpriseCloud\Schema\LicenseSimple' => $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️LicenseSimple($payload), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\User' => $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️User($payload), + 'ApiClients\Client\GitHubEnterpriseCloud\Schema\Repository\Permissions' => $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Repository⚡️Permissions($payload), + 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base' => $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base($payload), 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Links' => $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Links($payload), 'ApiClients\Client\GitHubEnterpriseCloud\Schema\Link' => $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Link($payload), 'ApiClients\Client\GitHubEnterpriseCloud\Schema\AutoMerge' => $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️AutoMerge($payload), @@ -1245,14 +1235,14 @@ private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️S $value = $payload['repo'] ?? null; if ($value === null) { - $properties['repo'] = null; + $missingFields[] = 'repo'; goto after_repo; } if (is_array($value)) { try { $this->hydrationStack[] = 'repo'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo($value); + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Repository($value); } finally { array_pop($this->hydrationStack); } @@ -1283,7 +1273,7 @@ private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️S if (is_array($value)) { try { $this->hydrationStack[] = 'user'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️User($value); + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleUser($value); } finally { array_pop($this->hydrationStack); } @@ -1307,11 +1297,181 @@ private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️S } } - private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo(array $payload): Repo + private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Repository(array $payload): Repository { $properties = []; $missingFields = []; try { + $value = $payload['id'] ?? null; + + if ($value === null) { + $missingFields[] = 'id'; + goto after_id; + } + + $properties['id'] = $value; + + after_id: + + $value = $payload['node_id'] ?? null; + + if ($value === null) { + $missingFields[] = 'node_id'; + goto after_nodeId; + } + + $properties['nodeId'] = $value; + + after_nodeId: + + $value = $payload['name'] ?? null; + + if ($value === null) { + $missingFields[] = 'name'; + goto after_name; + } + + $properties['name'] = $value; + + after_name: + + $value = $payload['full_name'] ?? null; + + if ($value === null) { + $missingFields[] = 'full_name'; + goto after_fullName; + } + + $properties['fullName'] = $value; + + after_fullName: + + $value = $payload['license'] ?? null; + + if ($value === null) { + $properties['license'] = null; + goto after_license; + } + + if (is_array($value)) { + try { + $this->hydrationStack[] = 'license'; + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️LicenseSimple($value); + } finally { + array_pop($this->hydrationStack); + } + } + + $properties['license'] = $value; + + after_license: + + $value = $payload['forks'] ?? null; + + if ($value === null) { + $missingFields[] = 'forks'; + goto after_forks; + } + + $properties['forks'] = $value; + + after_forks: + + $value = $payload['permissions'] ?? null; + + if ($value === null) { + $properties['permissions'] = null; + goto after_permissions; + } + + if (is_array($value)) { + try { + $this->hydrationStack[] = 'permissions'; + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Repository⚡️Permissions($value); + } finally { + array_pop($this->hydrationStack); + } + } + + $properties['permissions'] = $value; + + after_permissions: + + $value = $payload['owner'] ?? null; + + if ($value === null) { + $missingFields[] = 'owner'; + goto after_owner; + } + + if (is_array($value)) { + try { + $this->hydrationStack[] = 'owner'; + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleUser($value); + } finally { + array_pop($this->hydrationStack); + } + } + + $properties['owner'] = $value; + + after_owner: + + $value = $payload['private'] ?? null; + + if ($value === null) { + $missingFields[] = 'private'; + goto after_private; + } + + $properties['private'] = $value; + + after_private: + + $value = $payload['html_url'] ?? null; + + if ($value === null) { + $missingFields[] = 'html_url'; + goto after_htmlUrl; + } + + $properties['htmlUrl'] = $value; + + after_htmlUrl: + + $value = $payload['description'] ?? null; + + if ($value === null) { + $properties['description'] = null; + goto after_description; + } + + $properties['description'] = $value; + + after_description: + + $value = $payload['fork'] ?? null; + + if ($value === null) { + $missingFields[] = 'fork'; + goto after_fork; + } + + $properties['fork'] = $value; + + after_fork: + + $value = $payload['url'] ?? null; + + if ($value === null) { + $missingFields[] = 'url'; + goto after_url; + } + + $properties['url'] = $value; + + after_url: + $value = $payload['archive_url'] ?? null; if ($value === null) { @@ -1433,17 +1593,6 @@ private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️S after_deploymentsUrl: - $value = $payload['description'] ?? null; - - if ($value === null) { - $properties['description'] = null; - goto after_description; - } - - $properties['description'] = $value; - - after_description: - $value = $payload['downloads_url'] ?? null; if ($value === null) { @@ -1466,17 +1615,6 @@ private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️S after_eventsUrl: - $value = $payload['fork'] ?? null; - - if ($value === null) { - $missingFields[] = 'fork'; - goto after_fork; - } - - $properties['fork'] = $value; - - after_fork: - $value = $payload['forks_url'] ?? null; if ($value === null) { @@ -1488,17 +1626,6 @@ private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️S after_forksUrl: - $value = $payload['full_name'] ?? null; - - if ($value === null) { - $missingFields[] = 'full_name'; - goto after_fullName; - } - - $properties['fullName'] = $value; - - after_fullName: - $value = $payload['git_commits_url'] ?? null; if ($value === null) { @@ -1532,49 +1659,16 @@ private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️S after_gitTagsUrl: - $value = $payload['hooks_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'hooks_url'; - goto after_hooksUrl; - } - - $properties['hooksUrl'] = $value; - - after_hooksUrl: - - $value = $payload['html_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'html_url'; - goto after_htmlUrl; - } - - $properties['htmlUrl'] = $value; - - after_htmlUrl: - - $value = $payload['id'] ?? null; - - if ($value === null) { - $missingFields[] = 'id'; - goto after_id; - } - - $properties['id'] = $value; - - after_id: - - $value = $payload['node_id'] ?? null; + $value = $payload['git_url'] ?? null; if ($value === null) { - $missingFields[] = 'node_id'; - goto after_nodeId; + $missingFields[] = 'git_url'; + goto after_gitUrl; } - $properties['nodeId'] = $value; + $properties['gitUrl'] = $value; - after_nodeId: + after_gitUrl: $value = $payload['issue_comment_url'] ?? null; @@ -1664,59 +1758,17 @@ private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️S after_milestonesUrl: - $value = $payload['name'] ?? null; + $value = $payload['notifications_url'] ?? null; if ($value === null) { - $missingFields[] = 'name'; - goto after_name; - } - - $properties['name'] = $value; - - after_name: - - $value = $payload['notifications_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'notifications_url'; - goto after_notificationsUrl; + $missingFields[] = 'notifications_url'; + goto after_notificationsUrl; } $properties['notificationsUrl'] = $value; after_notificationsUrl: - $value = $payload['owner'] ?? null; - - if ($value === null) { - $missingFields[] = 'owner'; - goto after_owner; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'owner'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo⚡️Owner($value); - } finally { - array_pop($this->hydrationStack); - } - } - - $properties['owner'] = $value; - - after_owner: - - $value = $payload['private'] ?? null; - - if ($value === null) { - $missingFields[] = 'private'; - goto after_private; - } - - $properties['private'] = $value; - - after_private: - $value = $payload['pulls_url'] ?? null; if ($value === null) { @@ -1739,6 +1791,17 @@ private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️S after_releasesUrl: + $value = $payload['ssh_url'] ?? null; + + if ($value === null) { + $missingFields[] = 'ssh_url'; + goto after_sshUrl; + } + + $properties['sshUrl'] = $value; + + after_sshUrl: + $value = $payload['stargazers_url'] ?? null; if ($value === null) { @@ -1816,49 +1879,71 @@ private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️S after_treesUrl: - $value = $payload['url'] ?? null; + $value = $payload['clone_url'] ?? null; if ($value === null) { - $missingFields[] = 'url'; - goto after_url; + $missingFields[] = 'clone_url'; + goto after_cloneUrl; } - $properties['url'] = $value; + $properties['cloneUrl'] = $value; - after_url: + after_cloneUrl: - $value = $payload['clone_url'] ?? null; + $value = $payload['mirror_url'] ?? null; if ($value === null) { - $missingFields[] = 'clone_url'; - goto after_cloneUrl; + $properties['mirrorUrl'] = null; + goto after_mirrorUrl; } - $properties['cloneUrl'] = $value; + $properties['mirrorUrl'] = $value; - after_cloneUrl: + after_mirrorUrl: - $value = $payload['default_branch'] ?? null; + $value = $payload['hooks_url'] ?? null; if ($value === null) { - $missingFields[] = 'default_branch'; - goto after_defaultBranch; + $missingFields[] = 'hooks_url'; + goto after_hooksUrl; } - $properties['defaultBranch'] = $value; + $properties['hooksUrl'] = $value; - after_defaultBranch: + after_hooksUrl: - $value = $payload['forks'] ?? null; + $value = $payload['svn_url'] ?? null; if ($value === null) { - $missingFields[] = 'forks'; - goto after_forks; + $missingFields[] = 'svn_url'; + goto after_svnUrl; } - $properties['forks'] = $value; + $properties['svnUrl'] = $value; - after_forks: + after_svnUrl: + + $value = $payload['homepage'] ?? null; + + if ($value === null) { + $properties['homepage'] = null; + goto after_homepage; + } + + $properties['homepage'] = $value; + + after_homepage: + + $value = $payload['language'] ?? null; + + if ($value === null) { + $properties['language'] = null; + goto after_language; + } + + $properties['language'] = $value; + + after_language: $value = $payload['forks_count'] ?? null; @@ -1871,27 +1956,82 @@ private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️S after_forksCount: - $value = $payload['git_url'] ?? null; + $value = $payload['stargazers_count'] ?? null; if ($value === null) { - $missingFields[] = 'git_url'; - goto after_gitUrl; + $missingFields[] = 'stargazers_count'; + goto after_stargazersCount; } - $properties['gitUrl'] = $value; + $properties['stargazersCount'] = $value; - after_gitUrl: + after_stargazersCount: - $value = $payload['has_downloads'] ?? null; + $value = $payload['watchers_count'] ?? null; if ($value === null) { - $missingFields[] = 'has_downloads'; - goto after_hasDownloads; + $missingFields[] = 'watchers_count'; + goto after_watchersCount; } - $properties['hasDownloads'] = $value; + $properties['watchersCount'] = $value; - after_hasDownloads: + after_watchersCount: + + $value = $payload['size'] ?? null; + + if ($value === null) { + $missingFields[] = 'size'; + goto after_size; + } + + $properties['size'] = $value; + + after_size: + + $value = $payload['default_branch'] ?? null; + + if ($value === null) { + $missingFields[] = 'default_branch'; + goto after_defaultBranch; + } + + $properties['defaultBranch'] = $value; + + after_defaultBranch: + + $value = $payload['open_issues_count'] ?? null; + + if ($value === null) { + $missingFields[] = 'open_issues_count'; + goto after_openIssuesCount; + } + + $properties['openIssuesCount'] = $value; + + after_openIssuesCount: + + $value = $payload['is_template'] ?? null; + + if ($value === null) { + $properties['isTemplate'] = null; + goto after_isTemplate; + } + + $properties['isTemplate'] = $value; + + after_isTemplate: + + $value = $payload['topics'] ?? null; + + if ($value === null) { + $properties['topics'] = null; + goto after_topics; + } + + $properties['topics'] = $value; + + after_topics: $value = $payload['has_issues'] ?? null; @@ -1937,49 +2077,27 @@ private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️S after_hasPages: - $value = $payload['has_discussions'] ?? null; - - if ($value === null) { - $missingFields[] = 'has_discussions'; - goto after_hasDiscussions; - } - - $properties['hasDiscussions'] = $value; - - after_hasDiscussions: - - $value = $payload['homepage'] ?? null; - - if ($value === null) { - $properties['homepage'] = null; - goto after_homepage; - } - - $properties['homepage'] = $value; - - after_homepage: - - $value = $payload['language'] ?? null; + $value = $payload['has_downloads'] ?? null; if ($value === null) { - $properties['language'] = null; - goto after_language; + $missingFields[] = 'has_downloads'; + goto after_hasDownloads; } - $properties['language'] = $value; + $properties['hasDownloads'] = $value; - after_language: + after_hasDownloads: - $value = $payload['master_branch'] ?? null; + $value = $payload['has_discussions'] ?? null; if ($value === null) { - $properties['masterBranch'] = null; - goto after_masterBranch; + $properties['hasDiscussions'] = null; + goto after_hasDiscussions; } - $properties['masterBranch'] = $value; + $properties['hasDiscussions'] = $value; - after_masterBranch: + after_hasDiscussions: $value = $payload['archived'] ?? null; @@ -2014,58 +2132,49 @@ private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️S after_visibility: - $value = $payload['mirror_url'] ?? null; + $value = $payload['pushed_at'] ?? null; if ($value === null) { - $properties['mirrorUrl'] = null; - goto after_mirrorUrl; + $properties['pushedAt'] = null; + goto after_pushedAt; } - $properties['mirrorUrl'] = $value; + $properties['pushedAt'] = $value; - after_mirrorUrl: + after_pushedAt: - $value = $payload['open_issues'] ?? null; + $value = $payload['created_at'] ?? null; if ($value === null) { - $missingFields[] = 'open_issues'; - goto after_openIssues; + $properties['createdAt'] = null; + goto after_createdAt; } - $properties['openIssues'] = $value; + $properties['createdAt'] = $value; - after_openIssues: + after_createdAt: - $value = $payload['open_issues_count'] ?? null; + $value = $payload['updated_at'] ?? null; if ($value === null) { - $missingFields[] = 'open_issues_count'; - goto after_openIssuesCount; + $properties['updatedAt'] = null; + goto after_updatedAt; } - $properties['openIssuesCount'] = $value; + $properties['updatedAt'] = $value; - after_openIssuesCount: + after_updatedAt: - $value = $payload['permissions'] ?? null; + $value = $payload['allow_rebase_merge'] ?? null; if ($value === null) { - $properties['permissions'] = null; - goto after_permissions; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'permissions'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo⚡️Permissions($value); - } finally { - array_pop($this->hydrationStack); - } + $properties['allowRebaseMerge'] = null; + goto after_allowRebaseMerge; } - $properties['permissions'] = $value; + $properties['allowRebaseMerge'] = $value; - after_permissions: + after_allowRebaseMerge: $value = $payload['temp_clone_token'] ?? null; @@ -2078,17 +2187,6 @@ private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️S after_tempCloneToken: - $value = $payload['allow_merge_commit'] ?? null; - - if ($value === null) { - $properties['allowMergeCommit'] = null; - goto after_allowMergeCommit; - } - - $properties['allowMergeCommit'] = $value; - - after_allowMergeCommit: - $value = $payload['allow_squash_merge'] ?? null; if ($value === null) { @@ -2100,3516 +2198,933 @@ private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️S after_allowSquashMerge: - $value = $payload['allow_rebase_merge'] ?? null; + $value = $payload['allow_auto_merge'] ?? null; if ($value === null) { - $properties['allowRebaseMerge'] = null; - goto after_allowRebaseMerge; + $properties['allowAutoMerge'] = null; + goto after_allowAutoMerge; } - $properties['allowRebaseMerge'] = $value; + $properties['allowAutoMerge'] = $value; - after_allowRebaseMerge: + after_allowAutoMerge: - $value = $payload['license'] ?? null; + $value = $payload['delete_branch_on_merge'] ?? null; if ($value === null) { - $properties['license'] = null; - goto after_license; + $properties['deleteBranchOnMerge'] = null; + goto after_deleteBranchOnMerge; } - if (is_array($value)) { - try { - $this->hydrationStack[] = 'license'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo⚡️License($value); - } finally { - array_pop($this->hydrationStack); - } + $properties['deleteBranchOnMerge'] = $value; + + after_deleteBranchOnMerge: + + $value = $payload['allow_update_branch'] ?? null; + + if ($value === null) { + $properties['allowUpdateBranch'] = null; + goto after_allowUpdateBranch; } - $properties['license'] = $value; + $properties['allowUpdateBranch'] = $value; - after_license: + after_allowUpdateBranch: - $value = $payload['pushed_at'] ?? null; + $value = $payload['use_squash_pr_title_as_default'] ?? null; if ($value === null) { - $missingFields[] = 'pushed_at'; - goto after_pushedAt; + $properties['useSquashPrTitleAsDefault'] = null; + goto after_useSquashPrTitleAsDefault; } - $properties['pushedAt'] = $value; + $properties['useSquashPrTitleAsDefault'] = $value; - after_pushedAt: + after_useSquashPrTitleAsDefault: - $value = $payload['size'] ?? null; + $value = $payload['squash_merge_commit_title'] ?? null; if ($value === null) { - $missingFields[] = 'size'; - goto after_size; + $properties['squashMergeCommitTitle'] = null; + goto after_squashMergeCommitTitle; } - $properties['size'] = $value; + $properties['squashMergeCommitTitle'] = $value; - after_size: + after_squashMergeCommitTitle: - $value = $payload['ssh_url'] ?? null; + $value = $payload['squash_merge_commit_message'] ?? null; if ($value === null) { - $missingFields[] = 'ssh_url'; - goto after_sshUrl; + $properties['squashMergeCommitMessage'] = null; + goto after_squashMergeCommitMessage; } - $properties['sshUrl'] = $value; + $properties['squashMergeCommitMessage'] = $value; - after_sshUrl: + after_squashMergeCommitMessage: - $value = $payload['stargazers_count'] ?? null; + $value = $payload['merge_commit_title'] ?? null; if ($value === null) { - $missingFields[] = 'stargazers_count'; - goto after_stargazersCount; + $properties['mergeCommitTitle'] = null; + goto after_mergeCommitTitle; } - $properties['stargazersCount'] = $value; + $properties['mergeCommitTitle'] = $value; - after_stargazersCount: + after_mergeCommitTitle: - $value = $payload['svn_url'] ?? null; + $value = $payload['merge_commit_message'] ?? null; if ($value === null) { - $missingFields[] = 'svn_url'; - goto after_svnUrl; + $properties['mergeCommitMessage'] = null; + goto after_mergeCommitMessage; } - $properties['svnUrl'] = $value; + $properties['mergeCommitMessage'] = $value; - after_svnUrl: + after_mergeCommitMessage: - $value = $payload['topics'] ?? null; + $value = $payload['allow_merge_commit'] ?? null; if ($value === null) { - $properties['topics'] = null; - goto after_topics; + $properties['allowMergeCommit'] = null; + goto after_allowMergeCommit; } - $properties['topics'] = $value; + $properties['allowMergeCommit'] = $value; - after_topics: + after_allowMergeCommit: - $value = $payload['watchers'] ?? null; + $value = $payload['allow_forking'] ?? null; if ($value === null) { - $missingFields[] = 'watchers'; - goto after_watchers; + $properties['allowForking'] = null; + goto after_allowForking; } - $properties['watchers'] = $value; + $properties['allowForking'] = $value; - after_watchers: + after_allowForking: - $value = $payload['watchers_count'] ?? null; + $value = $payload['web_commit_signoff_required'] ?? null; if ($value === null) { - $missingFields[] = 'watchers_count'; - goto after_watchersCount; + $properties['webCommitSignoffRequired'] = null; + goto after_webCommitSignoffRequired; } - $properties['watchersCount'] = $value; + $properties['webCommitSignoffRequired'] = $value; - after_watchersCount: + after_webCommitSignoffRequired: - $value = $payload['created_at'] ?? null; + $value = $payload['open_issues'] ?? null; if ($value === null) { - $missingFields[] = 'created_at'; - goto after_createdAt; + $missingFields[] = 'open_issues'; + goto after_openIssues; } - $properties['createdAt'] = $value; + $properties['openIssues'] = $value; - after_createdAt: + after_openIssues: - $value = $payload['updated_at'] ?? null; + $value = $payload['watchers'] ?? null; if ($value === null) { - $missingFields[] = 'updated_at'; - goto after_updatedAt; + $missingFields[] = 'watchers'; + goto after_watchers; } - $properties['updatedAt'] = $value; + $properties['watchers'] = $value; - after_updatedAt: + after_watchers: - $value = $payload['allow_forking'] ?? null; + $value = $payload['master_branch'] ?? null; if ($value === null) { - $properties['allowForking'] = null; - goto after_allowForking; + $properties['masterBranch'] = null; + goto after_masterBranch; } - $properties['allowForking'] = $value; + $properties['masterBranch'] = $value; - after_allowForking: + after_masterBranch: - $value = $payload['is_template'] ?? null; + $value = $payload['starred_at'] ?? null; if ($value === null) { - $properties['isTemplate'] = null; - goto after_isTemplate; + $properties['starredAt'] = null; + goto after_starredAt; } - $properties['isTemplate'] = $value; + $properties['starredAt'] = $value; - after_isTemplate: + after_starredAt: - $value = $payload['web_commit_signoff_required'] ?? null; + $value = $payload['anonymous_access_enabled'] ?? null; if ($value === null) { - $properties['webCommitSignoffRequired'] = null; - goto after_webCommitSignoffRequired; + $properties['anonymousAccessEnabled'] = null; + goto after_anonymousAccessEnabled; } - $properties['webCommitSignoffRequired'] = $value; + $properties['anonymousAccessEnabled'] = $value; - after_webCommitSignoffRequired: + after_anonymousAccessEnabled: } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo', $exception, stack: $this->hydrationStack); + throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\Repository', $exception, stack: $this->hydrationStack); } if (count($missingFields) > 0) { - throw UnableToHydrateObject::dueToMissingFields(Repo::class, $missingFields, stack: $this->hydrationStack); + throw UnableToHydrateObject::dueToMissingFields(Repository::class, $missingFields, stack: $this->hydrationStack); } try { - return new Repo(...$properties); + return new Repository(...$properties); } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo', $exception, stack: $this->hydrationStack); + throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\Repository', $exception, stack: $this->hydrationStack); } } - private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo⚡️Owner(array $payload): Owner + private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️LicenseSimple(array $payload): LicenseSimple { $properties = []; $missingFields = []; try { - $value = $payload['avatar_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'avatar_url'; - goto after_avatarUrl; - } - - $properties['avatarUrl'] = $value; - - after_avatarUrl: - - $value = $payload['events_url'] ?? null; + $value = $payload['key'] ?? null; if ($value === null) { - $missingFields[] = 'events_url'; - goto after_eventsUrl; + $missingFields[] = 'key'; + goto after_key; } - $properties['eventsUrl'] = $value; + $properties['key'] = $value; - after_eventsUrl: + after_key: - $value = $payload['followers_url'] ?? null; + $value = $payload['name'] ?? null; if ($value === null) { - $missingFields[] = 'followers_url'; - goto after_followersUrl; + $missingFields[] = 'name'; + goto after_name; } - $properties['followersUrl'] = $value; + $properties['name'] = $value; - after_followersUrl: + after_name: - $value = $payload['following_url'] ?? null; + $value = $payload['url'] ?? null; if ($value === null) { - $missingFields[] = 'following_url'; - goto after_followingUrl; + $properties['url'] = null; + goto after_url; } - $properties['followingUrl'] = $value; + $properties['url'] = $value; - after_followingUrl: + after_url: - $value = $payload['gists_url'] ?? null; + $value = $payload['spdx_id'] ?? null; if ($value === null) { - $missingFields[] = 'gists_url'; - goto after_gistsUrl; + $properties['spdxId'] = null; + goto after_spdxId; } - $properties['gistsUrl'] = $value; + $properties['spdxId'] = $value; - after_gistsUrl: + after_spdxId: - $value = $payload['gravatar_id'] ?? null; + $value = $payload['node_id'] ?? null; if ($value === null) { - $properties['gravatarId'] = null; - goto after_gravatarId; + $missingFields[] = 'node_id'; + goto after_nodeId; } - $properties['gravatarId'] = $value; + $properties['nodeId'] = $value; - after_gravatarId: + after_nodeId: $value = $payload['html_url'] ?? null; if ($value === null) { - $missingFields[] = 'html_url'; + $properties['htmlUrl'] = null; goto after_htmlUrl; } $properties['htmlUrl'] = $value; after_htmlUrl: + } catch (Throwable $exception) { + throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\LicenseSimple', $exception, stack: $this->hydrationStack); + } - $value = $payload['id'] ?? null; + if (count($missingFields) > 0) { + throw UnableToHydrateObject::dueToMissingFields(LicenseSimple::class, $missingFields, stack: $this->hydrationStack); + } + + try { + return new LicenseSimple(...$properties); + } catch (Throwable $exception) { + throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\LicenseSimple', $exception, stack: $this->hydrationStack); + } + } + + private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Repository⚡️Permissions(array $payload): Permissions + { + $properties = []; + $missingFields = []; + try { + $value = $payload['admin'] ?? null; if ($value === null) { - $missingFields[] = 'id'; - goto after_id; + $missingFields[] = 'admin'; + goto after_admin; } - $properties['id'] = $value; + $properties['admin'] = $value; - after_id: + after_admin: - $value = $payload['node_id'] ?? null; + $value = $payload['pull'] ?? null; if ($value === null) { - $missingFields[] = 'node_id'; - goto after_nodeId; + $missingFields[] = 'pull'; + goto after_pull; } - $properties['nodeId'] = $value; + $properties['pull'] = $value; - after_nodeId: + after_pull: - $value = $payload['login'] ?? null; + $value = $payload['triage'] ?? null; if ($value === null) { - $missingFields[] = 'login'; - goto after_login; + $properties['triage'] = null; + goto after_triage; } - $properties['login'] = $value; + $properties['triage'] = $value; - after_login: + after_triage: - $value = $payload['organizations_url'] ?? null; + $value = $payload['push'] ?? null; if ($value === null) { - $missingFields[] = 'organizations_url'; - goto after_organizationsUrl; + $missingFields[] = 'push'; + goto after_push; } - $properties['organizationsUrl'] = $value; + $properties['push'] = $value; - after_organizationsUrl: + after_push: - $value = $payload['received_events_url'] ?? null; + $value = $payload['maintain'] ?? null; if ($value === null) { - $missingFields[] = 'received_events_url'; - goto after_receivedEventsUrl; + $properties['maintain'] = null; + goto after_maintain; } - $properties['receivedEventsUrl'] = $value; - - after_receivedEventsUrl: - - $value = $payload['repos_url'] ?? null; + $properties['maintain'] = $value; - if ($value === null) { - $missingFields[] = 'repos_url'; - goto after_reposUrl; - } + after_maintain: + } catch (Throwable $exception) { + throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\Repository\Permissions', $exception, stack: $this->hydrationStack); + } - $properties['reposUrl'] = $value; + if (count($missingFields) > 0) { + throw UnableToHydrateObject::dueToMissingFields(Permissions::class, $missingFields, stack: $this->hydrationStack); + } - after_reposUrl: + try { + return new Permissions(...$properties); + } catch (Throwable $exception) { + throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\Repository\Permissions', $exception, stack: $this->hydrationStack); + } + } - $value = $payload['site_admin'] ?? null; + private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base(array $payload): Base + { + $properties = []; + $missingFields = []; + try { + $value = $payload['label'] ?? null; if ($value === null) { - $missingFields[] = 'site_admin'; - goto after_siteAdmin; + $missingFields[] = 'label'; + goto after_label; } - $properties['siteAdmin'] = $value; + $properties['label'] = $value; - after_siteAdmin: + after_label: - $value = $payload['starred_url'] ?? null; + $value = $payload['ref'] ?? null; if ($value === null) { - $missingFields[] = 'starred_url'; - goto after_starredUrl; + $missingFields[] = 'ref'; + goto after_ref; } - $properties['starredUrl'] = $value; + $properties['ref'] = $value; - after_starredUrl: + after_ref: - $value = $payload['subscriptions_url'] ?? null; + $value = $payload['repo'] ?? null; if ($value === null) { - $missingFields[] = 'subscriptions_url'; - goto after_subscriptionsUrl; + $missingFields[] = 'repo'; + goto after_repo; } - $properties['subscriptionsUrl'] = $value; - - after_subscriptionsUrl: - - $value = $payload['type'] ?? null; - - if ($value === null) { - $missingFields[] = 'type'; - goto after_type; + if (is_array($value)) { + try { + $this->hydrationStack[] = 'repo'; + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Repository($value); + } finally { + array_pop($this->hydrationStack); + } } - $properties['type'] = $value; + $properties['repo'] = $value; - after_type: + after_repo: - $value = $payload['url'] ?? null; + $value = $payload['sha'] ?? null; if ($value === null) { - $missingFields[] = 'url'; - goto after_url; + $missingFields[] = 'sha'; + goto after_sha; } - $properties['url'] = $value; + $properties['sha'] = $value; - after_url: + after_sha: - $value = $payload['user_view_type'] ?? null; + $value = $payload['user'] ?? null; if ($value === null) { - $properties['userViewType'] = null; - goto after_userViewType; + $missingFields[] = 'user'; + goto after_user; } - $properties['userViewType'] = $value; + if (is_array($value)) { + try { + $this->hydrationStack[] = 'user'; + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleUser($value); + } finally { + array_pop($this->hydrationStack); + } + } - after_userViewType: + $properties['user'] = $value; + + after_user: } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo\Owner', $exception, stack: $this->hydrationStack); + throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base', $exception, stack: $this->hydrationStack); } if (count($missingFields) > 0) { - throw UnableToHydrateObject::dueToMissingFields(Owner::class, $missingFields, stack: $this->hydrationStack); + throw UnableToHydrateObject::dueToMissingFields(Base::class, $missingFields, stack: $this->hydrationStack); } try { - return new Owner(...$properties); + return new Base(...$properties); } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo\Owner', $exception, stack: $this->hydrationStack); + throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base', $exception, stack: $this->hydrationStack); } } - private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo⚡️Permissions(array $payload): Permissions + private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Links(array $payload): Links { $properties = []; $missingFields = []; try { - $value = $payload['admin'] ?? null; + $value = $payload['comments'] ?? null; if ($value === null) { - $missingFields[] = 'admin'; - goto after_admin; + $missingFields[] = 'comments'; + goto after_comments; } - $properties['admin'] = $value; - - after_admin: - - $value = $payload['maintain'] ?? null; - - if ($value === null) { - $properties['maintain'] = null; - goto after_maintain; + if (is_array($value)) { + try { + $this->hydrationStack[] = 'comments'; + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Link($value); + } finally { + array_pop($this->hydrationStack); + } } - $properties['maintain'] = $value; + $properties['comments'] = $value; - after_maintain: + after_comments: - $value = $payload['push'] ?? null; + $value = $payload['commits'] ?? null; if ($value === null) { - $missingFields[] = 'push'; - goto after_push; + $missingFields[] = 'commits'; + goto after_commits; } - $properties['push'] = $value; - - after_push: - - $value = $payload['triage'] ?? null; - - if ($value === null) { - $properties['triage'] = null; - goto after_triage; + if (is_array($value)) { + try { + $this->hydrationStack[] = 'commits'; + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Link($value); + } finally { + array_pop($this->hydrationStack); + } } - $properties['triage'] = $value; + $properties['commits'] = $value; - after_triage: + after_commits: - $value = $payload['pull'] ?? null; + $value = $payload['statuses'] ?? null; if ($value === null) { - $missingFields[] = 'pull'; - goto after_pull; + $missingFields[] = 'statuses'; + goto after_statuses; } - $properties['pull'] = $value; - - after_pull: - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo\Permissions', $exception, stack: $this->hydrationStack); - } + if (is_array($value)) { + try { + $this->hydrationStack[] = 'statuses'; + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Link($value); + } finally { + array_pop($this->hydrationStack); + } + } - if (count($missingFields) > 0) { - throw UnableToHydrateObject::dueToMissingFields(Permissions::class, $missingFields, stack: $this->hydrationStack); - } + $properties['statuses'] = $value; - try { - return new Permissions(...$properties); - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo\Permissions', $exception, stack: $this->hydrationStack); - } - } + after_statuses: - private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo⚡️License(array $payload): License - { - $properties = []; - $missingFields = []; - try { - $value = $payload['key'] ?? null; + $value = $payload['html'] ?? null; if ($value === null) { - $missingFields[] = 'key'; - goto after_key; + $missingFields[] = 'html'; + goto after_html; } - $properties['key'] = $value; + if (is_array($value)) { + try { + $this->hydrationStack[] = 'html'; + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Link($value); + } finally { + array_pop($this->hydrationStack); + } + } - after_key: + $properties['html'] = $value; - $value = $payload['name'] ?? null; + after_html: + + $value = $payload['issue'] ?? null; if ($value === null) { - $missingFields[] = 'name'; - goto after_name; + $missingFields[] = 'issue'; + goto after_issue; } - $properties['name'] = $value; + if (is_array($value)) { + try { + $this->hydrationStack[] = 'issue'; + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Link($value); + } finally { + array_pop($this->hydrationStack); + } + } - after_name: + $properties['issue'] = $value; - $value = $payload['url'] ?? null; + after_issue: + + $value = $payload['review_comments'] ?? null; if ($value === null) { - $properties['url'] = null; - goto after_url; + $missingFields[] = 'review_comments'; + goto after_reviewComments; } - $properties['url'] = $value; + if (is_array($value)) { + try { + $this->hydrationStack[] = 'reviewComments'; + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Link($value); + } finally { + array_pop($this->hydrationStack); + } + } - after_url: + $properties['reviewComments'] = $value; - $value = $payload['spdx_id'] ?? null; + after_reviewComments: + + $value = $payload['review_comment'] ?? null; if ($value === null) { - $properties['spdxId'] = null; - goto after_spdxId; + $missingFields[] = 'review_comment'; + goto after_reviewComment; } - $properties['spdxId'] = $value; + if (is_array($value)) { + try { + $this->hydrationStack[] = 'reviewComment'; + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Link($value); + } finally { + array_pop($this->hydrationStack); + } + } - after_spdxId: + $properties['reviewComment'] = $value; - $value = $payload['node_id'] ?? null; + after_reviewComment: + + $value = $payload['self'] ?? null; if ($value === null) { - $missingFields[] = 'node_id'; - goto after_nodeId; + $missingFields[] = 'self'; + goto after_self; } - $properties['nodeId'] = $value; + if (is_array($value)) { + try { + $this->hydrationStack[] = 'self'; + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Link($value); + } finally { + array_pop($this->hydrationStack); + } + } - after_nodeId: + $properties['self'] = $value; + + after_self: } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo\License', $exception, stack: $this->hydrationStack); + throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Links', $exception, stack: $this->hydrationStack); } if (count($missingFields) > 0) { - throw UnableToHydrateObject::dueToMissingFields(License::class, $missingFields, stack: $this->hydrationStack); + throw UnableToHydrateObject::dueToMissingFields(Links::class, $missingFields, stack: $this->hydrationStack); } try { - return new License(...$properties); + return new Links(...$properties); } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo\License', $exception, stack: $this->hydrationStack); + throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Links', $exception, stack: $this->hydrationStack); } } - private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️User(array $payload): User + private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Link(array $payload): Link { $properties = []; $missingFields = []; try { - $value = $payload['avatar_url'] ?? null; + $value = $payload['href'] ?? null; if ($value === null) { - $missingFields[] = 'avatar_url'; - goto after_avatarUrl; + $missingFields[] = 'href'; + goto after_href; } - $properties['avatarUrl'] = $value; - - after_avatarUrl: - - $value = $payload['events_url'] ?? null; + $properties['href'] = $value; - if ($value === null) { - $missingFields[] = 'events_url'; - goto after_eventsUrl; - } + after_href: + } catch (Throwable $exception) { + throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\Link', $exception, stack: $this->hydrationStack); + } - $properties['eventsUrl'] = $value; + if (count($missingFields) > 0) { + throw UnableToHydrateObject::dueToMissingFields(Link::class, $missingFields, stack: $this->hydrationStack); + } - after_eventsUrl: + try { + return new Link(...$properties); + } catch (Throwable $exception) { + throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\Link', $exception, stack: $this->hydrationStack); + } + } - $value = $payload['followers_url'] ?? null; + private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️AutoMerge(array $payload): AutoMerge + { + $properties = []; + $missingFields = []; + try { + $value = $payload['enabled_by'] ?? null; if ($value === null) { - $missingFields[] = 'followers_url'; - goto after_followersUrl; + $missingFields[] = 'enabled_by'; + goto after_enabledBy; } - $properties['followersUrl'] = $value; - - after_followersUrl: - - $value = $payload['following_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'following_url'; - goto after_followingUrl; + if (is_array($value)) { + try { + $this->hydrationStack[] = 'enabledBy'; + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleUser($value); + } finally { + array_pop($this->hydrationStack); + } } - $properties['followingUrl'] = $value; + $properties['enabledBy'] = $value; - after_followingUrl: + after_enabledBy: - $value = $payload['gists_url'] ?? null; + $value = $payload['merge_method'] ?? null; if ($value === null) { - $missingFields[] = 'gists_url'; - goto after_gistsUrl; + $missingFields[] = 'merge_method'; + goto after_mergeMethod; } - $properties['gistsUrl'] = $value; + $properties['mergeMethod'] = $value; - after_gistsUrl: + after_mergeMethod: - $value = $payload['gravatar_id'] ?? null; + $value = $payload['commit_title'] ?? null; if ($value === null) { - $properties['gravatarId'] = null; - goto after_gravatarId; + $missingFields[] = 'commit_title'; + goto after_commitTitle; } - $properties['gravatarId'] = $value; + $properties['commitTitle'] = $value; - after_gravatarId: + after_commitTitle: - $value = $payload['html_url'] ?? null; + $value = $payload['commit_message'] ?? null; if ($value === null) { - $missingFields[] = 'html_url'; - goto after_htmlUrl; + $missingFields[] = 'commit_message'; + goto after_commitMessage; } - $properties['htmlUrl'] = $value; - - after_htmlUrl: - - $value = $payload['id'] ?? null; + $properties['commitMessage'] = $value; - if ($value === null) { - $missingFields[] = 'id'; - goto after_id; - } + after_commitMessage: + } catch (Throwable $exception) { + throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\AutoMerge', $exception, stack: $this->hydrationStack); + } - $properties['id'] = $value; + if (count($missingFields) > 0) { + throw UnableToHydrateObject::dueToMissingFields(AutoMerge::class, $missingFields, stack: $this->hydrationStack); + } - after_id: + try { + return new AutoMerge(...$properties); + } catch (Throwable $exception) { + throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\AutoMerge', $exception, stack: $this->hydrationStack); + } + } - $value = $payload['node_id'] ?? null; + private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️BasicError(array $payload): BasicError + { + $properties = []; + $missingFields = []; + try { + $value = $payload['message'] ?? null; if ($value === null) { - $missingFields[] = 'node_id'; - goto after_nodeId; + $properties['message'] = null; + goto after_message; } - $properties['nodeId'] = $value; + $properties['message'] = $value; - after_nodeId: + after_message: - $value = $payload['login'] ?? null; + $value = $payload['documentation_url'] ?? null; if ($value === null) { - $missingFields[] = 'login'; - goto after_login; + $properties['documentationUrl'] = null; + goto after_documentationUrl; } - $properties['login'] = $value; + $properties['documentationUrl'] = $value; - after_login: + after_documentationUrl: - $value = $payload['organizations_url'] ?? null; + $value = $payload['url'] ?? null; if ($value === null) { - $missingFields[] = 'organizations_url'; - goto after_organizationsUrl; + $properties['url'] = null; + goto after_url; } - $properties['organizationsUrl'] = $value; + $properties['url'] = $value; - after_organizationsUrl: + after_url: - $value = $payload['received_events_url'] ?? null; + $value = $payload['status'] ?? null; if ($value === null) { - $missingFields[] = 'received_events_url'; - goto after_receivedEventsUrl; + $properties['status'] = null; + goto after_status; } - $properties['receivedEventsUrl'] = $value; - - after_receivedEventsUrl: - - $value = $payload['repos_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'repos_url'; - goto after_reposUrl; - } + $properties['status'] = $value; - $properties['reposUrl'] = $value; + after_status: + } catch (Throwable $exception) { + throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\BasicError', $exception, stack: $this->hydrationStack); + } - after_reposUrl: + if (count($missingFields) > 0) { + throw UnableToHydrateObject::dueToMissingFields(BasicError::class, $missingFields, stack: $this->hydrationStack); + } - $value = $payload['site_admin'] ?? null; + try { + return new BasicError(...$properties); + } catch (Throwable $exception) { + throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\BasicError', $exception, stack: $this->hydrationStack); + } + } - if ($value === null) { - $missingFields[] = 'site_admin'; - goto after_siteAdmin; + private function serializeViaTypeMap(string $accessor, object $object, array $payloadToTypeMap): array + { + foreach ($payloadToTypeMap as $payloadType => [$valueType, $method]) { + if (is_a($object, $valueType)) { + return [$accessor => $payloadType] + $this->{$method}($object); } + } - $properties['siteAdmin'] = $value; - - after_siteAdmin: + throw new LogicException('No type mapped for object of class: ' . $object::class); + } - $value = $payload['starred_url'] ?? null; + public function serializeObject(object $object): mixed + { + return $this->serializeObjectOfType($object, $object::class); + } - if ($value === null) { - $missingFields[] = 'starred_url'; - goto after_starredUrl; - } - - $properties['starredUrl'] = $value; - - after_starredUrl: - - $value = $payload['subscriptions_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'subscriptions_url'; - goto after_subscriptionsUrl; - } - - $properties['subscriptionsUrl'] = $value; - - after_subscriptionsUrl: - - $value = $payload['type'] ?? null; - - if ($value === null) { - $missingFields[] = 'type'; - goto after_type; - } - - $properties['type'] = $value; - - after_type: - - $value = $payload['url'] ?? null; - - if ($value === null) { - $missingFields[] = 'url'; - goto after_url; - } - - $properties['url'] = $value; - - after_url: - - $value = $payload['user_view_type'] ?? null; - - if ($value === null) { - $properties['userViewType'] = null; - goto after_userViewType; - } - - $properties['userViewType'] = $value; - - after_userViewType: - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\User', $exception, stack: $this->hydrationStack); - } - - if (count($missingFields) > 0) { - throw UnableToHydrateObject::dueToMissingFields(User::class, $missingFields, stack: $this->hydrationStack); - } - - try { - return new User(...$properties); - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\User', $exception, stack: $this->hydrationStack); - } - } - - private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base(array $payload): Base - { - $properties = []; - $missingFields = []; - try { - $value = $payload['label'] ?? null; - - if ($value === null) { - $missingFields[] = 'label'; - goto after_label; - } - - $properties['label'] = $value; - - after_label: - - $value = $payload['ref'] ?? null; - - if ($value === null) { - $missingFields[] = 'ref'; - goto after_ref; - } - - $properties['ref'] = $value; - - after_ref: - - $value = $payload['repo'] ?? null; - - if ($value === null) { - $missingFields[] = 'repo'; - goto after_repo; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'repo'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️Repo($value); - } finally { - array_pop($this->hydrationStack); - } - } - - $properties['repo'] = $value; - - after_repo: - - $value = $payload['sha'] ?? null; - - if ($value === null) { - $missingFields[] = 'sha'; - goto after_sha; - } - - $properties['sha'] = $value; - - after_sha: - - $value = $payload['user'] ?? null; - - if ($value === null) { - $missingFields[] = 'user'; - goto after_user; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'user'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️User($value); - } finally { - array_pop($this->hydrationStack); - } - } - - $properties['user'] = $value; - - after_user: - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base', $exception, stack: $this->hydrationStack); - } - - if (count($missingFields) > 0) { - throw UnableToHydrateObject::dueToMissingFields(Base::class, $missingFields, stack: $this->hydrationStack); - } - - try { - return new Base(...$properties); - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base', $exception, stack: $this->hydrationStack); - } - } - - private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️Repo(array $payload): \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo - { - $properties = []; - $missingFields = []; - try { - $value = $payload['archive_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'archive_url'; - goto after_archiveUrl; - } - - $properties['archiveUrl'] = $value; - - after_archiveUrl: - - $value = $payload['assignees_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'assignees_url'; - goto after_assigneesUrl; - } - - $properties['assigneesUrl'] = $value; - - after_assigneesUrl: - - $value = $payload['blobs_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'blobs_url'; - goto after_blobsUrl; - } - - $properties['blobsUrl'] = $value; - - after_blobsUrl: - - $value = $payload['branches_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'branches_url'; - goto after_branchesUrl; - } - - $properties['branchesUrl'] = $value; - - after_branchesUrl: - - $value = $payload['collaborators_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'collaborators_url'; - goto after_collaboratorsUrl; - } - - $properties['collaboratorsUrl'] = $value; - - after_collaboratorsUrl: - - $value = $payload['comments_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'comments_url'; - goto after_commentsUrl; - } - - $properties['commentsUrl'] = $value; - - after_commentsUrl: - - $value = $payload['commits_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'commits_url'; - goto after_commitsUrl; - } - - $properties['commitsUrl'] = $value; - - after_commitsUrl: - - $value = $payload['compare_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'compare_url'; - goto after_compareUrl; - } - - $properties['compareUrl'] = $value; - - after_compareUrl: - - $value = $payload['contents_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'contents_url'; - goto after_contentsUrl; - } - - $properties['contentsUrl'] = $value; - - after_contentsUrl: - - $value = $payload['contributors_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'contributors_url'; - goto after_contributorsUrl; - } - - $properties['contributorsUrl'] = $value; - - after_contributorsUrl: - - $value = $payload['deployments_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'deployments_url'; - goto after_deploymentsUrl; - } - - $properties['deploymentsUrl'] = $value; - - after_deploymentsUrl: - - $value = $payload['description'] ?? null; - - if ($value === null) { - $properties['description'] = null; - goto after_description; - } - - $properties['description'] = $value; - - after_description: - - $value = $payload['downloads_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'downloads_url'; - goto after_downloadsUrl; - } - - $properties['downloadsUrl'] = $value; - - after_downloadsUrl: - - $value = $payload['events_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'events_url'; - goto after_eventsUrl; - } - - $properties['eventsUrl'] = $value; - - after_eventsUrl: - - $value = $payload['fork'] ?? null; - - if ($value === null) { - $missingFields[] = 'fork'; - goto after_fork; - } - - $properties['fork'] = $value; - - after_fork: - - $value = $payload['forks_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'forks_url'; - goto after_forksUrl; - } - - $properties['forksUrl'] = $value; - - after_forksUrl: - - $value = $payload['full_name'] ?? null; - - if ($value === null) { - $missingFields[] = 'full_name'; - goto after_fullName; - } - - $properties['fullName'] = $value; - - after_fullName: - - $value = $payload['git_commits_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'git_commits_url'; - goto after_gitCommitsUrl; - } - - $properties['gitCommitsUrl'] = $value; - - after_gitCommitsUrl: - - $value = $payload['git_refs_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'git_refs_url'; - goto after_gitRefsUrl; - } - - $properties['gitRefsUrl'] = $value; - - after_gitRefsUrl: - - $value = $payload['git_tags_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'git_tags_url'; - goto after_gitTagsUrl; - } - - $properties['gitTagsUrl'] = $value; - - after_gitTagsUrl: - - $value = $payload['hooks_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'hooks_url'; - goto after_hooksUrl; - } - - $properties['hooksUrl'] = $value; - - after_hooksUrl: - - $value = $payload['html_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'html_url'; - goto after_htmlUrl; - } - - $properties['htmlUrl'] = $value; - - after_htmlUrl: - - $value = $payload['id'] ?? null; - - if ($value === null) { - $missingFields[] = 'id'; - goto after_id; - } - - $properties['id'] = $value; - - after_id: - - $value = $payload['is_template'] ?? null; - - if ($value === null) { - $properties['isTemplate'] = null; - goto after_isTemplate; - } - - $properties['isTemplate'] = $value; - - after_isTemplate: - - $value = $payload['node_id'] ?? null; - - if ($value === null) { - $missingFields[] = 'node_id'; - goto after_nodeId; - } - - $properties['nodeId'] = $value; - - after_nodeId: - - $value = $payload['issue_comment_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'issue_comment_url'; - goto after_issueCommentUrl; - } - - $properties['issueCommentUrl'] = $value; - - after_issueCommentUrl: - - $value = $payload['issue_events_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'issue_events_url'; - goto after_issueEventsUrl; - } - - $properties['issueEventsUrl'] = $value; - - after_issueEventsUrl: - - $value = $payload['issues_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'issues_url'; - goto after_issuesUrl; - } - - $properties['issuesUrl'] = $value; - - after_issuesUrl: - - $value = $payload['keys_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'keys_url'; - goto after_keysUrl; - } - - $properties['keysUrl'] = $value; - - after_keysUrl: - - $value = $payload['labels_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'labels_url'; - goto after_labelsUrl; - } - - $properties['labelsUrl'] = $value; - - after_labelsUrl: - - $value = $payload['languages_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'languages_url'; - goto after_languagesUrl; - } - - $properties['languagesUrl'] = $value; - - after_languagesUrl: - - $value = $payload['merges_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'merges_url'; - goto after_mergesUrl; - } - - $properties['mergesUrl'] = $value; - - after_mergesUrl: - - $value = $payload['milestones_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'milestones_url'; - goto after_milestonesUrl; - } - - $properties['milestonesUrl'] = $value; - - after_milestonesUrl: - - $value = $payload['name'] ?? null; - - if ($value === null) { - $missingFields[] = 'name'; - goto after_name; - } - - $properties['name'] = $value; - - after_name: - - $value = $payload['notifications_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'notifications_url'; - goto after_notificationsUrl; - } - - $properties['notificationsUrl'] = $value; - - after_notificationsUrl: - - $value = $payload['owner'] ?? null; - - if ($value === null) { - $missingFields[] = 'owner'; - goto after_owner; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'owner'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️Repo⚡️Owner($value); - } finally { - array_pop($this->hydrationStack); - } - } - - $properties['owner'] = $value; - - after_owner: - - $value = $payload['private'] ?? null; - - if ($value === null) { - $missingFields[] = 'private'; - goto after_private; - } - - $properties['private'] = $value; - - after_private: - - $value = $payload['pulls_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'pulls_url'; - goto after_pullsUrl; - } - - $properties['pullsUrl'] = $value; - - after_pullsUrl: - - $value = $payload['releases_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'releases_url'; - goto after_releasesUrl; - } - - $properties['releasesUrl'] = $value; - - after_releasesUrl: - - $value = $payload['stargazers_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'stargazers_url'; - goto after_stargazersUrl; - } - - $properties['stargazersUrl'] = $value; - - after_stargazersUrl: - - $value = $payload['statuses_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'statuses_url'; - goto after_statusesUrl; - } - - $properties['statusesUrl'] = $value; - - after_statusesUrl: - - $value = $payload['subscribers_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'subscribers_url'; - goto after_subscribersUrl; - } - - $properties['subscribersUrl'] = $value; - - after_subscribersUrl: - - $value = $payload['subscription_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'subscription_url'; - goto after_subscriptionUrl; - } - - $properties['subscriptionUrl'] = $value; - - after_subscriptionUrl: - - $value = $payload['tags_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'tags_url'; - goto after_tagsUrl; - } - - $properties['tagsUrl'] = $value; - - after_tagsUrl: - - $value = $payload['teams_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'teams_url'; - goto after_teamsUrl; - } - - $properties['teamsUrl'] = $value; - - after_teamsUrl: - - $value = $payload['trees_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'trees_url'; - goto after_treesUrl; - } - - $properties['treesUrl'] = $value; - - after_treesUrl: - - $value = $payload['url'] ?? null; - - if ($value === null) { - $missingFields[] = 'url'; - goto after_url; - } - - $properties['url'] = $value; - - after_url: - - $value = $payload['clone_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'clone_url'; - goto after_cloneUrl; - } - - $properties['cloneUrl'] = $value; - - after_cloneUrl: - - $value = $payload['default_branch'] ?? null; - - if ($value === null) { - $missingFields[] = 'default_branch'; - goto after_defaultBranch; - } - - $properties['defaultBranch'] = $value; - - after_defaultBranch: - - $value = $payload['forks'] ?? null; - - if ($value === null) { - $missingFields[] = 'forks'; - goto after_forks; - } - - $properties['forks'] = $value; - - after_forks: - - $value = $payload['forks_count'] ?? null; - - if ($value === null) { - $missingFields[] = 'forks_count'; - goto after_forksCount; - } - - $properties['forksCount'] = $value; - - after_forksCount: - - $value = $payload['git_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'git_url'; - goto after_gitUrl; - } - - $properties['gitUrl'] = $value; - - after_gitUrl: - - $value = $payload['has_downloads'] ?? null; - - if ($value === null) { - $missingFields[] = 'has_downloads'; - goto after_hasDownloads; - } - - $properties['hasDownloads'] = $value; - - after_hasDownloads: - - $value = $payload['has_issues'] ?? null; - - if ($value === null) { - $missingFields[] = 'has_issues'; - goto after_hasIssues; - } - - $properties['hasIssues'] = $value; - - after_hasIssues: - - $value = $payload['has_projects'] ?? null; - - if ($value === null) { - $missingFields[] = 'has_projects'; - goto after_hasProjects; - } - - $properties['hasProjects'] = $value; - - after_hasProjects: - - $value = $payload['has_wiki'] ?? null; - - if ($value === null) { - $missingFields[] = 'has_wiki'; - goto after_hasWiki; - } - - $properties['hasWiki'] = $value; - - after_hasWiki: - - $value = $payload['has_pages'] ?? null; - - if ($value === null) { - $missingFields[] = 'has_pages'; - goto after_hasPages; - } - - $properties['hasPages'] = $value; - - after_hasPages: - - $value = $payload['has_discussions'] ?? null; - - if ($value === null) { - $missingFields[] = 'has_discussions'; - goto after_hasDiscussions; - } - - $properties['hasDiscussions'] = $value; - - after_hasDiscussions: - - $value = $payload['homepage'] ?? null; - - if ($value === null) { - $properties['homepage'] = null; - goto after_homepage; - } - - $properties['homepage'] = $value; - - after_homepage: - - $value = $payload['language'] ?? null; - - if ($value === null) { - $properties['language'] = null; - goto after_language; - } - - $properties['language'] = $value; - - after_language: - - $value = $payload['master_branch'] ?? null; - - if ($value === null) { - $properties['masterBranch'] = null; - goto after_masterBranch; - } - - $properties['masterBranch'] = $value; - - after_masterBranch: - - $value = $payload['archived'] ?? null; - - if ($value === null) { - $missingFields[] = 'archived'; - goto after_archived; - } - - $properties['archived'] = $value; - - after_archived: - - $value = $payload['disabled'] ?? null; - - if ($value === null) { - $missingFields[] = 'disabled'; - goto after_disabled; - } - - $properties['disabled'] = $value; - - after_disabled: - - $value = $payload['visibility'] ?? null; - - if ($value === null) { - $properties['visibility'] = null; - goto after_visibility; - } - - $properties['visibility'] = $value; - - after_visibility: - - $value = $payload['mirror_url'] ?? null; - - if ($value === null) { - $properties['mirrorUrl'] = null; - goto after_mirrorUrl; - } - - $properties['mirrorUrl'] = $value; - - after_mirrorUrl: - - $value = $payload['open_issues'] ?? null; - - if ($value === null) { - $missingFields[] = 'open_issues'; - goto after_openIssues; - } - - $properties['openIssues'] = $value; - - after_openIssues: - - $value = $payload['open_issues_count'] ?? null; - - if ($value === null) { - $missingFields[] = 'open_issues_count'; - goto after_openIssuesCount; - } - - $properties['openIssuesCount'] = $value; - - after_openIssuesCount: - - $value = $payload['permissions'] ?? null; - - if ($value === null) { - $properties['permissions'] = null; - goto after_permissions; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'permissions'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️Repo⚡️Permissions($value); - } finally { - array_pop($this->hydrationStack); - } - } - - $properties['permissions'] = $value; - - after_permissions: - - $value = $payload['temp_clone_token'] ?? null; - - if ($value === null) { - $properties['tempCloneToken'] = null; - goto after_tempCloneToken; - } - - $properties['tempCloneToken'] = $value; - - after_tempCloneToken: - - $value = $payload['allow_merge_commit'] ?? null; - - if ($value === null) { - $properties['allowMergeCommit'] = null; - goto after_allowMergeCommit; - } - - $properties['allowMergeCommit'] = $value; - - after_allowMergeCommit: - - $value = $payload['allow_squash_merge'] ?? null; - - if ($value === null) { - $properties['allowSquashMerge'] = null; - goto after_allowSquashMerge; - } - - $properties['allowSquashMerge'] = $value; - - after_allowSquashMerge: - - $value = $payload['allow_rebase_merge'] ?? null; - - if ($value === null) { - $properties['allowRebaseMerge'] = null; - goto after_allowRebaseMerge; - } - - $properties['allowRebaseMerge'] = $value; - - after_allowRebaseMerge: - - $value = $payload['license'] ?? null; - - if ($value === null) { - $properties['license'] = null; - goto after_license; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'license'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️LicenseSimple($value); - } finally { - array_pop($this->hydrationStack); - } - } - - $properties['license'] = $value; - - after_license: - - $value = $payload['pushed_at'] ?? null; - - if ($value === null) { - $missingFields[] = 'pushed_at'; - goto after_pushedAt; - } - - $properties['pushedAt'] = $value; - - after_pushedAt: - - $value = $payload['size'] ?? null; - - if ($value === null) { - $missingFields[] = 'size'; - goto after_size; - } - - $properties['size'] = $value; - - after_size: - - $value = $payload['ssh_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'ssh_url'; - goto after_sshUrl; - } - - $properties['sshUrl'] = $value; - - after_sshUrl: - - $value = $payload['stargazers_count'] ?? null; - - if ($value === null) { - $missingFields[] = 'stargazers_count'; - goto after_stargazersCount; - } - - $properties['stargazersCount'] = $value; - - after_stargazersCount: - - $value = $payload['svn_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'svn_url'; - goto after_svnUrl; - } - - $properties['svnUrl'] = $value; - - after_svnUrl: - - $value = $payload['topics'] ?? null; - - if ($value === null) { - $properties['topics'] = null; - goto after_topics; - } - - $properties['topics'] = $value; - - after_topics: - - $value = $payload['watchers'] ?? null; - - if ($value === null) { - $missingFields[] = 'watchers'; - goto after_watchers; - } - - $properties['watchers'] = $value; - - after_watchers: - - $value = $payload['watchers_count'] ?? null; - - if ($value === null) { - $missingFields[] = 'watchers_count'; - goto after_watchersCount; - } - - $properties['watchersCount'] = $value; - - after_watchersCount: - - $value = $payload['created_at'] ?? null; - - if ($value === null) { - $missingFields[] = 'created_at'; - goto after_createdAt; - } - - $properties['createdAt'] = $value; - - after_createdAt: - - $value = $payload['updated_at'] ?? null; - - if ($value === null) { - $missingFields[] = 'updated_at'; - goto after_updatedAt; - } - - $properties['updatedAt'] = $value; - - after_updatedAt: - - $value = $payload['allow_forking'] ?? null; - - if ($value === null) { - $properties['allowForking'] = null; - goto after_allowForking; - } - - $properties['allowForking'] = $value; - - after_allowForking: - - $value = $payload['web_commit_signoff_required'] ?? null; - - if ($value === null) { - $properties['webCommitSignoffRequired'] = null; - goto after_webCommitSignoffRequired; - } - - $properties['webCommitSignoffRequired'] = $value; - - after_webCommitSignoffRequired: - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo', $exception, stack: $this->hydrationStack); - } - - if (count($missingFields) > 0) { - throw UnableToHydrateObject::dueToMissingFields(\ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo::class, $missingFields, stack: $this->hydrationStack); - } - - try { - return new \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo(...$properties); - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo', $exception, stack: $this->hydrationStack); - } - } - - private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️Repo⚡️Owner(array $payload): \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo\Owner - { - $properties = []; - $missingFields = []; - try { - $value = $payload['avatar_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'avatar_url'; - goto after_avatarUrl; - } - - $properties['avatarUrl'] = $value; - - after_avatarUrl: - - $value = $payload['events_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'events_url'; - goto after_eventsUrl; - } - - $properties['eventsUrl'] = $value; - - after_eventsUrl: - - $value = $payload['followers_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'followers_url'; - goto after_followersUrl; - } - - $properties['followersUrl'] = $value; - - after_followersUrl: - - $value = $payload['following_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'following_url'; - goto after_followingUrl; - } - - $properties['followingUrl'] = $value; - - after_followingUrl: - - $value = $payload['gists_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'gists_url'; - goto after_gistsUrl; - } - - $properties['gistsUrl'] = $value; - - after_gistsUrl: - - $value = $payload['gravatar_id'] ?? null; - - if ($value === null) { - $properties['gravatarId'] = null; - goto after_gravatarId; - } - - $properties['gravatarId'] = $value; - - after_gravatarId: - - $value = $payload['html_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'html_url'; - goto after_htmlUrl; - } - - $properties['htmlUrl'] = $value; - - after_htmlUrl: - - $value = $payload['id'] ?? null; - - if ($value === null) { - $missingFields[] = 'id'; - goto after_id; - } - - $properties['id'] = $value; - - after_id: - - $value = $payload['node_id'] ?? null; - - if ($value === null) { - $missingFields[] = 'node_id'; - goto after_nodeId; - } - - $properties['nodeId'] = $value; - - after_nodeId: - - $value = $payload['login'] ?? null; - - if ($value === null) { - $missingFields[] = 'login'; - goto after_login; - } - - $properties['login'] = $value; - - after_login: - - $value = $payload['organizations_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'organizations_url'; - goto after_organizationsUrl; - } - - $properties['organizationsUrl'] = $value; - - after_organizationsUrl: - - $value = $payload['received_events_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'received_events_url'; - goto after_receivedEventsUrl; - } - - $properties['receivedEventsUrl'] = $value; - - after_receivedEventsUrl: - - $value = $payload['repos_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'repos_url'; - goto after_reposUrl; - } - - $properties['reposUrl'] = $value; - - after_reposUrl: - - $value = $payload['site_admin'] ?? null; - - if ($value === null) { - $missingFields[] = 'site_admin'; - goto after_siteAdmin; - } - - $properties['siteAdmin'] = $value; - - after_siteAdmin: - - $value = $payload['starred_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'starred_url'; - goto after_starredUrl; - } - - $properties['starredUrl'] = $value; - - after_starredUrl: - - $value = $payload['subscriptions_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'subscriptions_url'; - goto after_subscriptionsUrl; - } - - $properties['subscriptionsUrl'] = $value; - - after_subscriptionsUrl: - - $value = $payload['type'] ?? null; - - if ($value === null) { - $missingFields[] = 'type'; - goto after_type; - } - - $properties['type'] = $value; - - after_type: - - $value = $payload['url'] ?? null; - - if ($value === null) { - $missingFields[] = 'url'; - goto after_url; - } - - $properties['url'] = $value; - - after_url: - - $value = $payload['user_view_type'] ?? null; - - if ($value === null) { - $properties['userViewType'] = null; - goto after_userViewType; - } - - $properties['userViewType'] = $value; - - after_userViewType: - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo\Owner', $exception, stack: $this->hydrationStack); - } - - if (count($missingFields) > 0) { - throw UnableToHydrateObject::dueToMissingFields(\ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo\Owner::class, $missingFields, stack: $this->hydrationStack); - } - - try { - return new \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo\Owner(...$properties); - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo\Owner', $exception, stack: $this->hydrationStack); - } - } - - private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️Repo⚡️Permissions(array $payload): \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo\Permissions - { - $properties = []; - $missingFields = []; - try { - $value = $payload['admin'] ?? null; - - if ($value === null) { - $missingFields[] = 'admin'; - goto after_admin; - } - - $properties['admin'] = $value; - - after_admin: - - $value = $payload['maintain'] ?? null; - - if ($value === null) { - $properties['maintain'] = null; - goto after_maintain; - } - - $properties['maintain'] = $value; - - after_maintain: - - $value = $payload['push'] ?? null; - - if ($value === null) { - $missingFields[] = 'push'; - goto after_push; - } - - $properties['push'] = $value; - - after_push: - - $value = $payload['triage'] ?? null; - - if ($value === null) { - $properties['triage'] = null; - goto after_triage; - } - - $properties['triage'] = $value; - - after_triage: - - $value = $payload['pull'] ?? null; - - if ($value === null) { - $missingFields[] = 'pull'; - goto after_pull; - } - - $properties['pull'] = $value; - - after_pull: - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo\Permissions', $exception, stack: $this->hydrationStack); - } - - if (count($missingFields) > 0) { - throw UnableToHydrateObject::dueToMissingFields(\ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo\Permissions::class, $missingFields, stack: $this->hydrationStack); - } - - try { - return new \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo\Permissions(...$properties); - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo\Permissions', $exception, stack: $this->hydrationStack); - } - } - - private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️LicenseSimple(array $payload): LicenseSimple - { - $properties = []; - $missingFields = []; - try { - $value = $payload['key'] ?? null; - - if ($value === null) { - $missingFields[] = 'key'; - goto after_key; - } - - $properties['key'] = $value; - - after_key: - - $value = $payload['name'] ?? null; - - if ($value === null) { - $missingFields[] = 'name'; - goto after_name; - } - - $properties['name'] = $value; - - after_name: - - $value = $payload['url'] ?? null; - - if ($value === null) { - $properties['url'] = null; - goto after_url; - } - - $properties['url'] = $value; - - after_url: - - $value = $payload['spdx_id'] ?? null; - - if ($value === null) { - $properties['spdxId'] = null; - goto after_spdxId; - } - - $properties['spdxId'] = $value; - - after_spdxId: - - $value = $payload['node_id'] ?? null; - - if ($value === null) { - $missingFields[] = 'node_id'; - goto after_nodeId; - } - - $properties['nodeId'] = $value; - - after_nodeId: - - $value = $payload['html_url'] ?? null; - - if ($value === null) { - $properties['htmlUrl'] = null; - goto after_htmlUrl; - } - - $properties['htmlUrl'] = $value; - - after_htmlUrl: - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\LicenseSimple', $exception, stack: $this->hydrationStack); - } - - if (count($missingFields) > 0) { - throw UnableToHydrateObject::dueToMissingFields(LicenseSimple::class, $missingFields, stack: $this->hydrationStack); - } - - try { - return new LicenseSimple(...$properties); - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\LicenseSimple', $exception, stack: $this->hydrationStack); - } - } - - private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️User(array $payload): \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\User - { - $properties = []; - $missingFields = []; - try { - $value = $payload['avatar_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'avatar_url'; - goto after_avatarUrl; - } - - $properties['avatarUrl'] = $value; - - after_avatarUrl: - - $value = $payload['events_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'events_url'; - goto after_eventsUrl; - } - - $properties['eventsUrl'] = $value; - - after_eventsUrl: - - $value = $payload['followers_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'followers_url'; - goto after_followersUrl; - } - - $properties['followersUrl'] = $value; - - after_followersUrl: - - $value = $payload['following_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'following_url'; - goto after_followingUrl; - } - - $properties['followingUrl'] = $value; - - after_followingUrl: - - $value = $payload['gists_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'gists_url'; - goto after_gistsUrl; - } - - $properties['gistsUrl'] = $value; - - after_gistsUrl: - - $value = $payload['gravatar_id'] ?? null; - - if ($value === null) { - $properties['gravatarId'] = null; - goto after_gravatarId; - } - - $properties['gravatarId'] = $value; - - after_gravatarId: - - $value = $payload['html_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'html_url'; - goto after_htmlUrl; - } - - $properties['htmlUrl'] = $value; - - after_htmlUrl: - - $value = $payload['id'] ?? null; - - if ($value === null) { - $missingFields[] = 'id'; - goto after_id; - } - - $properties['id'] = $value; - - after_id: - - $value = $payload['node_id'] ?? null; - - if ($value === null) { - $missingFields[] = 'node_id'; - goto after_nodeId; - } - - $properties['nodeId'] = $value; - - after_nodeId: - - $value = $payload['login'] ?? null; - - if ($value === null) { - $missingFields[] = 'login'; - goto after_login; - } - - $properties['login'] = $value; - - after_login: - - $value = $payload['organizations_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'organizations_url'; - goto after_organizationsUrl; - } - - $properties['organizationsUrl'] = $value; - - after_organizationsUrl: - - $value = $payload['received_events_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'received_events_url'; - goto after_receivedEventsUrl; - } - - $properties['receivedEventsUrl'] = $value; - - after_receivedEventsUrl: - - $value = $payload['repos_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'repos_url'; - goto after_reposUrl; - } - - $properties['reposUrl'] = $value; - - after_reposUrl: - - $value = $payload['site_admin'] ?? null; - - if ($value === null) { - $missingFields[] = 'site_admin'; - goto after_siteAdmin; - } - - $properties['siteAdmin'] = $value; - - after_siteAdmin: - - $value = $payload['starred_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'starred_url'; - goto after_starredUrl; - } - - $properties['starredUrl'] = $value; - - after_starredUrl: - - $value = $payload['subscriptions_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'subscriptions_url'; - goto after_subscriptionsUrl; - } - - $properties['subscriptionsUrl'] = $value; - - after_subscriptionsUrl: - - $value = $payload['type'] ?? null; - - if ($value === null) { - $missingFields[] = 'type'; - goto after_type; - } - - $properties['type'] = $value; - - after_type: - - $value = $payload['url'] ?? null; - - if ($value === null) { - $missingFields[] = 'url'; - goto after_url; - } - - $properties['url'] = $value; - - after_url: - - $value = $payload['user_view_type'] ?? null; - - if ($value === null) { - $properties['userViewType'] = null; - goto after_userViewType; - } - - $properties['userViewType'] = $value; - - after_userViewType: - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\User', $exception, stack: $this->hydrationStack); - } - - if (count($missingFields) > 0) { - throw UnableToHydrateObject::dueToMissingFields(\ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\User::class, $missingFields, stack: $this->hydrationStack); - } - - try { - return new \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\User(...$properties); - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\User', $exception, stack: $this->hydrationStack); - } - } - - private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Links(array $payload): Links - { - $properties = []; - $missingFields = []; - try { - $value = $payload['comments'] ?? null; - - if ($value === null) { - $missingFields[] = 'comments'; - goto after_comments; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'comments'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Link($value); - } finally { - array_pop($this->hydrationStack); - } - } - - $properties['comments'] = $value; - - after_comments: - - $value = $payload['commits'] ?? null; - - if ($value === null) { - $missingFields[] = 'commits'; - goto after_commits; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'commits'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Link($value); - } finally { - array_pop($this->hydrationStack); - } - } - - $properties['commits'] = $value; - - after_commits: - - $value = $payload['statuses'] ?? null; - - if ($value === null) { - $missingFields[] = 'statuses'; - goto after_statuses; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'statuses'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Link($value); - } finally { - array_pop($this->hydrationStack); - } - } - - $properties['statuses'] = $value; - - after_statuses: - - $value = $payload['html'] ?? null; - - if ($value === null) { - $missingFields[] = 'html'; - goto after_html; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'html'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Link($value); - } finally { - array_pop($this->hydrationStack); - } - } - - $properties['html'] = $value; - - after_html: - - $value = $payload['issue'] ?? null; - - if ($value === null) { - $missingFields[] = 'issue'; - goto after_issue; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'issue'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Link($value); - } finally { - array_pop($this->hydrationStack); - } - } - - $properties['issue'] = $value; - - after_issue: - - $value = $payload['review_comments'] ?? null; - - if ($value === null) { - $missingFields[] = 'review_comments'; - goto after_reviewComments; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'reviewComments'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Link($value); - } finally { - array_pop($this->hydrationStack); - } - } - - $properties['reviewComments'] = $value; - - after_reviewComments: - - $value = $payload['review_comment'] ?? null; - - if ($value === null) { - $missingFields[] = 'review_comment'; - goto after_reviewComment; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'reviewComment'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Link($value); - } finally { - array_pop($this->hydrationStack); - } - } - - $properties['reviewComment'] = $value; - - after_reviewComment: - - $value = $payload['self'] ?? null; - - if ($value === null) { - $missingFields[] = 'self'; - goto after_self; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'self'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Link($value); - } finally { - array_pop($this->hydrationStack); - } - } - - $properties['self'] = $value; - - after_self: - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Links', $exception, stack: $this->hydrationStack); - } - - if (count($missingFields) > 0) { - throw UnableToHydrateObject::dueToMissingFields(Links::class, $missingFields, stack: $this->hydrationStack); - } - - try { - return new Links(...$properties); - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Links', $exception, stack: $this->hydrationStack); - } - } - - private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Link(array $payload): Link - { - $properties = []; - $missingFields = []; - try { - $value = $payload['href'] ?? null; - - if ($value === null) { - $missingFields[] = 'href'; - goto after_href; - } - - $properties['href'] = $value; - - after_href: - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\Link', $exception, stack: $this->hydrationStack); - } - - if (count($missingFields) > 0) { - throw UnableToHydrateObject::dueToMissingFields(Link::class, $missingFields, stack: $this->hydrationStack); - } - - try { - return new Link(...$properties); - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\Link', $exception, stack: $this->hydrationStack); - } - } - - private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️AutoMerge(array $payload): AutoMerge - { - $properties = []; - $missingFields = []; - try { - $value = $payload['enabled_by'] ?? null; - - if ($value === null) { - $missingFields[] = 'enabled_by'; - goto after_enabledBy; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'enabledBy'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleUser($value); - } finally { - array_pop($this->hydrationStack); - } - } - - $properties['enabledBy'] = $value; - - after_enabledBy: - - $value = $payload['merge_method'] ?? null; - - if ($value === null) { - $missingFields[] = 'merge_method'; - goto after_mergeMethod; - } - - $properties['mergeMethod'] = $value; - - after_mergeMethod: - - $value = $payload['commit_title'] ?? null; - - if ($value === null) { - $missingFields[] = 'commit_title'; - goto after_commitTitle; - } - - $properties['commitTitle'] = $value; - - after_commitTitle: - - $value = $payload['commit_message'] ?? null; - - if ($value === null) { - $missingFields[] = 'commit_message'; - goto after_commitMessage; - } - - $properties['commitMessage'] = $value; - - after_commitMessage: - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\AutoMerge', $exception, stack: $this->hydrationStack); - } - - if (count($missingFields) > 0) { - throw UnableToHydrateObject::dueToMissingFields(AutoMerge::class, $missingFields, stack: $this->hydrationStack); - } - - try { - return new AutoMerge(...$properties); - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\AutoMerge', $exception, stack: $this->hydrationStack); - } - } - - private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️BasicError(array $payload): BasicError - { - $properties = []; - $missingFields = []; - try { - $value = $payload['message'] ?? null; - - if ($value === null) { - $properties['message'] = null; - goto after_message; - } - - $properties['message'] = $value; - - after_message: - - $value = $payload['documentation_url'] ?? null; - - if ($value === null) { - $properties['documentationUrl'] = null; - goto after_documentationUrl; - } - - $properties['documentationUrl'] = $value; - - after_documentationUrl: - - $value = $payload['url'] ?? null; - - if ($value === null) { - $properties['url'] = null; - goto after_url; - } - - $properties['url'] = $value; - - after_url: - - $value = $payload['status'] ?? null; - - if ($value === null) { - $properties['status'] = null; - goto after_status; - } - - $properties['status'] = $value; - - after_status: - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\BasicError', $exception, stack: $this->hydrationStack); - } - - if (count($missingFields) > 0) { - throw UnableToHydrateObject::dueToMissingFields(BasicError::class, $missingFields, stack: $this->hydrationStack); - } - - try { - return new BasicError(...$properties); - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\BasicError', $exception, stack: $this->hydrationStack); - } - } - - private function serializeViaTypeMap(string $accessor, object $object, array $payloadToTypeMap): array - { - foreach ($payloadToTypeMap as $payloadType => [$valueType, $method]) { - if (is_a($object, $valueType)) { - return [$accessor => $payloadType] + $this->{$method}($object); - } - } - - throw new LogicException('No type mapped for object of class: ' . $object::class); - } - - public function serializeObject(object $object): mixed - { - return $this->serializeObjectOfType($object, $object::class); - } - - /** - * @param T $object - * @param class-string $className - * - * @template T - */ - public function serializeObjectOfType(object $object, string $className): mixed - { - try { - return match ($className) { - 'array' => $this->serializeValuearray($object), - 'Ramsey\Uuid\UuidInterface' => $this->serializeValueRamsey⚡️Uuid⚡️UuidInterface($object), - 'DateTime' => $this->serializeValueDateTime($object), - 'DateTimeImmutable' => $this->serializeValueDateTimeImmutable($object), - 'DateTimeInterface' => $this->serializeValueDateTimeInterface($object), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\ValidationError' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️ValidationError($object), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest($object), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\SimpleUser' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleUser($object), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\Milestone' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Milestone($object), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head($object), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo($object), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo\Owner' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo⚡️Owner($object), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo\Permissions' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo⚡️Permissions($object), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo\License' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo⚡️License($object), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\User' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️User($object), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base($object), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️Repo($object), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo\Owner' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️Repo⚡️Owner($object), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo\Permissions' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️Repo⚡️Permissions($object), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\LicenseSimple' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️LicenseSimple($object), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\User' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️User($object), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Links' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Links($object), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\Link' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Link($object), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\AutoMerge' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️AutoMerge($object), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\BasicError' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️BasicError($object), - default => throw new LogicException("No serialization defined for $className"), - }; - } catch (Throwable $exception) { - throw UnableToSerializeObject::dueToError($className, $exception); - } - } - - private function serializeValuearray(mixed $value): mixed - { - static $serializer; - - if ($serializer === null) { - $serializer = new SerializeArrayItems(...[]); - } - - return $serializer->serialize($value, $this); - } - - private function serializeValueRamsey⚡️Uuid⚡️UuidInterface(mixed $value): mixed - { - static $serializer; - - if ($serializer === null) { - $serializer = new SerializeUuidToString(...[]); - } - - return $serializer->serialize($value, $this); - } - - private function serializeValueDateTime(mixed $value): mixed - { - static $serializer; - - if ($serializer === null) { - $serializer = new SerializeDateTime(...[]); - } - - return $serializer->serialize($value, $this); - } - - private function serializeValueDateTimeImmutable(mixed $value): mixed - { - static $serializer; - - if ($serializer === null) { - $serializer = new SerializeDateTime(...[]); - } - - return $serializer->serialize($value, $this); - } - - private function serializeValueDateTimeInterface(mixed $value): mixed - { - static $serializer; - - if ($serializer === null) { - $serializer = new SerializeDateTime(...[]); - } - - return $serializer->serialize($value, $this); - } - - private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️ValidationError(mixed $object): mixed - { - assert($object instanceof ValidationError); - $result = []; - - $message = $object->message; - after_message: $result['message'] = $message; - - $documentationUrl = $object->documentationUrl; - after_documentationUrl: $result['documentation_url'] = $documentationUrl; - - $errors = $object->errors; - - if ($errors === null) { - goto after_errors; - } - - static $errorsSerializer0; - - if ($errorsSerializer0 === null) { - $errorsSerializer0 = new SerializeArrayItems(...[]); - } - - $errors = $errorsSerializer0->serialize($errors, $this); - after_errors: $result['errors'] = $errors; - - return $result; - } - - private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest(mixed $object): mixed - { - assert($object instanceof PullRequest); - $result = []; - - $url = $object->url; - after_url: $result['url'] = $url; - - $id = $object->id; - after_id: $result['id'] = $id; - - $nodeId = $object->nodeId; - after_nodeId: $result['node_id'] = $nodeId; - - $htmlUrl = $object->htmlUrl; - after_htmlUrl: $result['html_url'] = $htmlUrl; - - $diffUrl = $object->diffUrl; - after_diffUrl: $result['diff_url'] = $diffUrl; - - $patchUrl = $object->patchUrl; - after_patchUrl: $result['patch_url'] = $patchUrl; - - $issueUrl = $object->issueUrl; - after_issueUrl: $result['issue_url'] = $issueUrl; - - $commitsUrl = $object->commitsUrl; - after_commitsUrl: $result['commits_url'] = $commitsUrl; - - $reviewCommentsUrl = $object->reviewCommentsUrl; - after_reviewCommentsUrl: $result['review_comments_url'] = $reviewCommentsUrl; - - $reviewCommentUrl = $object->reviewCommentUrl; - after_reviewCommentUrl: $result['review_comment_url'] = $reviewCommentUrl; - - $commentsUrl = $object->commentsUrl; - after_commentsUrl: $result['comments_url'] = $commentsUrl; - - $statusesUrl = $object->statusesUrl; - after_statusesUrl: $result['statuses_url'] = $statusesUrl; - - $number = $object->number; - after_number: $result['number'] = $number; - - $state = $object->state; - after_state: $result['state'] = $state; - - $locked = $object->locked; - after_locked: $result['locked'] = $locked; - - $title = $object->title; - after_title: $result['title'] = $title; - - $user = $object->user; - $user = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleUser($user); - after_user: $result['user'] = $user; - - $body = $object->body; - - if ($body === null) { - goto after_body; - } - - after_body: $result['body'] = $body; - - $labels = $object->labels; - static $labelsSerializer0; - - if ($labelsSerializer0 === null) { - $labelsSerializer0 = new SerializeArrayItems(...[]); - } - - $labels = $labelsSerializer0->serialize($labels, $this); - after_labels: $result['labels'] = $labels; - - $milestone = $object->milestone; - - if ($milestone === null) { - goto after_milestone; - } - - $milestone = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Milestone($milestone); - after_milestone: $result['milestone'] = $milestone; - - $activeLockReason = $object->activeLockReason; - - if ($activeLockReason === null) { - goto after_activeLockReason; - } - - after_activeLockReason: $result['active_lock_reason'] = $activeLockReason; - - $createdAt = $object->createdAt; - after_createdAt: $result['created_at'] = $createdAt; - - $updatedAt = $object->updatedAt; - after_updatedAt: $result['updated_at'] = $updatedAt; - - $closedAt = $object->closedAt; - - if ($closedAt === null) { - goto after_closedAt; - } - - after_closedAt: $result['closed_at'] = $closedAt; - - $mergedAt = $object->mergedAt; - - if ($mergedAt === null) { - goto after_mergedAt; - } - - after_mergedAt: $result['merged_at'] = $mergedAt; - - $mergeCommitSha = $object->mergeCommitSha; - - if ($mergeCommitSha === null) { - goto after_mergeCommitSha; - } - - after_mergeCommitSha: $result['merge_commit_sha'] = $mergeCommitSha; - - $assignee = $object->assignee; - - if ($assignee === null) { - goto after_assignee; - } - - $assignee = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleUser($assignee); - after_assignee: $result['assignee'] = $assignee; - - $assignees = $object->assignees; - - if ($assignees === null) { - goto after_assignees; - } - - static $assigneesSerializer0; - - if ($assigneesSerializer0 === null) { - $assigneesSerializer0 = new SerializeArrayItems(...[]); - } - - $assignees = $assigneesSerializer0->serialize($assignees, $this); - after_assignees: $result['assignees'] = $assignees; - - $requestedReviewers = $object->requestedReviewers; - - if ($requestedReviewers === null) { - goto after_requestedReviewers; - } - - static $requestedReviewersSerializer0; - - if ($requestedReviewersSerializer0 === null) { - $requestedReviewersSerializer0 = new SerializeArrayItems(...[]); - } - - $requestedReviewers = $requestedReviewersSerializer0->serialize($requestedReviewers, $this); - after_requestedReviewers: $result['requested_reviewers'] = $requestedReviewers; - - $requestedTeams = $object->requestedTeams; - - if ($requestedTeams === null) { - goto after_requestedTeams; - } - - static $requestedTeamsSerializer0; - - if ($requestedTeamsSerializer0 === null) { - $requestedTeamsSerializer0 = new SerializeArrayItems(...[]); - } - - $requestedTeams = $requestedTeamsSerializer0->serialize($requestedTeams, $this); - after_requestedTeams: $result['requested_teams'] = $requestedTeams; - - $head = $object->head; - $head = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head($head); - after_head: $result['head'] = $head; - - $base = $object->base; - $base = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base($base); - after_base: $result['base'] = $base; - - $links = $object->links; - $links = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Links($links); - after_links: $result['_links'] = $links; - - $authorAssociation = $object->authorAssociation; - after_authorAssociation: $result['author_association'] = $authorAssociation; - - $autoMerge = $object->autoMerge; - - if ($autoMerge === null) { - goto after_autoMerge; - } - - $autoMerge = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️AutoMerge($autoMerge); - after_autoMerge: $result['auto_merge'] = $autoMerge; - - $draft = $object->draft; - - if ($draft === null) { - goto after_draft; - } - - after_draft: $result['draft'] = $draft; - - $merged = $object->merged; - after_merged: $result['merged'] = $merged; - - $mergeable = $object->mergeable; - - if ($mergeable === null) { - goto after_mergeable; - } - - after_mergeable: $result['mergeable'] = $mergeable; - - $rebaseable = $object->rebaseable; - - if ($rebaseable === null) { - goto after_rebaseable; - } - - after_rebaseable: $result['rebaseable'] = $rebaseable; - - $mergeableState = $object->mergeableState; - after_mergeableState: $result['mergeable_state'] = $mergeableState; - - $mergedBy = $object->mergedBy; - - if ($mergedBy === null) { - goto after_mergedBy; - } - - $mergedBy = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleUser($mergedBy); - after_mergedBy: $result['merged_by'] = $mergedBy; - - $comments = $object->comments; - after_comments: $result['comments'] = $comments; - - $reviewComments = $object->reviewComments; - after_reviewComments: $result['review_comments'] = $reviewComments; - - $maintainerCanModify = $object->maintainerCanModify; - after_maintainerCanModify: $result['maintainer_can_modify'] = $maintainerCanModify; - - $commits = $object->commits; - after_commits: $result['commits'] = $commits; - - $additions = $object->additions; - after_additions: $result['additions'] = $additions; - - $deletions = $object->deletions; - after_deletions: $result['deletions'] = $deletions; - - $changedFiles = $object->changedFiles; - after_changedFiles: $result['changed_files'] = $changedFiles; - - return $result; - } - - private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleUser(mixed $object): mixed - { - assert($object instanceof SimpleUser); - $result = []; - - $name = $object->name; - - if ($name === null) { - goto after_name; - } - - after_name: $result['name'] = $name; - - $email = $object->email; - - if ($email === null) { - goto after_email; - } - - after_email: $result['email'] = $email; - - $login = $object->login; - after_login: $result['login'] = $login; - - $id = $object->id; - after_id: $result['id'] = $id; - - $nodeId = $object->nodeId; - after_nodeId: $result['node_id'] = $nodeId; - - $avatarUrl = $object->avatarUrl; - after_avatarUrl: $result['avatar_url'] = $avatarUrl; - - $gravatarId = $object->gravatarId; - - if ($gravatarId === null) { - goto after_gravatarId; - } - - after_gravatarId: $result['gravatar_id'] = $gravatarId; - - $url = $object->url; - after_url: $result['url'] = $url; - - $htmlUrl = $object->htmlUrl; - after_htmlUrl: $result['html_url'] = $htmlUrl; - - $followersUrl = $object->followersUrl; - after_followersUrl: $result['followers_url'] = $followersUrl; - - $followingUrl = $object->followingUrl; - after_followingUrl: $result['following_url'] = $followingUrl; - - $gistsUrl = $object->gistsUrl; - after_gistsUrl: $result['gists_url'] = $gistsUrl; - - $starredUrl = $object->starredUrl; - after_starredUrl: $result['starred_url'] = $starredUrl; - - $subscriptionsUrl = $object->subscriptionsUrl; - after_subscriptionsUrl: $result['subscriptions_url'] = $subscriptionsUrl; - - $organizationsUrl = $object->organizationsUrl; - after_organizationsUrl: $result['organizations_url'] = $organizationsUrl; - - $reposUrl = $object->reposUrl; - after_reposUrl: $result['repos_url'] = $reposUrl; - - $eventsUrl = $object->eventsUrl; - after_eventsUrl: $result['events_url'] = $eventsUrl; - - $receivedEventsUrl = $object->receivedEventsUrl; - after_receivedEventsUrl: $result['received_events_url'] = $receivedEventsUrl; - - $type = $object->type; - after_type: $result['type'] = $type; - - $siteAdmin = $object->siteAdmin; - after_siteAdmin: $result['site_admin'] = $siteAdmin; - - $starredAt = $object->starredAt; - - if ($starredAt === null) { - goto after_starredAt; - } - - after_starredAt: $result['starred_at'] = $starredAt; - - $userViewType = $object->userViewType; - - if ($userViewType === null) { - goto after_userViewType; + /** + * @param T $object + * @param class-string $className + * + * @template T + */ + public function serializeObjectOfType(object $object, string $className): mixed + { + try { + return match ($className) { + 'array' => $this->serializeValuearray($object), + 'Ramsey\Uuid\UuidInterface' => $this->serializeValueRamsey⚡️Uuid⚡️UuidInterface($object), + 'DateTime' => $this->serializeValueDateTime($object), + 'DateTimeImmutable' => $this->serializeValueDateTimeImmutable($object), + 'DateTimeInterface' => $this->serializeValueDateTimeInterface($object), + 'ApiClients\Client\GitHubEnterpriseCloud\Schema\ValidationError' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️ValidationError($object), + 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest($object), + 'ApiClients\Client\GitHubEnterpriseCloud\Schema\SimpleUser' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleUser($object), + 'ApiClients\Client\GitHubEnterpriseCloud\Schema\Milestone' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Milestone($object), + 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head($object), + 'ApiClients\Client\GitHubEnterpriseCloud\Schema\Repository' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Repository($object), + 'ApiClients\Client\GitHubEnterpriseCloud\Schema\LicenseSimple' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️LicenseSimple($object), + 'ApiClients\Client\GitHubEnterpriseCloud\Schema\Repository\Permissions' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Repository⚡️Permissions($object), + 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base($object), + 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Links' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Links($object), + 'ApiClients\Client\GitHubEnterpriseCloud\Schema\Link' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Link($object), + 'ApiClients\Client\GitHubEnterpriseCloud\Schema\AutoMerge' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️AutoMerge($object), + 'ApiClients\Client\GitHubEnterpriseCloud\Schema\BasicError' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️BasicError($object), + default => throw new LogicException("No serialization defined for $className"), + }; + } catch (Throwable $exception) { + throw UnableToSerializeObject::dueToError($className, $exception); } - - after_userViewType: $result['user_view_type'] = $userViewType; - - return $result; } - private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Milestone(mixed $object): mixed + private function serializeValuearray(mixed $value): mixed { - assert($object instanceof Milestone); - $result = []; - - $url = $object->url; - after_url: $result['url'] = $url; - - $htmlUrl = $object->htmlUrl; - after_htmlUrl: $result['html_url'] = $htmlUrl; - - $labelsUrl = $object->labelsUrl; - after_labelsUrl: $result['labels_url'] = $labelsUrl; - - $id = $object->id; - after_id: $result['id'] = $id; - - $nodeId = $object->nodeId; - after_nodeId: $result['node_id'] = $nodeId; - - $number = $object->number; - after_number: $result['number'] = $number; - - $state = $object->state; - after_state: $result['state'] = $state; - - $title = $object->title; - after_title: $result['title'] = $title; - - $description = $object->description; + static $serializer; - if ($description === null) { - goto after_description; + if ($serializer === null) { + $serializer = new SerializeArrayItems(...[]); } - after_description: $result['description'] = $description; + return $serializer->serialize($value, $this); + } - $creator = $object->creator; + private function serializeValueRamsey⚡️Uuid⚡️UuidInterface(mixed $value): mixed + { + static $serializer; - if ($creator === null) { - goto after_creator; + if ($serializer === null) { + $serializer = new SerializeUuidToString(...[]); } - $creator = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleUser($creator); - after_creator: $result['creator'] = $creator; - - $openIssues = $object->openIssues; - after_openIssues: $result['open_issues'] = $openIssues; - - $closedIssues = $object->closedIssues; - after_closedIssues: $result['closed_issues'] = $closedIssues; - - $createdAt = $object->createdAt; - after_createdAt: $result['created_at'] = $createdAt; - - $updatedAt = $object->updatedAt; - after_updatedAt: $result['updated_at'] = $updatedAt; + return $serializer->serialize($value, $this); + } - $closedAt = $object->closedAt; + private function serializeValueDateTime(mixed $value): mixed + { + static $serializer; - if ($closedAt === null) { - goto after_closedAt; + if ($serializer === null) { + $serializer = new SerializeDateTime(...[]); } - after_closedAt: $result['closed_at'] = $closedAt; + return $serializer->serialize($value, $this); + } - $dueOn = $object->dueOn; + private function serializeValueDateTimeImmutable(mixed $value): mixed + { + static $serializer; - if ($dueOn === null) { - goto after_dueOn; + if ($serializer === null) { + $serializer = new SerializeDateTime(...[]); } - after_dueOn: $result['due_on'] = $dueOn; - - return $result; + return $serializer->serialize($value, $this); } - private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head(mixed $object): mixed + private function serializeValueDateTimeInterface(mixed $value): mixed { - assert($object instanceof Head); - $result = []; - - $label = $object->label; - after_label: $result['label'] = $label; - - $ref = $object->ref; - after_ref: $result['ref'] = $ref; - - $repo = $object->repo; + static $serializer; - if ($repo === null) { - goto after_repo; + if ($serializer === null) { + $serializer = new SerializeDateTime(...[]); } - $repo = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo($repo); - after_repo: $result['repo'] = $repo; - - $sha = $object->sha; - after_sha: $result['sha'] = $sha; - - $user = $object->user; - $user = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️User($user); - after_user: $result['user'] = $user; - - return $result; + return $serializer->serialize($value, $this); } - private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo(mixed $object): mixed + private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️ValidationError(mixed $object): mixed { - assert($object instanceof Repo); + assert($object instanceof ValidationError); $result = []; - $archiveUrl = $object->archiveUrl; - after_archiveUrl: $result['archive_url'] = $archiveUrl; - - $assigneesUrl = $object->assigneesUrl; - after_assigneesUrl: $result['assignees_url'] = $assigneesUrl; - - $blobsUrl = $object->blobsUrl; - after_blobsUrl: $result['blobs_url'] = $blobsUrl; - - $branchesUrl = $object->branchesUrl; - after_branchesUrl: $result['branches_url'] = $branchesUrl; - - $collaboratorsUrl = $object->collaboratorsUrl; - after_collaboratorsUrl: $result['collaborators_url'] = $collaboratorsUrl; - - $commentsUrl = $object->commentsUrl; - after_commentsUrl: $result['comments_url'] = $commentsUrl; - - $commitsUrl = $object->commitsUrl; - after_commitsUrl: $result['commits_url'] = $commitsUrl; - - $compareUrl = $object->compareUrl; - after_compareUrl: $result['compare_url'] = $compareUrl; - - $contentsUrl = $object->contentsUrl; - after_contentsUrl: $result['contents_url'] = $contentsUrl; - - $contributorsUrl = $object->contributorsUrl; - after_contributorsUrl: $result['contributors_url'] = $contributorsUrl; + $message = $object->message; + after_message: $result['message'] = $message; - $deploymentsUrl = $object->deploymentsUrl; - after_deploymentsUrl: $result['deployments_url'] = $deploymentsUrl; + $documentationUrl = $object->documentationUrl; + after_documentationUrl: $result['documentation_url'] = $documentationUrl; - $description = $object->description; + $errors = $object->errors; - if ($description === null) { - goto after_description; + if ($errors === null) { + goto after_errors; } - after_description: $result['description'] = $description; - - $downloadsUrl = $object->downloadsUrl; - after_downloadsUrl: $result['downloads_url'] = $downloadsUrl; - - $eventsUrl = $object->eventsUrl; - after_eventsUrl: $result['events_url'] = $eventsUrl; - - $fork = $object->fork; - after_fork: $result['fork'] = $fork; - - $forksUrl = $object->forksUrl; - after_forksUrl: $result['forks_url'] = $forksUrl; - - $fullName = $object->fullName; - after_fullName: $result['full_name'] = $fullName; + static $errorsSerializer0; - $gitCommitsUrl = $object->gitCommitsUrl; - after_gitCommitsUrl: $result['git_commits_url'] = $gitCommitsUrl; + if ($errorsSerializer0 === null) { + $errorsSerializer0 = new SerializeArrayItems(...[]); + } - $gitRefsUrl = $object->gitRefsUrl; - after_gitRefsUrl: $result['git_refs_url'] = $gitRefsUrl; + $errors = $errorsSerializer0->serialize($errors, $this); + after_errors: $result['errors'] = $errors; - $gitTagsUrl = $object->gitTagsUrl; - after_gitTagsUrl: $result['git_tags_url'] = $gitTagsUrl; + return $result; + } - $hooksUrl = $object->hooksUrl; - after_hooksUrl: $result['hooks_url'] = $hooksUrl; + private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest(mixed $object): mixed + { + assert($object instanceof PullRequest); + $result = []; - $htmlUrl = $object->htmlUrl; - after_htmlUrl: $result['html_url'] = $htmlUrl; + $url = $object->url; + after_url: $result['url'] = $url; $id = $object->id; after_id: $result['id'] = $id; @@ -5617,296 +3132,287 @@ private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseClou $nodeId = $object->nodeId; after_nodeId: $result['node_id'] = $nodeId; - $issueCommentUrl = $object->issueCommentUrl; - after_issueCommentUrl: $result['issue_comment_url'] = $issueCommentUrl; - - $issueEventsUrl = $object->issueEventsUrl; - after_issueEventsUrl: $result['issue_events_url'] = $issueEventsUrl; - - $issuesUrl = $object->issuesUrl; - after_issuesUrl: $result['issues_url'] = $issuesUrl; - - $keysUrl = $object->keysUrl; - after_keysUrl: $result['keys_url'] = $keysUrl; - - $labelsUrl = $object->labelsUrl; - after_labelsUrl: $result['labels_url'] = $labelsUrl; - - $languagesUrl = $object->languagesUrl; - after_languagesUrl: $result['languages_url'] = $languagesUrl; - - $mergesUrl = $object->mergesUrl; - after_mergesUrl: $result['merges_url'] = $mergesUrl; - - $milestonesUrl = $object->milestonesUrl; - after_milestonesUrl: $result['milestones_url'] = $milestonesUrl; + $htmlUrl = $object->htmlUrl; + after_htmlUrl: $result['html_url'] = $htmlUrl; - $name = $object->name; - after_name: $result['name'] = $name; + $diffUrl = $object->diffUrl; + after_diffUrl: $result['diff_url'] = $diffUrl; - $notificationsUrl = $object->notificationsUrl; - after_notificationsUrl: $result['notifications_url'] = $notificationsUrl; + $patchUrl = $object->patchUrl; + after_patchUrl: $result['patch_url'] = $patchUrl; - $owner = $object->owner; - $owner = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo⚡️Owner($owner); - after_owner: $result['owner'] = $owner; + $issueUrl = $object->issueUrl; + after_issueUrl: $result['issue_url'] = $issueUrl; - $private = $object->private; - after_private: $result['private'] = $private; + $commitsUrl = $object->commitsUrl; + after_commitsUrl: $result['commits_url'] = $commitsUrl; - $pullsUrl = $object->pullsUrl; - after_pullsUrl: $result['pulls_url'] = $pullsUrl; + $reviewCommentsUrl = $object->reviewCommentsUrl; + after_reviewCommentsUrl: $result['review_comments_url'] = $reviewCommentsUrl; - $releasesUrl = $object->releasesUrl; - after_releasesUrl: $result['releases_url'] = $releasesUrl; + $reviewCommentUrl = $object->reviewCommentUrl; + after_reviewCommentUrl: $result['review_comment_url'] = $reviewCommentUrl; - $stargazersUrl = $object->stargazersUrl; - after_stargazersUrl: $result['stargazers_url'] = $stargazersUrl; + $commentsUrl = $object->commentsUrl; + after_commentsUrl: $result['comments_url'] = $commentsUrl; $statusesUrl = $object->statusesUrl; after_statusesUrl: $result['statuses_url'] = $statusesUrl; - $subscribersUrl = $object->subscribersUrl; - after_subscribersUrl: $result['subscribers_url'] = $subscribersUrl; - - $subscriptionUrl = $object->subscriptionUrl; - after_subscriptionUrl: $result['subscription_url'] = $subscriptionUrl; + $number = $object->number; + after_number: $result['number'] = $number; - $tagsUrl = $object->tagsUrl; - after_tagsUrl: $result['tags_url'] = $tagsUrl; + $state = $object->state; + after_state: $result['state'] = $state; - $teamsUrl = $object->teamsUrl; - after_teamsUrl: $result['teams_url'] = $teamsUrl; + $locked = $object->locked; + after_locked: $result['locked'] = $locked; - $treesUrl = $object->treesUrl; - after_treesUrl: $result['trees_url'] = $treesUrl; + $title = $object->title; + after_title: $result['title'] = $title; - $url = $object->url; - after_url: $result['url'] = $url; + $user = $object->user; + $user = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleUser($user); + after_user: $result['user'] = $user; - $cloneUrl = $object->cloneUrl; - after_cloneUrl: $result['clone_url'] = $cloneUrl; + $body = $object->body; - $defaultBranch = $object->defaultBranch; - after_defaultBranch: $result['default_branch'] = $defaultBranch; + if ($body === null) { + goto after_body; + } - $forks = $object->forks; - after_forks: $result['forks'] = $forks; + after_body: $result['body'] = $body; - $forksCount = $object->forksCount; - after_forksCount: $result['forks_count'] = $forksCount; + $labels = $object->labels; + static $labelsSerializer0; - $gitUrl = $object->gitUrl; - after_gitUrl: $result['git_url'] = $gitUrl; + if ($labelsSerializer0 === null) { + $labelsSerializer0 = new SerializeArrayItems(...[]); + } - $hasDownloads = $object->hasDownloads; - after_hasDownloads: $result['has_downloads'] = $hasDownloads; + $labels = $labelsSerializer0->serialize($labels, $this); + after_labels: $result['labels'] = $labels; - $hasIssues = $object->hasIssues; - after_hasIssues: $result['has_issues'] = $hasIssues; + $milestone = $object->milestone; - $hasProjects = $object->hasProjects; - after_hasProjects: $result['has_projects'] = $hasProjects; + if ($milestone === null) { + goto after_milestone; + } - $hasWiki = $object->hasWiki; - after_hasWiki: $result['has_wiki'] = $hasWiki; + $milestone = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Milestone($milestone); + after_milestone: $result['milestone'] = $milestone; - $hasPages = $object->hasPages; - after_hasPages: $result['has_pages'] = $hasPages; + $activeLockReason = $object->activeLockReason; - $hasDiscussions = $object->hasDiscussions; - after_hasDiscussions: $result['has_discussions'] = $hasDiscussions; + if ($activeLockReason === null) { + goto after_activeLockReason; + } - $homepage = $object->homepage; + after_activeLockReason: $result['active_lock_reason'] = $activeLockReason; - if ($homepage === null) { - goto after_homepage; - } + $createdAt = $object->createdAt; + after_createdAt: $result['created_at'] = $createdAt; - after_homepage: $result['homepage'] = $homepage; + $updatedAt = $object->updatedAt; + after_updatedAt: $result['updated_at'] = $updatedAt; - $language = $object->language; + $closedAt = $object->closedAt; - if ($language === null) { - goto after_language; + if ($closedAt === null) { + goto after_closedAt; } - after_language: $result['language'] = $language; + after_closedAt: $result['closed_at'] = $closedAt; - $masterBranch = $object->masterBranch; + $mergedAt = $object->mergedAt; - if ($masterBranch === null) { - goto after_masterBranch; + if ($mergedAt === null) { + goto after_mergedAt; } - after_masterBranch: $result['master_branch'] = $masterBranch; - - $archived = $object->archived; - after_archived: $result['archived'] = $archived; - - $disabled = $object->disabled; - after_disabled: $result['disabled'] = $disabled; + after_mergedAt: $result['merged_at'] = $mergedAt; - $visibility = $object->visibility; + $mergeCommitSha = $object->mergeCommitSha; - if ($visibility === null) { - goto after_visibility; + if ($mergeCommitSha === null) { + goto after_mergeCommitSha; } - after_visibility: $result['visibility'] = $visibility; + after_mergeCommitSha: $result['merge_commit_sha'] = $mergeCommitSha; - $mirrorUrl = $object->mirrorUrl; + $assignee = $object->assignee; - if ($mirrorUrl === null) { - goto after_mirrorUrl; + if ($assignee === null) { + goto after_assignee; } - after_mirrorUrl: $result['mirror_url'] = $mirrorUrl; + $assignee = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleUser($assignee); + after_assignee: $result['assignee'] = $assignee; - $openIssues = $object->openIssues; - after_openIssues: $result['open_issues'] = $openIssues; + $assignees = $object->assignees; - $openIssuesCount = $object->openIssuesCount; - after_openIssuesCount: $result['open_issues_count'] = $openIssuesCount; + if ($assignees === null) { + goto after_assignees; + } - $permissions = $object->permissions; + static $assigneesSerializer0; - if ($permissions === null) { - goto after_permissions; + if ($assigneesSerializer0 === null) { + $assigneesSerializer0 = new SerializeArrayItems(...[]); } - $permissions = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo⚡️Permissions($permissions); - after_permissions: $result['permissions'] = $permissions; + $assignees = $assigneesSerializer0->serialize($assignees, $this); + after_assignees: $result['assignees'] = $assignees; - $tempCloneToken = $object->tempCloneToken; + $requestedReviewers = $object->requestedReviewers; - if ($tempCloneToken === null) { - goto after_tempCloneToken; + if ($requestedReviewers === null) { + goto after_requestedReviewers; } - after_tempCloneToken: $result['temp_clone_token'] = $tempCloneToken; - - $allowMergeCommit = $object->allowMergeCommit; + static $requestedReviewersSerializer0; - if ($allowMergeCommit === null) { - goto after_allowMergeCommit; + if ($requestedReviewersSerializer0 === null) { + $requestedReviewersSerializer0 = new SerializeArrayItems(...[]); } - after_allowMergeCommit: $result['allow_merge_commit'] = $allowMergeCommit; + $requestedReviewers = $requestedReviewersSerializer0->serialize($requestedReviewers, $this); + after_requestedReviewers: $result['requested_reviewers'] = $requestedReviewers; - $allowSquashMerge = $object->allowSquashMerge; + $requestedTeams = $object->requestedTeams; - if ($allowSquashMerge === null) { - goto after_allowSquashMerge; + if ($requestedTeams === null) { + goto after_requestedTeams; } - after_allowSquashMerge: $result['allow_squash_merge'] = $allowSquashMerge; - - $allowRebaseMerge = $object->allowRebaseMerge; + static $requestedTeamsSerializer0; - if ($allowRebaseMerge === null) { - goto after_allowRebaseMerge; + if ($requestedTeamsSerializer0 === null) { + $requestedTeamsSerializer0 = new SerializeArrayItems(...[]); } - after_allowRebaseMerge: $result['allow_rebase_merge'] = $allowRebaseMerge; - - $license = $object->license; + $requestedTeams = $requestedTeamsSerializer0->serialize($requestedTeams, $this); + after_requestedTeams: $result['requested_teams'] = $requestedTeams; - if ($license === null) { - goto after_license; - } + $head = $object->head; + $head = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head($head); + after_head: $result['head'] = $head; - $license = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo⚡️License($license); - after_license: $result['license'] = $license; + $base = $object->base; + $base = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base($base); + after_base: $result['base'] = $base; - $pushedAt = $object->pushedAt; - after_pushedAt: $result['pushed_at'] = $pushedAt; + $links = $object->links; + $links = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Links($links); + after_links: $result['_links'] = $links; - $size = $object->size; - after_size: $result['size'] = $size; + $authorAssociation = $object->authorAssociation; + after_authorAssociation: $result['author_association'] = $authorAssociation; - $sshUrl = $object->sshUrl; - after_sshUrl: $result['ssh_url'] = $sshUrl; + $autoMerge = $object->autoMerge; - $stargazersCount = $object->stargazersCount; - after_stargazersCount: $result['stargazers_count'] = $stargazersCount; + if ($autoMerge === null) { + goto after_autoMerge; + } - $svnUrl = $object->svnUrl; - after_svnUrl: $result['svn_url'] = $svnUrl; + $autoMerge = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️AutoMerge($autoMerge); + after_autoMerge: $result['auto_merge'] = $autoMerge; - $topics = $object->topics; + $draft = $object->draft; - if ($topics === null) { - goto after_topics; + if ($draft === null) { + goto after_draft; } - static $topicsSerializer0; + after_draft: $result['draft'] = $draft; - if ($topicsSerializer0 === null) { - $topicsSerializer0 = new SerializeArrayItems(...[]); + $merged = $object->merged; + after_merged: $result['merged'] = $merged; + + $mergeable = $object->mergeable; + + if ($mergeable === null) { + goto after_mergeable; } - $topics = $topicsSerializer0->serialize($topics, $this); - after_topics: $result['topics'] = $topics; + after_mergeable: $result['mergeable'] = $mergeable; - $watchers = $object->watchers; - after_watchers: $result['watchers'] = $watchers; + $rebaseable = $object->rebaseable; - $watchersCount = $object->watchersCount; - after_watchersCount: $result['watchers_count'] = $watchersCount; + if ($rebaseable === null) { + goto after_rebaseable; + } - $createdAt = $object->createdAt; - after_createdAt: $result['created_at'] = $createdAt; + after_rebaseable: $result['rebaseable'] = $rebaseable; - $updatedAt = $object->updatedAt; - after_updatedAt: $result['updated_at'] = $updatedAt; + $mergeableState = $object->mergeableState; + after_mergeableState: $result['mergeable_state'] = $mergeableState; - $allowForking = $object->allowForking; + $mergedBy = $object->mergedBy; - if ($allowForking === null) { - goto after_allowForking; + if ($mergedBy === null) { + goto after_mergedBy; } - after_allowForking: $result['allow_forking'] = $allowForking; + $mergedBy = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleUser($mergedBy); + after_mergedBy: $result['merged_by'] = $mergedBy; - $isTemplate = $object->isTemplate; + $comments = $object->comments; + after_comments: $result['comments'] = $comments; - if ($isTemplate === null) { - goto after_isTemplate; - } + $reviewComments = $object->reviewComments; + after_reviewComments: $result['review_comments'] = $reviewComments; - after_isTemplate: $result['is_template'] = $isTemplate; + $maintainerCanModify = $object->maintainerCanModify; + after_maintainerCanModify: $result['maintainer_can_modify'] = $maintainerCanModify; - $webCommitSignoffRequired = $object->webCommitSignoffRequired; + $commits = $object->commits; + after_commits: $result['commits'] = $commits; - if ($webCommitSignoffRequired === null) { - goto after_webCommitSignoffRequired; - } + $additions = $object->additions; + after_additions: $result['additions'] = $additions; - after_webCommitSignoffRequired: $result['web_commit_signoff_required'] = $webCommitSignoffRequired; + $deletions = $object->deletions; + after_deletions: $result['deletions'] = $deletions; + + $changedFiles = $object->changedFiles; + after_changedFiles: $result['changed_files'] = $changedFiles; return $result; } - private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo⚡️Owner(mixed $object): mixed + private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleUser(mixed $object): mixed { - assert($object instanceof Owner); + assert($object instanceof SimpleUser); $result = []; - $avatarUrl = $object->avatarUrl; - after_avatarUrl: $result['avatar_url'] = $avatarUrl; + $name = $object->name; - $eventsUrl = $object->eventsUrl; - after_eventsUrl: $result['events_url'] = $eventsUrl; + if ($name === null) { + goto after_name; + } - $followersUrl = $object->followersUrl; - after_followersUrl: $result['followers_url'] = $followersUrl; + after_name: $result['name'] = $name; - $followingUrl = $object->followingUrl; - after_followingUrl: $result['following_url'] = $followingUrl; + $email = $object->email; - $gistsUrl = $object->gistsUrl; - after_gistsUrl: $result['gists_url'] = $gistsUrl; + if ($email === null) { + goto after_email; + } + + after_email: $result['email'] = $email; + + $login = $object->login; + after_login: $result['login'] = $login; + + $id = $object->id; + after_id: $result['id'] = $id; + + $nodeId = $object->nodeId; + after_nodeId: $result['node_id'] = $nodeId; + + $avatarUrl = $object->avatarUrl; + after_avatarUrl: $result['avatar_url'] = $avatarUrl; $gravatarId = $object->gravatarId; @@ -5916,41 +3422,52 @@ private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseClou after_gravatarId: $result['gravatar_id'] = $gravatarId; + $url = $object->url; + after_url: $result['url'] = $url; + $htmlUrl = $object->htmlUrl; after_htmlUrl: $result['html_url'] = $htmlUrl; - $id = $object->id; - after_id: $result['id'] = $id; + $followersUrl = $object->followersUrl; + after_followersUrl: $result['followers_url'] = $followersUrl; - $nodeId = $object->nodeId; - after_nodeId: $result['node_id'] = $nodeId; + $followingUrl = $object->followingUrl; + after_followingUrl: $result['following_url'] = $followingUrl; - $login = $object->login; - after_login: $result['login'] = $login; + $gistsUrl = $object->gistsUrl; + after_gistsUrl: $result['gists_url'] = $gistsUrl; + + $starredUrl = $object->starredUrl; + after_starredUrl: $result['starred_url'] = $starredUrl; + + $subscriptionsUrl = $object->subscriptionsUrl; + after_subscriptionsUrl: $result['subscriptions_url'] = $subscriptionsUrl; $organizationsUrl = $object->organizationsUrl; after_organizationsUrl: $result['organizations_url'] = $organizationsUrl; + $reposUrl = $object->reposUrl; + after_reposUrl: $result['repos_url'] = $reposUrl; + + $eventsUrl = $object->eventsUrl; + after_eventsUrl: $result['events_url'] = $eventsUrl; + $receivedEventsUrl = $object->receivedEventsUrl; after_receivedEventsUrl: $result['received_events_url'] = $receivedEventsUrl; - $reposUrl = $object->reposUrl; - after_reposUrl: $result['repos_url'] = $reposUrl; + $type = $object->type; + after_type: $result['type'] = $type; $siteAdmin = $object->siteAdmin; after_siteAdmin: $result['site_admin'] = $siteAdmin; - $starredUrl = $object->starredUrl; - after_starredUrl: $result['starred_url'] = $starredUrl; - - $subscriptionsUrl = $object->subscriptionsUrl; - after_subscriptionsUrl: $result['subscriptions_url'] = $subscriptionsUrl; + $starredAt = $object->starredAt; - $type = $object->type; - after_type: $result['type'] = $type; + if ($starredAt === null) { + goto after_starredAt; + } - $url = $object->url; - after_url: $result['url'] = $url; + after_starredAt: $result['starred_at'] = $starredAt; $userViewType = $object->userViewType; @@ -5963,150 +3480,86 @@ private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseClou return $result; } - private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo⚡️Permissions(mixed $object): mixed - { - assert($object instanceof Permissions); - $result = []; - - $admin = $object->admin; - after_admin: $result['admin'] = $admin; - - $maintain = $object->maintain; - - if ($maintain === null) { - goto after_maintain; - } - - after_maintain: $result['maintain'] = $maintain; - - $push = $object->push; - after_push: $result['push'] = $push; - - $triage = $object->triage; - - if ($triage === null) { - goto after_triage; - } - - after_triage: $result['triage'] = $triage; - - $pull = $object->pull; - after_pull: $result['pull'] = $pull; - - return $result; - } - - private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo⚡️License(mixed $object): mixed + private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Milestone(mixed $object): mixed { - assert($object instanceof License); + assert($object instanceof Milestone); $result = []; - $key = $object->key; - after_key: $result['key'] = $key; - - $name = $object->name; - after_name: $result['name'] = $name; - - $url = $object->url; - - if ($url === null) { - goto after_url; - } - + $url = $object->url; after_url: $result['url'] = $url; - $spdxId = $object->spdxId; + $htmlUrl = $object->htmlUrl; + after_htmlUrl: $result['html_url'] = $htmlUrl; - if ($spdxId === null) { - goto after_spdxId; - } + $labelsUrl = $object->labelsUrl; + after_labelsUrl: $result['labels_url'] = $labelsUrl; - after_spdxId: $result['spdx_id'] = $spdxId; + $id = $object->id; + after_id: $result['id'] = $id; $nodeId = $object->nodeId; after_nodeId: $result['node_id'] = $nodeId; - return $result; - } - - private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️User(mixed $object): mixed - { - assert($object instanceof User); - $result = []; - - $avatarUrl = $object->avatarUrl; - after_avatarUrl: $result['avatar_url'] = $avatarUrl; - - $eventsUrl = $object->eventsUrl; - after_eventsUrl: $result['events_url'] = $eventsUrl; - - $followersUrl = $object->followersUrl; - after_followersUrl: $result['followers_url'] = $followersUrl; + $number = $object->number; + after_number: $result['number'] = $number; - $followingUrl = $object->followingUrl; - after_followingUrl: $result['following_url'] = $followingUrl; + $state = $object->state; + after_state: $result['state'] = $state; - $gistsUrl = $object->gistsUrl; - after_gistsUrl: $result['gists_url'] = $gistsUrl; + $title = $object->title; + after_title: $result['title'] = $title; - $gravatarId = $object->gravatarId; + $description = $object->description; - if ($gravatarId === null) { - goto after_gravatarId; + if ($description === null) { + goto after_description; } - after_gravatarId: $result['gravatar_id'] = $gravatarId; - - $htmlUrl = $object->htmlUrl; - after_htmlUrl: $result['html_url'] = $htmlUrl; - - $id = $object->id; - after_id: $result['id'] = $id; + after_description: $result['description'] = $description; - $nodeId = $object->nodeId; - after_nodeId: $result['node_id'] = $nodeId; + $creator = $object->creator; - $login = $object->login; - after_login: $result['login'] = $login; + if ($creator === null) { + goto after_creator; + } - $organizationsUrl = $object->organizationsUrl; - after_organizationsUrl: $result['organizations_url'] = $organizationsUrl; + $creator = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleUser($creator); + after_creator: $result['creator'] = $creator; - $receivedEventsUrl = $object->receivedEventsUrl; - after_receivedEventsUrl: $result['received_events_url'] = $receivedEventsUrl; + $openIssues = $object->openIssues; + after_openIssues: $result['open_issues'] = $openIssues; - $reposUrl = $object->reposUrl; - after_reposUrl: $result['repos_url'] = $reposUrl; + $closedIssues = $object->closedIssues; + after_closedIssues: $result['closed_issues'] = $closedIssues; - $siteAdmin = $object->siteAdmin; - after_siteAdmin: $result['site_admin'] = $siteAdmin; + $createdAt = $object->createdAt; + after_createdAt: $result['created_at'] = $createdAt; - $starredUrl = $object->starredUrl; - after_starredUrl: $result['starred_url'] = $starredUrl; + $updatedAt = $object->updatedAt; + after_updatedAt: $result['updated_at'] = $updatedAt; - $subscriptionsUrl = $object->subscriptionsUrl; - after_subscriptionsUrl: $result['subscriptions_url'] = $subscriptionsUrl; + $closedAt = $object->closedAt; - $type = $object->type; - after_type: $result['type'] = $type; + if ($closedAt === null) { + goto after_closedAt; + } - $url = $object->url; - after_url: $result['url'] = $url; + after_closedAt: $result['closed_at'] = $closedAt; - $userViewType = $object->userViewType; + $dueOn = $object->dueOn; - if ($userViewType === null) { - goto after_userViewType; + if ($dueOn === null) { + goto after_dueOn; } - after_userViewType: $result['user_view_type'] = $userViewType; + after_dueOn: $result['due_on'] = $dueOn; return $result; } - private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base(mixed $object): mixed + private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head(mixed $object): mixed { - assert($object instanceof Base); + assert($object instanceof Head); $result = []; $label = $object->label; @@ -6116,24 +3569,81 @@ private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseClou after_ref: $result['ref'] = $ref; $repo = $object->repo; - $repo = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️Repo($repo); + $repo = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Repository($repo); after_repo: $result['repo'] = $repo; $sha = $object->sha; after_sha: $result['sha'] = $sha; $user = $object->user; - $user = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️User($user); + $user = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleUser($user); after_user: $result['user'] = $user; return $result; } - private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️Repo(mixed $object): mixed + private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Repository(mixed $object): mixed { - assert($object instanceof \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo); + assert($object instanceof Repository); $result = []; + $id = $object->id; + after_id: $result['id'] = $id; + + $nodeId = $object->nodeId; + after_nodeId: $result['node_id'] = $nodeId; + + $name = $object->name; + after_name: $result['name'] = $name; + + $fullName = $object->fullName; + after_fullName: $result['full_name'] = $fullName; + + $license = $object->license; + + if ($license === null) { + goto after_license; + } + + $license = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️LicenseSimple($license); + after_license: $result['license'] = $license; + + $forks = $object->forks; + after_forks: $result['forks'] = $forks; + + $permissions = $object->permissions; + + if ($permissions === null) { + goto after_permissions; + } + + $permissions = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Repository⚡️Permissions($permissions); + after_permissions: $result['permissions'] = $permissions; + + $owner = $object->owner; + $owner = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleUser($owner); + after_owner: $result['owner'] = $owner; + + $private = $object->private; + after_private: $result['private'] = $private; + + $htmlUrl = $object->htmlUrl; + after_htmlUrl: $result['html_url'] = $htmlUrl; + + $description = $object->description; + + if ($description === null) { + goto after_description; + } + + after_description: $result['description'] = $description; + + $fork = $object->fork; + after_fork: $result['fork'] = $fork; + + $url = $object->url; + after_url: $result['url'] = $url; + $archiveUrl = $object->archiveUrl; after_archiveUrl: $result['archive_url'] = $archiveUrl; @@ -6167,29 +3677,15 @@ private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseClou $deploymentsUrl = $object->deploymentsUrl; after_deploymentsUrl: $result['deployments_url'] = $deploymentsUrl; - $description = $object->description; - - if ($description === null) { - goto after_description; - } - - after_description: $result['description'] = $description; - $downloadsUrl = $object->downloadsUrl; after_downloadsUrl: $result['downloads_url'] = $downloadsUrl; $eventsUrl = $object->eventsUrl; after_eventsUrl: $result['events_url'] = $eventsUrl; - $fork = $object->fork; - after_fork: $result['fork'] = $fork; - $forksUrl = $object->forksUrl; after_forksUrl: $result['forks_url'] = $forksUrl; - $fullName = $object->fullName; - after_fullName: $result['full_name'] = $fullName; - $gitCommitsUrl = $object->gitCommitsUrl; after_gitCommitsUrl: $result['git_commits_url'] = $gitCommitsUrl; @@ -6199,25 +3695,8 @@ private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseClou $gitTagsUrl = $object->gitTagsUrl; after_gitTagsUrl: $result['git_tags_url'] = $gitTagsUrl; - $hooksUrl = $object->hooksUrl; - after_hooksUrl: $result['hooks_url'] = $hooksUrl; - - $htmlUrl = $object->htmlUrl; - after_htmlUrl: $result['html_url'] = $htmlUrl; - - $id = $object->id; - after_id: $result['id'] = $id; - - $isTemplate = $object->isTemplate; - - if ($isTemplate === null) { - goto after_isTemplate; - } - - after_isTemplate: $result['is_template'] = $isTemplate; - - $nodeId = $object->nodeId; - after_nodeId: $result['node_id'] = $nodeId; + $gitUrl = $object->gitUrl; + after_gitUrl: $result['git_url'] = $gitUrl; $issueCommentUrl = $object->issueCommentUrl; after_issueCommentUrl: $result['issue_comment_url'] = $issueCommentUrl; @@ -6243,25 +3722,18 @@ private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseClou $milestonesUrl = $object->milestonesUrl; after_milestonesUrl: $result['milestones_url'] = $milestonesUrl; - $name = $object->name; - after_name: $result['name'] = $name; - $notificationsUrl = $object->notificationsUrl; after_notificationsUrl: $result['notifications_url'] = $notificationsUrl; - $owner = $object->owner; - $owner = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️Repo⚡️Owner($owner); - after_owner: $result['owner'] = $owner; - - $private = $object->private; - after_private: $result['private'] = $private; - $pullsUrl = $object->pullsUrl; after_pullsUrl: $result['pulls_url'] = $pullsUrl; $releasesUrl = $object->releasesUrl; after_releasesUrl: $result['releases_url'] = $releasesUrl; + $sshUrl = $object->sshUrl; + after_sshUrl: $result['ssh_url'] = $sshUrl; + $stargazersUrl = $object->stargazersUrl; after_stargazersUrl: $result['stargazers_url'] = $stargazersUrl; @@ -6283,41 +3755,22 @@ private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseClou $treesUrl = $object->treesUrl; after_treesUrl: $result['trees_url'] = $treesUrl; - $url = $object->url; - after_url: $result['url'] = $url; - $cloneUrl = $object->cloneUrl; after_cloneUrl: $result['clone_url'] = $cloneUrl; - $defaultBranch = $object->defaultBranch; - after_defaultBranch: $result['default_branch'] = $defaultBranch; - - $forks = $object->forks; - after_forks: $result['forks'] = $forks; - - $forksCount = $object->forksCount; - after_forksCount: $result['forks_count'] = $forksCount; - - $gitUrl = $object->gitUrl; - after_gitUrl: $result['git_url'] = $gitUrl; - - $hasDownloads = $object->hasDownloads; - after_hasDownloads: $result['has_downloads'] = $hasDownloads; - - $hasIssues = $object->hasIssues; - after_hasIssues: $result['has_issues'] = $hasIssues; + $mirrorUrl = $object->mirrorUrl; - $hasProjects = $object->hasProjects; - after_hasProjects: $result['has_projects'] = $hasProjects; + if ($mirrorUrl === null) { + goto after_mirrorUrl; + } - $hasWiki = $object->hasWiki; - after_hasWiki: $result['has_wiki'] = $hasWiki; + after_mirrorUrl: $result['mirror_url'] = $mirrorUrl; - $hasPages = $object->hasPages; - after_hasPages: $result['has_pages'] = $hasPages; + $hooksUrl = $object->hooksUrl; + after_hooksUrl: $result['hooks_url'] = $hooksUrl; - $hasDiscussions = $object->hasDiscussions; - after_hasDiscussions: $result['has_discussions'] = $hasDiscussions; + $svnUrl = $object->svnUrl; + after_svnUrl: $result['svn_url'] = $svnUrl; $homepage = $object->homepage; @@ -6335,74 +3788,107 @@ private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseClou after_language: $result['language'] = $language; - $masterBranch = $object->masterBranch; + $forksCount = $object->forksCount; + after_forksCount: $result['forks_count'] = $forksCount; - if ($masterBranch === null) { - goto after_masterBranch; + $stargazersCount = $object->stargazersCount; + after_stargazersCount: $result['stargazers_count'] = $stargazersCount; + + $watchersCount = $object->watchersCount; + after_watchersCount: $result['watchers_count'] = $watchersCount; + + $size = $object->size; + after_size: $result['size'] = $size; + + $defaultBranch = $object->defaultBranch; + after_defaultBranch: $result['default_branch'] = $defaultBranch; + + $openIssuesCount = $object->openIssuesCount; + after_openIssuesCount: $result['open_issues_count'] = $openIssuesCount; + + $isTemplate = $object->isTemplate; + + if ($isTemplate === null) { + goto after_isTemplate; } - after_masterBranch: $result['master_branch'] = $masterBranch; + after_isTemplate: $result['is_template'] = $isTemplate; - $archived = $object->archived; - after_archived: $result['archived'] = $archived; + $topics = $object->topics; - $disabled = $object->disabled; - after_disabled: $result['disabled'] = $disabled; + if ($topics === null) { + goto after_topics; + } - $visibility = $object->visibility; + static $topicsSerializer0; - if ($visibility === null) { - goto after_visibility; + if ($topicsSerializer0 === null) { + $topicsSerializer0 = new SerializeArrayItems(...[]); } - after_visibility: $result['visibility'] = $visibility; + $topics = $topicsSerializer0->serialize($topics, $this); + after_topics: $result['topics'] = $topics; - $mirrorUrl = $object->mirrorUrl; + $hasIssues = $object->hasIssues; + after_hasIssues: $result['has_issues'] = $hasIssues; - if ($mirrorUrl === null) { - goto after_mirrorUrl; + $hasProjects = $object->hasProjects; + after_hasProjects: $result['has_projects'] = $hasProjects; + + $hasWiki = $object->hasWiki; + after_hasWiki: $result['has_wiki'] = $hasWiki; + + $hasPages = $object->hasPages; + after_hasPages: $result['has_pages'] = $hasPages; + + $hasDownloads = $object->hasDownloads; + after_hasDownloads: $result['has_downloads'] = $hasDownloads; + + $hasDiscussions = $object->hasDiscussions; + + if ($hasDiscussions === null) { + goto after_hasDiscussions; } - after_mirrorUrl: $result['mirror_url'] = $mirrorUrl; + after_hasDiscussions: $result['has_discussions'] = $hasDiscussions; - $openIssues = $object->openIssues; - after_openIssues: $result['open_issues'] = $openIssues; + $archived = $object->archived; + after_archived: $result['archived'] = $archived; - $openIssuesCount = $object->openIssuesCount; - after_openIssuesCount: $result['open_issues_count'] = $openIssuesCount; + $disabled = $object->disabled; + after_disabled: $result['disabled'] = $disabled; - $permissions = $object->permissions; + $visibility = $object->visibility; - if ($permissions === null) { - goto after_permissions; + if ($visibility === null) { + goto after_visibility; } - $permissions = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️Repo⚡️Permissions($permissions); - after_permissions: $result['permissions'] = $permissions; + after_visibility: $result['visibility'] = $visibility; - $tempCloneToken = $object->tempCloneToken; + $pushedAt = $object->pushedAt; - if ($tempCloneToken === null) { - goto after_tempCloneToken; + if ($pushedAt === null) { + goto after_pushedAt; } - after_tempCloneToken: $result['temp_clone_token'] = $tempCloneToken; + after_pushedAt: $result['pushed_at'] = $pushedAt; - $allowMergeCommit = $object->allowMergeCommit; + $createdAt = $object->createdAt; - if ($allowMergeCommit === null) { - goto after_allowMergeCommit; + if ($createdAt === null) { + goto after_createdAt; } - after_allowMergeCommit: $result['allow_merge_commit'] = $allowMergeCommit; + after_createdAt: $result['created_at'] = $createdAt; - $allowSquashMerge = $object->allowSquashMerge; + $updatedAt = $object->updatedAt; - if ($allowSquashMerge === null) { - goto after_allowSquashMerge; + if ($updatedAt === null) { + goto after_updatedAt; } - after_allowSquashMerge: $result['allow_squash_merge'] = $allowSquashMerge; + after_updatedAt: $result['updated_at'] = $updatedAt; $allowRebaseMerge = $object->allowRebaseMerge; @@ -6412,180 +3898,139 @@ private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseClou after_allowRebaseMerge: $result['allow_rebase_merge'] = $allowRebaseMerge; - $license = $object->license; + $tempCloneToken = $object->tempCloneToken; - if ($license === null) { - goto after_license; + if ($tempCloneToken === null) { + goto after_tempCloneToken; } - $license = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️LicenseSimple($license); - after_license: $result['license'] = $license; - - $pushedAt = $object->pushedAt; - after_pushedAt: $result['pushed_at'] = $pushedAt; - - $size = $object->size; - after_size: $result['size'] = $size; + after_tempCloneToken: $result['temp_clone_token'] = $tempCloneToken; - $sshUrl = $object->sshUrl; - after_sshUrl: $result['ssh_url'] = $sshUrl; + $allowSquashMerge = $object->allowSquashMerge; - $stargazersCount = $object->stargazersCount; - after_stargazersCount: $result['stargazers_count'] = $stargazersCount; + if ($allowSquashMerge === null) { + goto after_allowSquashMerge; + } - $svnUrl = $object->svnUrl; - after_svnUrl: $result['svn_url'] = $svnUrl; + after_allowSquashMerge: $result['allow_squash_merge'] = $allowSquashMerge; - $topics = $object->topics; + $allowAutoMerge = $object->allowAutoMerge; - if ($topics === null) { - goto after_topics; + if ($allowAutoMerge === null) { + goto after_allowAutoMerge; } - static $topicsSerializer0; + after_allowAutoMerge: $result['allow_auto_merge'] = $allowAutoMerge; - if ($topicsSerializer0 === null) { - $topicsSerializer0 = new SerializeArrayItems(...[]); - } + $deleteBranchOnMerge = $object->deleteBranchOnMerge; - $topics = $topicsSerializer0->serialize($topics, $this); - after_topics: $result['topics'] = $topics; + if ($deleteBranchOnMerge === null) { + goto after_deleteBranchOnMerge; + } - $watchers = $object->watchers; - after_watchers: $result['watchers'] = $watchers; + after_deleteBranchOnMerge: $result['delete_branch_on_merge'] = $deleteBranchOnMerge; - $watchersCount = $object->watchersCount; - after_watchersCount: $result['watchers_count'] = $watchersCount; + $allowUpdateBranch = $object->allowUpdateBranch; - $createdAt = $object->createdAt; - after_createdAt: $result['created_at'] = $createdAt; + if ($allowUpdateBranch === null) { + goto after_allowUpdateBranch; + } - $updatedAt = $object->updatedAt; - after_updatedAt: $result['updated_at'] = $updatedAt; + after_allowUpdateBranch: $result['allow_update_branch'] = $allowUpdateBranch; - $allowForking = $object->allowForking; + $useSquashPrTitleAsDefault = $object->useSquashPrTitleAsDefault; - if ($allowForking === null) { - goto after_allowForking; + if ($useSquashPrTitleAsDefault === null) { + goto after_useSquashPrTitleAsDefault; } - after_allowForking: $result['allow_forking'] = $allowForking; + after_useSquashPrTitleAsDefault: $result['use_squash_pr_title_as_default'] = $useSquashPrTitleAsDefault; - $webCommitSignoffRequired = $object->webCommitSignoffRequired; + $squashMergeCommitTitle = $object->squashMergeCommitTitle; - if ($webCommitSignoffRequired === null) { - goto after_webCommitSignoffRequired; + if ($squashMergeCommitTitle === null) { + goto after_squashMergeCommitTitle; } - after_webCommitSignoffRequired: $result['web_commit_signoff_required'] = $webCommitSignoffRequired; - - return $result; - } + after_squashMergeCommitTitle: $result['squash_merge_commit_title'] = $squashMergeCommitTitle; - private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️Repo⚡️Owner(mixed $object): mixed - { - assert($object instanceof \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo\Owner); - $result = []; + $squashMergeCommitMessage = $object->squashMergeCommitMessage; - $avatarUrl = $object->avatarUrl; - after_avatarUrl: $result['avatar_url'] = $avatarUrl; + if ($squashMergeCommitMessage === null) { + goto after_squashMergeCommitMessage; + } - $eventsUrl = $object->eventsUrl; - after_eventsUrl: $result['events_url'] = $eventsUrl; + after_squashMergeCommitMessage: $result['squash_merge_commit_message'] = $squashMergeCommitMessage; - $followersUrl = $object->followersUrl; - after_followersUrl: $result['followers_url'] = $followersUrl; + $mergeCommitTitle = $object->mergeCommitTitle; - $followingUrl = $object->followingUrl; - after_followingUrl: $result['following_url'] = $followingUrl; + if ($mergeCommitTitle === null) { + goto after_mergeCommitTitle; + } - $gistsUrl = $object->gistsUrl; - after_gistsUrl: $result['gists_url'] = $gistsUrl; + after_mergeCommitTitle: $result['merge_commit_title'] = $mergeCommitTitle; - $gravatarId = $object->gravatarId; + $mergeCommitMessage = $object->mergeCommitMessage; - if ($gravatarId === null) { - goto after_gravatarId; + if ($mergeCommitMessage === null) { + goto after_mergeCommitMessage; } - after_gravatarId: $result['gravatar_id'] = $gravatarId; - - $htmlUrl = $object->htmlUrl; - after_htmlUrl: $result['html_url'] = $htmlUrl; + after_mergeCommitMessage: $result['merge_commit_message'] = $mergeCommitMessage; - $id = $object->id; - after_id: $result['id'] = $id; + $allowMergeCommit = $object->allowMergeCommit; - $nodeId = $object->nodeId; - after_nodeId: $result['node_id'] = $nodeId; + if ($allowMergeCommit === null) { + goto after_allowMergeCommit; + } - $login = $object->login; - after_login: $result['login'] = $login; + after_allowMergeCommit: $result['allow_merge_commit'] = $allowMergeCommit; - $organizationsUrl = $object->organizationsUrl; - after_organizationsUrl: $result['organizations_url'] = $organizationsUrl; + $allowForking = $object->allowForking; - $receivedEventsUrl = $object->receivedEventsUrl; - after_receivedEventsUrl: $result['received_events_url'] = $receivedEventsUrl; + if ($allowForking === null) { + goto after_allowForking; + } - $reposUrl = $object->reposUrl; - after_reposUrl: $result['repos_url'] = $reposUrl; + after_allowForking: $result['allow_forking'] = $allowForking; - $siteAdmin = $object->siteAdmin; - after_siteAdmin: $result['site_admin'] = $siteAdmin; + $webCommitSignoffRequired = $object->webCommitSignoffRequired; - $starredUrl = $object->starredUrl; - after_starredUrl: $result['starred_url'] = $starredUrl; + if ($webCommitSignoffRequired === null) { + goto after_webCommitSignoffRequired; + } - $subscriptionsUrl = $object->subscriptionsUrl; - after_subscriptionsUrl: $result['subscriptions_url'] = $subscriptionsUrl; + after_webCommitSignoffRequired: $result['web_commit_signoff_required'] = $webCommitSignoffRequired; - $type = $object->type; - after_type: $result['type'] = $type; + $openIssues = $object->openIssues; + after_openIssues: $result['open_issues'] = $openIssues; - $url = $object->url; - after_url: $result['url'] = $url; + $watchers = $object->watchers; + after_watchers: $result['watchers'] = $watchers; - $userViewType = $object->userViewType; + $masterBranch = $object->masterBranch; - if ($userViewType === null) { - goto after_userViewType; + if ($masterBranch === null) { + goto after_masterBranch; } - after_userViewType: $result['user_view_type'] = $userViewType; - - return $result; - } - - private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️Repo⚡️Permissions(mixed $object): mixed - { - assert($object instanceof \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo\Permissions); - $result = []; - - $admin = $object->admin; - after_admin: $result['admin'] = $admin; + after_masterBranch: $result['master_branch'] = $masterBranch; - $maintain = $object->maintain; + $starredAt = $object->starredAt; - if ($maintain === null) { - goto after_maintain; + if ($starredAt === null) { + goto after_starredAt; } - after_maintain: $result['maintain'] = $maintain; - - $push = $object->push; - after_push: $result['push'] = $push; + after_starredAt: $result['starred_at'] = $starredAt; - $triage = $object->triage; + $anonymousAccessEnabled = $object->anonymousAccessEnabled; - if ($triage === null) { - goto after_triage; + if ($anonymousAccessEnabled === null) { + goto after_anonymousAccessEnabled; } - after_triage: $result['triage'] = $triage; - - $pull = $object->pull; - after_pull: $result['pull'] = $pull; + after_anonymousAccessEnabled: $result['anonymous_access_enabled'] = $anonymousAccessEnabled; return $result; } @@ -6631,77 +4076,60 @@ private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseClou return $result; } - private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️User(mixed $object): mixed + private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Repository⚡️Permissions(mixed $object): mixed { - assert($object instanceof \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\User); + assert($object instanceof Permissions); $result = []; - $avatarUrl = $object->avatarUrl; - after_avatarUrl: $result['avatar_url'] = $avatarUrl; - - $eventsUrl = $object->eventsUrl; - after_eventsUrl: $result['events_url'] = $eventsUrl; - - $followersUrl = $object->followersUrl; - after_followersUrl: $result['followers_url'] = $followersUrl; - - $followingUrl = $object->followingUrl; - after_followingUrl: $result['following_url'] = $followingUrl; + $admin = $object->admin; + after_admin: $result['admin'] = $admin; - $gistsUrl = $object->gistsUrl; - after_gistsUrl: $result['gists_url'] = $gistsUrl; + $pull = $object->pull; + after_pull: $result['pull'] = $pull; - $gravatarId = $object->gravatarId; + $triage = $object->triage; - if ($gravatarId === null) { - goto after_gravatarId; + if ($triage === null) { + goto after_triage; } - after_gravatarId: $result['gravatar_id'] = $gravatarId; - - $htmlUrl = $object->htmlUrl; - after_htmlUrl: $result['html_url'] = $htmlUrl; - - $id = $object->id; - after_id: $result['id'] = $id; - - $nodeId = $object->nodeId; - after_nodeId: $result['node_id'] = $nodeId; - - $login = $object->login; - after_login: $result['login'] = $login; + after_triage: $result['triage'] = $triage; - $organizationsUrl = $object->organizationsUrl; - after_organizationsUrl: $result['organizations_url'] = $organizationsUrl; + $push = $object->push; + after_push: $result['push'] = $push; - $receivedEventsUrl = $object->receivedEventsUrl; - after_receivedEventsUrl: $result['received_events_url'] = $receivedEventsUrl; + $maintain = $object->maintain; - $reposUrl = $object->reposUrl; - after_reposUrl: $result['repos_url'] = $reposUrl; + if ($maintain === null) { + goto after_maintain; + } - $siteAdmin = $object->siteAdmin; - after_siteAdmin: $result['site_admin'] = $siteAdmin; + after_maintain: $result['maintain'] = $maintain; - $starredUrl = $object->starredUrl; - after_starredUrl: $result['starred_url'] = $starredUrl; + return $result; + } - $subscriptionsUrl = $object->subscriptionsUrl; - after_subscriptionsUrl: $result['subscriptions_url'] = $subscriptionsUrl; + private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base(mixed $object): mixed + { + assert($object instanceof Base); + $result = []; - $type = $object->type; - after_type: $result['type'] = $type; + $label = $object->label; + after_label: $result['label'] = $label; - $url = $object->url; - after_url: $result['url'] = $url; + $ref = $object->ref; + after_ref: $result['ref'] = $ref; - $userViewType = $object->userViewType; + $repo = $object->repo; + $repo = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Repository($repo); + after_repo: $result['repo'] = $repo; - if ($userViewType === null) { - goto after_userViewType; - } + $sha = $object->sha; + after_sha: $result['sha'] = $sha; - after_userViewType: $result['user_view_type'] = $userViewType; + $user = $object->user; + $user = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleUser($user); + after_user: $result['user'] = $user; return $result; } diff --git a/clients/GitHubEnterpriseCloud/src/Internal/Hydrator/Operation/Repos/Owner/Repo/Pulls/PullNumber.php b/clients/GitHubEnterpriseCloud/src/Internal/Hydrator/Operation/Repos/Owner/Repo/Pulls/PullNumber.php index de162b5c49b..bc6318cd42f 100644 --- a/clients/GitHubEnterpriseCloud/src/Internal/Hydrator/Operation/Repos/Owner/Repo/Pulls/PullNumber.php +++ b/clients/GitHubEnterpriseCloud/src/Internal/Hydrator/Operation/Repos/Owner/Repo/Pulls/PullNumber.php @@ -13,12 +13,9 @@ use ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest; use ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base; use ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head; -use ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo; -use ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo\License; -use ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo\Owner; -use ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo\Permissions; -use ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\User; use ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Links; +use ApiClients\Client\GitHubEnterpriseCloud\Schema\Repository; +use ApiClients\Client\GitHubEnterpriseCloud\Schema\Repository\Permissions; use ApiClients\Client\GitHubEnterpriseCloud\Schema\SimpleUser; use ApiClients\Client\GitHubEnterpriseCloud\Schema\ValidationError; use EventSauce\ObjectHydrator\IterableList; @@ -60,17 +57,10 @@ public function hydrateObject(string $className, array $payload): object 'ApiClients\Client\GitHubEnterpriseCloud\Schema\SimpleUser' => $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleUser($payload), 'ApiClients\Client\GitHubEnterpriseCloud\Schema\Milestone' => $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Milestone($payload), 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head' => $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head($payload), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo' => $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo($payload), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo\Owner' => $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo⚡️Owner($payload), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo\Permissions' => $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo⚡️Permissions($payload), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo\License' => $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo⚡️License($payload), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\User' => $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️User($payload), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base' => $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base($payload), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo' => $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️Repo($payload), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo\Owner' => $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️Repo⚡️Owner($payload), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo\Permissions' => $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️Repo⚡️Permissions($payload), + 'ApiClients\Client\GitHubEnterpriseCloud\Schema\Repository' => $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Repository($payload), 'ApiClients\Client\GitHubEnterpriseCloud\Schema\LicenseSimple' => $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️LicenseSimple($payload), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\User' => $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️User($payload), + 'ApiClients\Client\GitHubEnterpriseCloud\Schema\Repository\Permissions' => $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Repository⚡️Permissions($payload), + 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base' => $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base($payload), 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Links' => $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Links($payload), 'ApiClients\Client\GitHubEnterpriseCloud\Schema\Link' => $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Link($payload), 'ApiClients\Client\GitHubEnterpriseCloud\Schema\AutoMerge' => $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️AutoMerge($payload), @@ -1195,14 +1185,14 @@ private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️S $value = $payload['repo'] ?? null; if ($value === null) { - $properties['repo'] = null; + $missingFields[] = 'repo'; goto after_repo; } if (is_array($value)) { try { $this->hydrationStack[] = 'repo'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo($value); + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Repository($value); } finally { array_pop($this->hydrationStack); } @@ -1233,7 +1223,7 @@ private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️S if (is_array($value)) { try { $this->hydrationStack[] = 'user'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️User($value); + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleUser($value); } finally { array_pop($this->hydrationStack); } @@ -1257,11 +1247,181 @@ private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️S } } - private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo(array $payload): Repo + private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Repository(array $payload): Repository { $properties = []; $missingFields = []; try { + $value = $payload['id'] ?? null; + + if ($value === null) { + $missingFields[] = 'id'; + goto after_id; + } + + $properties['id'] = $value; + + after_id: + + $value = $payload['node_id'] ?? null; + + if ($value === null) { + $missingFields[] = 'node_id'; + goto after_nodeId; + } + + $properties['nodeId'] = $value; + + after_nodeId: + + $value = $payload['name'] ?? null; + + if ($value === null) { + $missingFields[] = 'name'; + goto after_name; + } + + $properties['name'] = $value; + + after_name: + + $value = $payload['full_name'] ?? null; + + if ($value === null) { + $missingFields[] = 'full_name'; + goto after_fullName; + } + + $properties['fullName'] = $value; + + after_fullName: + + $value = $payload['license'] ?? null; + + if ($value === null) { + $properties['license'] = null; + goto after_license; + } + + if (is_array($value)) { + try { + $this->hydrationStack[] = 'license'; + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️LicenseSimple($value); + } finally { + array_pop($this->hydrationStack); + } + } + + $properties['license'] = $value; + + after_license: + + $value = $payload['forks'] ?? null; + + if ($value === null) { + $missingFields[] = 'forks'; + goto after_forks; + } + + $properties['forks'] = $value; + + after_forks: + + $value = $payload['permissions'] ?? null; + + if ($value === null) { + $properties['permissions'] = null; + goto after_permissions; + } + + if (is_array($value)) { + try { + $this->hydrationStack[] = 'permissions'; + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Repository⚡️Permissions($value); + } finally { + array_pop($this->hydrationStack); + } + } + + $properties['permissions'] = $value; + + after_permissions: + + $value = $payload['owner'] ?? null; + + if ($value === null) { + $missingFields[] = 'owner'; + goto after_owner; + } + + if (is_array($value)) { + try { + $this->hydrationStack[] = 'owner'; + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleUser($value); + } finally { + array_pop($this->hydrationStack); + } + } + + $properties['owner'] = $value; + + after_owner: + + $value = $payload['private'] ?? null; + + if ($value === null) { + $missingFields[] = 'private'; + goto after_private; + } + + $properties['private'] = $value; + + after_private: + + $value = $payload['html_url'] ?? null; + + if ($value === null) { + $missingFields[] = 'html_url'; + goto after_htmlUrl; + } + + $properties['htmlUrl'] = $value; + + after_htmlUrl: + + $value = $payload['description'] ?? null; + + if ($value === null) { + $properties['description'] = null; + goto after_description; + } + + $properties['description'] = $value; + + after_description: + + $value = $payload['fork'] ?? null; + + if ($value === null) { + $missingFields[] = 'fork'; + goto after_fork; + } + + $properties['fork'] = $value; + + after_fork: + + $value = $payload['url'] ?? null; + + if ($value === null) { + $missingFields[] = 'url'; + goto after_url; + } + + $properties['url'] = $value; + + after_url: + $value = $payload['archive_url'] ?? null; if ($value === null) { @@ -1383,17 +1543,6 @@ private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️S after_deploymentsUrl: - $value = $payload['description'] ?? null; - - if ($value === null) { - $properties['description'] = null; - goto after_description; - } - - $properties['description'] = $value; - - after_description: - $value = $payload['downloads_url'] ?? null; if ($value === null) { @@ -1416,17 +1565,6 @@ private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️S after_eventsUrl: - $value = $payload['fork'] ?? null; - - if ($value === null) { - $missingFields[] = 'fork'; - goto after_fork; - } - - $properties['fork'] = $value; - - after_fork: - $value = $payload['forks_url'] ?? null; if ($value === null) { @@ -1438,17 +1576,6 @@ private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️S after_forksUrl: - $value = $payload['full_name'] ?? null; - - if ($value === null) { - $missingFields[] = 'full_name'; - goto after_fullName; - } - - $properties['fullName'] = $value; - - after_fullName: - $value = $payload['git_commits_url'] ?? null; if ($value === null) { @@ -1482,49 +1609,16 @@ private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️S after_gitTagsUrl: - $value = $payload['hooks_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'hooks_url'; - goto after_hooksUrl; - } - - $properties['hooksUrl'] = $value; - - after_hooksUrl: - - $value = $payload['html_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'html_url'; - goto after_htmlUrl; - } - - $properties['htmlUrl'] = $value; - - after_htmlUrl: - - $value = $payload['id'] ?? null; - - if ($value === null) { - $missingFields[] = 'id'; - goto after_id; - } - - $properties['id'] = $value; - - after_id: - - $value = $payload['node_id'] ?? null; + $value = $payload['git_url'] ?? null; if ($value === null) { - $missingFields[] = 'node_id'; - goto after_nodeId; + $missingFields[] = 'git_url'; + goto after_gitUrl; } - $properties['nodeId'] = $value; + $properties['gitUrl'] = $value; - after_nodeId: + after_gitUrl: $value = $payload['issue_comment_url'] ?? null; @@ -1614,59 +1708,17 @@ private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️S after_milestonesUrl: - $value = $payload['name'] ?? null; + $value = $payload['notifications_url'] ?? null; if ($value === null) { - $missingFields[] = 'name'; - goto after_name; - } - - $properties['name'] = $value; - - after_name: - - $value = $payload['notifications_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'notifications_url'; - goto after_notificationsUrl; + $missingFields[] = 'notifications_url'; + goto after_notificationsUrl; } $properties['notificationsUrl'] = $value; after_notificationsUrl: - $value = $payload['owner'] ?? null; - - if ($value === null) { - $missingFields[] = 'owner'; - goto after_owner; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'owner'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo⚡️Owner($value); - } finally { - array_pop($this->hydrationStack); - } - } - - $properties['owner'] = $value; - - after_owner: - - $value = $payload['private'] ?? null; - - if ($value === null) { - $missingFields[] = 'private'; - goto after_private; - } - - $properties['private'] = $value; - - after_private: - $value = $payload['pulls_url'] ?? null; if ($value === null) { @@ -1689,6 +1741,17 @@ private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️S after_releasesUrl: + $value = $payload['ssh_url'] ?? null; + + if ($value === null) { + $missingFields[] = 'ssh_url'; + goto after_sshUrl; + } + + $properties['sshUrl'] = $value; + + after_sshUrl: + $value = $payload['stargazers_url'] ?? null; if ($value === null) { @@ -1766,49 +1829,71 @@ private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️S after_treesUrl: - $value = $payload['url'] ?? null; + $value = $payload['clone_url'] ?? null; if ($value === null) { - $missingFields[] = 'url'; - goto after_url; + $missingFields[] = 'clone_url'; + goto after_cloneUrl; } - $properties['url'] = $value; + $properties['cloneUrl'] = $value; - after_url: + after_cloneUrl: - $value = $payload['clone_url'] ?? null; + $value = $payload['mirror_url'] ?? null; if ($value === null) { - $missingFields[] = 'clone_url'; - goto after_cloneUrl; + $properties['mirrorUrl'] = null; + goto after_mirrorUrl; } - $properties['cloneUrl'] = $value; + $properties['mirrorUrl'] = $value; - after_cloneUrl: + after_mirrorUrl: - $value = $payload['default_branch'] ?? null; + $value = $payload['hooks_url'] ?? null; if ($value === null) { - $missingFields[] = 'default_branch'; - goto after_defaultBranch; + $missingFields[] = 'hooks_url'; + goto after_hooksUrl; } - $properties['defaultBranch'] = $value; + $properties['hooksUrl'] = $value; - after_defaultBranch: + after_hooksUrl: - $value = $payload['forks'] ?? null; + $value = $payload['svn_url'] ?? null; if ($value === null) { - $missingFields[] = 'forks'; - goto after_forks; + $missingFields[] = 'svn_url'; + goto after_svnUrl; } - $properties['forks'] = $value; + $properties['svnUrl'] = $value; - after_forks: + after_svnUrl: + + $value = $payload['homepage'] ?? null; + + if ($value === null) { + $properties['homepage'] = null; + goto after_homepage; + } + + $properties['homepage'] = $value; + + after_homepage: + + $value = $payload['language'] ?? null; + + if ($value === null) { + $properties['language'] = null; + goto after_language; + } + + $properties['language'] = $value; + + after_language: $value = $payload['forks_count'] ?? null; @@ -1821,27 +1906,82 @@ private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️S after_forksCount: - $value = $payload['git_url'] ?? null; + $value = $payload['stargazers_count'] ?? null; if ($value === null) { - $missingFields[] = 'git_url'; - goto after_gitUrl; + $missingFields[] = 'stargazers_count'; + goto after_stargazersCount; } - $properties['gitUrl'] = $value; + $properties['stargazersCount'] = $value; - after_gitUrl: + after_stargazersCount: - $value = $payload['has_downloads'] ?? null; + $value = $payload['watchers_count'] ?? null; if ($value === null) { - $missingFields[] = 'has_downloads'; - goto after_hasDownloads; + $missingFields[] = 'watchers_count'; + goto after_watchersCount; } - $properties['hasDownloads'] = $value; + $properties['watchersCount'] = $value; - after_hasDownloads: + after_watchersCount: + + $value = $payload['size'] ?? null; + + if ($value === null) { + $missingFields[] = 'size'; + goto after_size; + } + + $properties['size'] = $value; + + after_size: + + $value = $payload['default_branch'] ?? null; + + if ($value === null) { + $missingFields[] = 'default_branch'; + goto after_defaultBranch; + } + + $properties['defaultBranch'] = $value; + + after_defaultBranch: + + $value = $payload['open_issues_count'] ?? null; + + if ($value === null) { + $missingFields[] = 'open_issues_count'; + goto after_openIssuesCount; + } + + $properties['openIssuesCount'] = $value; + + after_openIssuesCount: + + $value = $payload['is_template'] ?? null; + + if ($value === null) { + $properties['isTemplate'] = null; + goto after_isTemplate; + } + + $properties['isTemplate'] = $value; + + after_isTemplate: + + $value = $payload['topics'] ?? null; + + if ($value === null) { + $properties['topics'] = null; + goto after_topics; + } + + $properties['topics'] = $value; + + after_topics: $value = $payload['has_issues'] ?? null; @@ -1887,49 +2027,27 @@ private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️S after_hasPages: - $value = $payload['has_discussions'] ?? null; - - if ($value === null) { - $missingFields[] = 'has_discussions'; - goto after_hasDiscussions; - } - - $properties['hasDiscussions'] = $value; - - after_hasDiscussions: - - $value = $payload['homepage'] ?? null; - - if ($value === null) { - $properties['homepage'] = null; - goto after_homepage; - } - - $properties['homepage'] = $value; - - after_homepage: - - $value = $payload['language'] ?? null; + $value = $payload['has_downloads'] ?? null; if ($value === null) { - $properties['language'] = null; - goto after_language; + $missingFields[] = 'has_downloads'; + goto after_hasDownloads; } - $properties['language'] = $value; + $properties['hasDownloads'] = $value; - after_language: + after_hasDownloads: - $value = $payload['master_branch'] ?? null; + $value = $payload['has_discussions'] ?? null; if ($value === null) { - $properties['masterBranch'] = null; - goto after_masterBranch; + $properties['hasDiscussions'] = null; + goto after_hasDiscussions; } - $properties['masterBranch'] = $value; + $properties['hasDiscussions'] = $value; - after_masterBranch: + after_hasDiscussions: $value = $payload['archived'] ?? null; @@ -1964,58 +2082,49 @@ private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️S after_visibility: - $value = $payload['mirror_url'] ?? null; + $value = $payload['pushed_at'] ?? null; if ($value === null) { - $properties['mirrorUrl'] = null; - goto after_mirrorUrl; + $properties['pushedAt'] = null; + goto after_pushedAt; } - $properties['mirrorUrl'] = $value; + $properties['pushedAt'] = $value; - after_mirrorUrl: + after_pushedAt: - $value = $payload['open_issues'] ?? null; + $value = $payload['created_at'] ?? null; if ($value === null) { - $missingFields[] = 'open_issues'; - goto after_openIssues; + $properties['createdAt'] = null; + goto after_createdAt; } - $properties['openIssues'] = $value; + $properties['createdAt'] = $value; - after_openIssues: + after_createdAt: - $value = $payload['open_issues_count'] ?? null; + $value = $payload['updated_at'] ?? null; if ($value === null) { - $missingFields[] = 'open_issues_count'; - goto after_openIssuesCount; + $properties['updatedAt'] = null; + goto after_updatedAt; } - $properties['openIssuesCount'] = $value; + $properties['updatedAt'] = $value; - after_openIssuesCount: + after_updatedAt: - $value = $payload['permissions'] ?? null; + $value = $payload['allow_rebase_merge'] ?? null; if ($value === null) { - $properties['permissions'] = null; - goto after_permissions; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'permissions'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo⚡️Permissions($value); - } finally { - array_pop($this->hydrationStack); - } + $properties['allowRebaseMerge'] = null; + goto after_allowRebaseMerge; } - $properties['permissions'] = $value; + $properties['allowRebaseMerge'] = $value; - after_permissions: + after_allowRebaseMerge: $value = $payload['temp_clone_token'] ?? null; @@ -2028,17 +2137,6 @@ private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️S after_tempCloneToken: - $value = $payload['allow_merge_commit'] ?? null; - - if ($value === null) { - $properties['allowMergeCommit'] = null; - goto after_allowMergeCommit; - } - - $properties['allowMergeCommit'] = $value; - - after_allowMergeCommit: - $value = $payload['allow_squash_merge'] ?? null; if ($value === null) { @@ -2050,3592 +2148,1009 @@ private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️S after_allowSquashMerge: - $value = $payload['allow_rebase_merge'] ?? null; + $value = $payload['allow_auto_merge'] ?? null; if ($value === null) { - $properties['allowRebaseMerge'] = null; - goto after_allowRebaseMerge; + $properties['allowAutoMerge'] = null; + goto after_allowAutoMerge; } - $properties['allowRebaseMerge'] = $value; + $properties['allowAutoMerge'] = $value; - after_allowRebaseMerge: + after_allowAutoMerge: - $value = $payload['license'] ?? null; + $value = $payload['delete_branch_on_merge'] ?? null; if ($value === null) { - $properties['license'] = null; - goto after_license; + $properties['deleteBranchOnMerge'] = null; + goto after_deleteBranchOnMerge; } - if (is_array($value)) { - try { - $this->hydrationStack[] = 'license'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo⚡️License($value); - } finally { - array_pop($this->hydrationStack); - } + $properties['deleteBranchOnMerge'] = $value; + + after_deleteBranchOnMerge: + + $value = $payload['allow_update_branch'] ?? null; + + if ($value === null) { + $properties['allowUpdateBranch'] = null; + goto after_allowUpdateBranch; } - $properties['license'] = $value; + $properties['allowUpdateBranch'] = $value; - after_license: + after_allowUpdateBranch: - $value = $payload['pushed_at'] ?? null; + $value = $payload['use_squash_pr_title_as_default'] ?? null; if ($value === null) { - $missingFields[] = 'pushed_at'; - goto after_pushedAt; + $properties['useSquashPrTitleAsDefault'] = null; + goto after_useSquashPrTitleAsDefault; } - $properties['pushedAt'] = $value; + $properties['useSquashPrTitleAsDefault'] = $value; - after_pushedAt: + after_useSquashPrTitleAsDefault: - $value = $payload['size'] ?? null; + $value = $payload['squash_merge_commit_title'] ?? null; if ($value === null) { - $missingFields[] = 'size'; - goto after_size; + $properties['squashMergeCommitTitle'] = null; + goto after_squashMergeCommitTitle; } - $properties['size'] = $value; + $properties['squashMergeCommitTitle'] = $value; - after_size: + after_squashMergeCommitTitle: - $value = $payload['ssh_url'] ?? null; + $value = $payload['squash_merge_commit_message'] ?? null; if ($value === null) { - $missingFields[] = 'ssh_url'; - goto after_sshUrl; + $properties['squashMergeCommitMessage'] = null; + goto after_squashMergeCommitMessage; } - $properties['sshUrl'] = $value; + $properties['squashMergeCommitMessage'] = $value; - after_sshUrl: + after_squashMergeCommitMessage: - $value = $payload['stargazers_count'] ?? null; + $value = $payload['merge_commit_title'] ?? null; if ($value === null) { - $missingFields[] = 'stargazers_count'; - goto after_stargazersCount; + $properties['mergeCommitTitle'] = null; + goto after_mergeCommitTitle; } - $properties['stargazersCount'] = $value; + $properties['mergeCommitTitle'] = $value; - after_stargazersCount: + after_mergeCommitTitle: - $value = $payload['svn_url'] ?? null; + $value = $payload['merge_commit_message'] ?? null; if ($value === null) { - $missingFields[] = 'svn_url'; - goto after_svnUrl; + $properties['mergeCommitMessage'] = null; + goto after_mergeCommitMessage; } - $properties['svnUrl'] = $value; + $properties['mergeCommitMessage'] = $value; - after_svnUrl: + after_mergeCommitMessage: - $value = $payload['topics'] ?? null; + $value = $payload['allow_merge_commit'] ?? null; if ($value === null) { - $properties['topics'] = null; - goto after_topics; + $properties['allowMergeCommit'] = null; + goto after_allowMergeCommit; } - $properties['topics'] = $value; + $properties['allowMergeCommit'] = $value; - after_topics: + after_allowMergeCommit: - $value = $payload['watchers'] ?? null; + $value = $payload['allow_forking'] ?? null; if ($value === null) { - $missingFields[] = 'watchers'; - goto after_watchers; + $properties['allowForking'] = null; + goto after_allowForking; } - $properties['watchers'] = $value; + $properties['allowForking'] = $value; - after_watchers: + after_allowForking: - $value = $payload['watchers_count'] ?? null; + $value = $payload['web_commit_signoff_required'] ?? null; if ($value === null) { - $missingFields[] = 'watchers_count'; - goto after_watchersCount; + $properties['webCommitSignoffRequired'] = null; + goto after_webCommitSignoffRequired; } - $properties['watchersCount'] = $value; + $properties['webCommitSignoffRequired'] = $value; - after_watchersCount: + after_webCommitSignoffRequired: - $value = $payload['created_at'] ?? null; + $value = $payload['open_issues'] ?? null; if ($value === null) { - $missingFields[] = 'created_at'; - goto after_createdAt; + $missingFields[] = 'open_issues'; + goto after_openIssues; } - $properties['createdAt'] = $value; + $properties['openIssues'] = $value; - after_createdAt: + after_openIssues: - $value = $payload['updated_at'] ?? null; + $value = $payload['watchers'] ?? null; if ($value === null) { - $missingFields[] = 'updated_at'; - goto after_updatedAt; + $missingFields[] = 'watchers'; + goto after_watchers; } - $properties['updatedAt'] = $value; + $properties['watchers'] = $value; - after_updatedAt: + after_watchers: - $value = $payload['allow_forking'] ?? null; + $value = $payload['master_branch'] ?? null; if ($value === null) { - $properties['allowForking'] = null; - goto after_allowForking; + $properties['masterBranch'] = null; + goto after_masterBranch; } - $properties['allowForking'] = $value; + $properties['masterBranch'] = $value; - after_allowForking: + after_masterBranch: - $value = $payload['is_template'] ?? null; + $value = $payload['starred_at'] ?? null; if ($value === null) { - $properties['isTemplate'] = null; - goto after_isTemplate; + $properties['starredAt'] = null; + goto after_starredAt; } - $properties['isTemplate'] = $value; + $properties['starredAt'] = $value; - after_isTemplate: + after_starredAt: - $value = $payload['web_commit_signoff_required'] ?? null; + $value = $payload['anonymous_access_enabled'] ?? null; if ($value === null) { - $properties['webCommitSignoffRequired'] = null; - goto after_webCommitSignoffRequired; + $properties['anonymousAccessEnabled'] = null; + goto after_anonymousAccessEnabled; } - $properties['webCommitSignoffRequired'] = $value; + $properties['anonymousAccessEnabled'] = $value; - after_webCommitSignoffRequired: + after_anonymousAccessEnabled: } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo', $exception, stack: $this->hydrationStack); + throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\Repository', $exception, stack: $this->hydrationStack); } if (count($missingFields) > 0) { - throw UnableToHydrateObject::dueToMissingFields(Repo::class, $missingFields, stack: $this->hydrationStack); + throw UnableToHydrateObject::dueToMissingFields(Repository::class, $missingFields, stack: $this->hydrationStack); } try { - return new Repo(...$properties); + return new Repository(...$properties); } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo', $exception, stack: $this->hydrationStack); + throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\Repository', $exception, stack: $this->hydrationStack); } } - private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo⚡️Owner(array $payload): Owner + private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️LicenseSimple(array $payload): LicenseSimple { $properties = []; $missingFields = []; try { - $value = $payload['avatar_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'avatar_url'; - goto after_avatarUrl; - } - - $properties['avatarUrl'] = $value; - - after_avatarUrl: - - $value = $payload['events_url'] ?? null; + $value = $payload['key'] ?? null; if ($value === null) { - $missingFields[] = 'events_url'; - goto after_eventsUrl; + $missingFields[] = 'key'; + goto after_key; } - $properties['eventsUrl'] = $value; + $properties['key'] = $value; - after_eventsUrl: + after_key: - $value = $payload['followers_url'] ?? null; + $value = $payload['name'] ?? null; if ($value === null) { - $missingFields[] = 'followers_url'; - goto after_followersUrl; + $missingFields[] = 'name'; + goto after_name; } - $properties['followersUrl'] = $value; + $properties['name'] = $value; - after_followersUrl: + after_name: - $value = $payload['following_url'] ?? null; + $value = $payload['url'] ?? null; if ($value === null) { - $missingFields[] = 'following_url'; - goto after_followingUrl; + $properties['url'] = null; + goto after_url; } - $properties['followingUrl'] = $value; + $properties['url'] = $value; - after_followingUrl: + after_url: - $value = $payload['gists_url'] ?? null; + $value = $payload['spdx_id'] ?? null; if ($value === null) { - $missingFields[] = 'gists_url'; - goto after_gistsUrl; + $properties['spdxId'] = null; + goto after_spdxId; } - $properties['gistsUrl'] = $value; + $properties['spdxId'] = $value; - after_gistsUrl: + after_spdxId: - $value = $payload['gravatar_id'] ?? null; + $value = $payload['node_id'] ?? null; if ($value === null) { - $properties['gravatarId'] = null; - goto after_gravatarId; + $missingFields[] = 'node_id'; + goto after_nodeId; } - $properties['gravatarId'] = $value; + $properties['nodeId'] = $value; - after_gravatarId: + after_nodeId: $value = $payload['html_url'] ?? null; if ($value === null) { - $missingFields[] = 'html_url'; + $properties['htmlUrl'] = null; goto after_htmlUrl; } $properties['htmlUrl'] = $value; after_htmlUrl: + } catch (Throwable $exception) { + throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\LicenseSimple', $exception, stack: $this->hydrationStack); + } - $value = $payload['id'] ?? null; + if (count($missingFields) > 0) { + throw UnableToHydrateObject::dueToMissingFields(LicenseSimple::class, $missingFields, stack: $this->hydrationStack); + } + + try { + return new LicenseSimple(...$properties); + } catch (Throwable $exception) { + throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\LicenseSimple', $exception, stack: $this->hydrationStack); + } + } + + private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Repository⚡️Permissions(array $payload): Permissions + { + $properties = []; + $missingFields = []; + try { + $value = $payload['admin'] ?? null; if ($value === null) { - $missingFields[] = 'id'; - goto after_id; + $missingFields[] = 'admin'; + goto after_admin; } - $properties['id'] = $value; + $properties['admin'] = $value; - after_id: + after_admin: - $value = $payload['node_id'] ?? null; + $value = $payload['pull'] ?? null; if ($value === null) { - $missingFields[] = 'node_id'; - goto after_nodeId; + $missingFields[] = 'pull'; + goto after_pull; } - $properties['nodeId'] = $value; + $properties['pull'] = $value; - after_nodeId: + after_pull: - $value = $payload['login'] ?? null; + $value = $payload['triage'] ?? null; if ($value === null) { - $missingFields[] = 'login'; - goto after_login; + $properties['triage'] = null; + goto after_triage; } - $properties['login'] = $value; + $properties['triage'] = $value; - after_login: + after_triage: - $value = $payload['organizations_url'] ?? null; + $value = $payload['push'] ?? null; if ($value === null) { - $missingFields[] = 'organizations_url'; - goto after_organizationsUrl; + $missingFields[] = 'push'; + goto after_push; } - $properties['organizationsUrl'] = $value; + $properties['push'] = $value; - after_organizationsUrl: + after_push: - $value = $payload['received_events_url'] ?? null; + $value = $payload['maintain'] ?? null; if ($value === null) { - $missingFields[] = 'received_events_url'; - goto after_receivedEventsUrl; + $properties['maintain'] = null; + goto after_maintain; } - $properties['receivedEventsUrl'] = $value; - - after_receivedEventsUrl: - - $value = $payload['repos_url'] ?? null; + $properties['maintain'] = $value; - if ($value === null) { - $missingFields[] = 'repos_url'; - goto after_reposUrl; - } + after_maintain: + } catch (Throwable $exception) { + throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\Repository\Permissions', $exception, stack: $this->hydrationStack); + } - $properties['reposUrl'] = $value; + if (count($missingFields) > 0) { + throw UnableToHydrateObject::dueToMissingFields(Permissions::class, $missingFields, stack: $this->hydrationStack); + } - after_reposUrl: + try { + return new Permissions(...$properties); + } catch (Throwable $exception) { + throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\Repository\Permissions', $exception, stack: $this->hydrationStack); + } + } - $value = $payload['site_admin'] ?? null; + private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base(array $payload): Base + { + $properties = []; + $missingFields = []; + try { + $value = $payload['label'] ?? null; if ($value === null) { - $missingFields[] = 'site_admin'; - goto after_siteAdmin; + $missingFields[] = 'label'; + goto after_label; } - $properties['siteAdmin'] = $value; + $properties['label'] = $value; - after_siteAdmin: + after_label: - $value = $payload['starred_url'] ?? null; + $value = $payload['ref'] ?? null; if ($value === null) { - $missingFields[] = 'starred_url'; - goto after_starredUrl; + $missingFields[] = 'ref'; + goto after_ref; } - $properties['starredUrl'] = $value; + $properties['ref'] = $value; - after_starredUrl: + after_ref: - $value = $payload['subscriptions_url'] ?? null; + $value = $payload['repo'] ?? null; if ($value === null) { - $missingFields[] = 'subscriptions_url'; - goto after_subscriptionsUrl; + $missingFields[] = 'repo'; + goto after_repo; } - $properties['subscriptionsUrl'] = $value; - - after_subscriptionsUrl: - - $value = $payload['type'] ?? null; - - if ($value === null) { - $missingFields[] = 'type'; - goto after_type; + if (is_array($value)) { + try { + $this->hydrationStack[] = 'repo'; + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Repository($value); + } finally { + array_pop($this->hydrationStack); + } } - $properties['type'] = $value; + $properties['repo'] = $value; - after_type: + after_repo: - $value = $payload['url'] ?? null; + $value = $payload['sha'] ?? null; if ($value === null) { - $missingFields[] = 'url'; - goto after_url; + $missingFields[] = 'sha'; + goto after_sha; } - $properties['url'] = $value; + $properties['sha'] = $value; - after_url: + after_sha: - $value = $payload['user_view_type'] ?? null; + $value = $payload['user'] ?? null; if ($value === null) { - $properties['userViewType'] = null; - goto after_userViewType; + $missingFields[] = 'user'; + goto after_user; } - $properties['userViewType'] = $value; + if (is_array($value)) { + try { + $this->hydrationStack[] = 'user'; + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleUser($value); + } finally { + array_pop($this->hydrationStack); + } + } - after_userViewType: + $properties['user'] = $value; + + after_user: } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo\Owner', $exception, stack: $this->hydrationStack); + throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base', $exception, stack: $this->hydrationStack); } if (count($missingFields) > 0) { - throw UnableToHydrateObject::dueToMissingFields(Owner::class, $missingFields, stack: $this->hydrationStack); + throw UnableToHydrateObject::dueToMissingFields(Base::class, $missingFields, stack: $this->hydrationStack); } try { - return new Owner(...$properties); + return new Base(...$properties); } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo\Owner', $exception, stack: $this->hydrationStack); + throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base', $exception, stack: $this->hydrationStack); } } - private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo⚡️Permissions(array $payload): Permissions + private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Links(array $payload): Links { $properties = []; $missingFields = []; try { - $value = $payload['admin'] ?? null; + $value = $payload['comments'] ?? null; if ($value === null) { - $missingFields[] = 'admin'; - goto after_admin; + $missingFields[] = 'comments'; + goto after_comments; } - $properties['admin'] = $value; - - after_admin: - - $value = $payload['maintain'] ?? null; - - if ($value === null) { - $properties['maintain'] = null; - goto after_maintain; + if (is_array($value)) { + try { + $this->hydrationStack[] = 'comments'; + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Link($value); + } finally { + array_pop($this->hydrationStack); + } } - $properties['maintain'] = $value; + $properties['comments'] = $value; - after_maintain: + after_comments: - $value = $payload['push'] ?? null; + $value = $payload['commits'] ?? null; if ($value === null) { - $missingFields[] = 'push'; - goto after_push; + $missingFields[] = 'commits'; + goto after_commits; } - $properties['push'] = $value; - - after_push: - - $value = $payload['triage'] ?? null; - - if ($value === null) { - $properties['triage'] = null; - goto after_triage; + if (is_array($value)) { + try { + $this->hydrationStack[] = 'commits'; + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Link($value); + } finally { + array_pop($this->hydrationStack); + } } - $properties['triage'] = $value; + $properties['commits'] = $value; - after_triage: + after_commits: - $value = $payload['pull'] ?? null; + $value = $payload['statuses'] ?? null; if ($value === null) { - $missingFields[] = 'pull'; - goto after_pull; + $missingFields[] = 'statuses'; + goto after_statuses; } - $properties['pull'] = $value; - - after_pull: - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo\Permissions', $exception, stack: $this->hydrationStack); - } + if (is_array($value)) { + try { + $this->hydrationStack[] = 'statuses'; + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Link($value); + } finally { + array_pop($this->hydrationStack); + } + } - if (count($missingFields) > 0) { - throw UnableToHydrateObject::dueToMissingFields(Permissions::class, $missingFields, stack: $this->hydrationStack); - } + $properties['statuses'] = $value; - try { - return new Permissions(...$properties); - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo\Permissions', $exception, stack: $this->hydrationStack); - } - } + after_statuses: - private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo⚡️License(array $payload): License - { - $properties = []; - $missingFields = []; - try { - $value = $payload['key'] ?? null; + $value = $payload['html'] ?? null; if ($value === null) { - $missingFields[] = 'key'; - goto after_key; + $missingFields[] = 'html'; + goto after_html; } - $properties['key'] = $value; + if (is_array($value)) { + try { + $this->hydrationStack[] = 'html'; + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Link($value); + } finally { + array_pop($this->hydrationStack); + } + } - after_key: + $properties['html'] = $value; - $value = $payload['name'] ?? null; + after_html: + + $value = $payload['issue'] ?? null; if ($value === null) { - $missingFields[] = 'name'; - goto after_name; + $missingFields[] = 'issue'; + goto after_issue; } - $properties['name'] = $value; + if (is_array($value)) { + try { + $this->hydrationStack[] = 'issue'; + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Link($value); + } finally { + array_pop($this->hydrationStack); + } + } - after_name: + $properties['issue'] = $value; - $value = $payload['url'] ?? null; + after_issue: + + $value = $payload['review_comments'] ?? null; if ($value === null) { - $properties['url'] = null; - goto after_url; + $missingFields[] = 'review_comments'; + goto after_reviewComments; } - $properties['url'] = $value; + if (is_array($value)) { + try { + $this->hydrationStack[] = 'reviewComments'; + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Link($value); + } finally { + array_pop($this->hydrationStack); + } + } - after_url: + $properties['reviewComments'] = $value; - $value = $payload['spdx_id'] ?? null; + after_reviewComments: + + $value = $payload['review_comment'] ?? null; if ($value === null) { - $properties['spdxId'] = null; - goto after_spdxId; + $missingFields[] = 'review_comment'; + goto after_reviewComment; } - $properties['spdxId'] = $value; + if (is_array($value)) { + try { + $this->hydrationStack[] = 'reviewComment'; + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Link($value); + } finally { + array_pop($this->hydrationStack); + } + } - after_spdxId: + $properties['reviewComment'] = $value; - $value = $payload['node_id'] ?? null; + after_reviewComment: + + $value = $payload['self'] ?? null; if ($value === null) { - $missingFields[] = 'node_id'; - goto after_nodeId; + $missingFields[] = 'self'; + goto after_self; } - $properties['nodeId'] = $value; + if (is_array($value)) { + try { + $this->hydrationStack[] = 'self'; + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Link($value); + } finally { + array_pop($this->hydrationStack); + } + } - after_nodeId: + $properties['self'] = $value; + + after_self: } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo\License', $exception, stack: $this->hydrationStack); + throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Links', $exception, stack: $this->hydrationStack); } if (count($missingFields) > 0) { - throw UnableToHydrateObject::dueToMissingFields(License::class, $missingFields, stack: $this->hydrationStack); + throw UnableToHydrateObject::dueToMissingFields(Links::class, $missingFields, stack: $this->hydrationStack); } try { - return new License(...$properties); + return new Links(...$properties); } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo\License', $exception, stack: $this->hydrationStack); + throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Links', $exception, stack: $this->hydrationStack); } } - private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️User(array $payload): User + private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Link(array $payload): Link { $properties = []; $missingFields = []; try { - $value = $payload['avatar_url'] ?? null; + $value = $payload['href'] ?? null; if ($value === null) { - $missingFields[] = 'avatar_url'; - goto after_avatarUrl; + $missingFields[] = 'href'; + goto after_href; } - $properties['avatarUrl'] = $value; - - after_avatarUrl: - - $value = $payload['events_url'] ?? null; + $properties['href'] = $value; - if ($value === null) { - $missingFields[] = 'events_url'; - goto after_eventsUrl; - } + after_href: + } catch (Throwable $exception) { + throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\Link', $exception, stack: $this->hydrationStack); + } - $properties['eventsUrl'] = $value; + if (count($missingFields) > 0) { + throw UnableToHydrateObject::dueToMissingFields(Link::class, $missingFields, stack: $this->hydrationStack); + } - after_eventsUrl: + try { + return new Link(...$properties); + } catch (Throwable $exception) { + throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\Link', $exception, stack: $this->hydrationStack); + } + } - $value = $payload['followers_url'] ?? null; + private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️AutoMerge(array $payload): AutoMerge + { + $properties = []; + $missingFields = []; + try { + $value = $payload['enabled_by'] ?? null; if ($value === null) { - $missingFields[] = 'followers_url'; - goto after_followersUrl; + $missingFields[] = 'enabled_by'; + goto after_enabledBy; } - $properties['followersUrl'] = $value; - - after_followersUrl: - - $value = $payload['following_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'following_url'; - goto after_followingUrl; + if (is_array($value)) { + try { + $this->hydrationStack[] = 'enabledBy'; + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleUser($value); + } finally { + array_pop($this->hydrationStack); + } } - $properties['followingUrl'] = $value; + $properties['enabledBy'] = $value; - after_followingUrl: + after_enabledBy: - $value = $payload['gists_url'] ?? null; + $value = $payload['merge_method'] ?? null; if ($value === null) { - $missingFields[] = 'gists_url'; - goto after_gistsUrl; + $missingFields[] = 'merge_method'; + goto after_mergeMethod; } - $properties['gistsUrl'] = $value; + $properties['mergeMethod'] = $value; - after_gistsUrl: + after_mergeMethod: - $value = $payload['gravatar_id'] ?? null; + $value = $payload['commit_title'] ?? null; if ($value === null) { - $properties['gravatarId'] = null; - goto after_gravatarId; + $missingFields[] = 'commit_title'; + goto after_commitTitle; } - $properties['gravatarId'] = $value; + $properties['commitTitle'] = $value; - after_gravatarId: + after_commitTitle: - $value = $payload['html_url'] ?? null; + $value = $payload['commit_message'] ?? null; if ($value === null) { - $missingFields[] = 'html_url'; - goto after_htmlUrl; + $missingFields[] = 'commit_message'; + goto after_commitMessage; } - $properties['htmlUrl'] = $value; + $properties['commitMessage'] = $value; - after_htmlUrl: + after_commitMessage: + } catch (Throwable $exception) { + throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\AutoMerge', $exception, stack: $this->hydrationStack); + } - $value = $payload['id'] ?? null; + if (count($missingFields) > 0) { + throw UnableToHydrateObject::dueToMissingFields(AutoMerge::class, $missingFields, stack: $this->hydrationStack); + } + + try { + return new AutoMerge(...$properties); + } catch (Throwable $exception) { + throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\AutoMerge', $exception, stack: $this->hydrationStack); + } + } + + private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️BasicError(array $payload): BasicError + { + $properties = []; + $missingFields = []; + try { + $value = $payload['message'] ?? null; if ($value === null) { - $missingFields[] = 'id'; - goto after_id; + $properties['message'] = null; + goto after_message; } - $properties['id'] = $value; + $properties['message'] = $value; - after_id: + after_message: - $value = $payload['node_id'] ?? null; + $value = $payload['documentation_url'] ?? null; if ($value === null) { - $missingFields[] = 'node_id'; - goto after_nodeId; + $properties['documentationUrl'] = null; + goto after_documentationUrl; } - $properties['nodeId'] = $value; + $properties['documentationUrl'] = $value; - after_nodeId: + after_documentationUrl: - $value = $payload['login'] ?? null; + $value = $payload['url'] ?? null; if ($value === null) { - $missingFields[] = 'login'; - goto after_login; + $properties['url'] = null; + goto after_url; } - $properties['login'] = $value; + $properties['url'] = $value; - after_login: + after_url: - $value = $payload['organizations_url'] ?? null; + $value = $payload['status'] ?? null; if ($value === null) { - $missingFields[] = 'organizations_url'; - goto after_organizationsUrl; + $properties['status'] = null; + goto after_status; } - $properties['organizationsUrl'] = $value; + $properties['status'] = $value; - after_organizationsUrl: + after_status: + } catch (Throwable $exception) { + throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\BasicError', $exception, stack: $this->hydrationStack); + } - $value = $payload['received_events_url'] ?? null; + if (count($missingFields) > 0) { + throw UnableToHydrateObject::dueToMissingFields(BasicError::class, $missingFields, stack: $this->hydrationStack); + } + + try { + return new BasicError(...$properties); + } catch (Throwable $exception) { + throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\BasicError', $exception, stack: $this->hydrationStack); + } + } + + private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Operations⚡️CodeScanning⚡️ListAlertsForEnterprise⚡️Response⚡️ApplicationJson⚡️ServiceUnavailable(array $payload): ServiceUnavailable + { + $properties = []; + $missingFields = []; + try { + $value = $payload['code'] ?? null; if ($value === null) { - $missingFields[] = 'received_events_url'; - goto after_receivedEventsUrl; + $properties['code'] = null; + goto after_code; } - $properties['receivedEventsUrl'] = $value; + $properties['code'] = $value; - after_receivedEventsUrl: + after_code: - $value = $payload['repos_url'] ?? null; + $value = $payload['message'] ?? null; if ($value === null) { - $missingFields[] = 'repos_url'; - goto after_reposUrl; + $properties['message'] = null; + goto after_message; } - $properties['reposUrl'] = $value; + $properties['message'] = $value; - after_reposUrl: + after_message: - $value = $payload['site_admin'] ?? null; + $value = $payload['documentation_url'] ?? null; if ($value === null) { - $missingFields[] = 'site_admin'; - goto after_siteAdmin; + $properties['documentationUrl'] = null; + goto after_documentationUrl; } - $properties['siteAdmin'] = $value; - - after_siteAdmin: + $properties['documentationUrl'] = $value; - $value = $payload['starred_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'starred_url'; - goto after_starredUrl; - } - - $properties['starredUrl'] = $value; - - after_starredUrl: - - $value = $payload['subscriptions_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'subscriptions_url'; - goto after_subscriptionsUrl; - } - - $properties['subscriptionsUrl'] = $value; - - after_subscriptionsUrl: - - $value = $payload['type'] ?? null; - - if ($value === null) { - $missingFields[] = 'type'; - goto after_type; - } - - $properties['type'] = $value; - - after_type: - - $value = $payload['url'] ?? null; - - if ($value === null) { - $missingFields[] = 'url'; - goto after_url; - } - - $properties['url'] = $value; - - after_url: - - $value = $payload['user_view_type'] ?? null; - - if ($value === null) { - $properties['userViewType'] = null; - goto after_userViewType; - } - - $properties['userViewType'] = $value; - - after_userViewType: + after_documentationUrl: } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\User', $exception, stack: $this->hydrationStack); + throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\Operations\CodeScanning\ListAlertsForEnterprise\Response\ApplicationJson\ServiceUnavailable', $exception, stack: $this->hydrationStack); } if (count($missingFields) > 0) { - throw UnableToHydrateObject::dueToMissingFields(User::class, $missingFields, stack: $this->hydrationStack); + throw UnableToHydrateObject::dueToMissingFields(ServiceUnavailable::class, $missingFields, stack: $this->hydrationStack); } try { - return new User(...$properties); + return new ServiceUnavailable(...$properties); } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\User', $exception, stack: $this->hydrationStack); + throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\Operations\CodeScanning\ListAlertsForEnterprise\Response\ApplicationJson\ServiceUnavailable', $exception, stack: $this->hydrationStack); } } - private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base(array $payload): Base + private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️ValidationError(array $payload): ValidationError { $properties = []; $missingFields = []; try { - $value = $payload['label'] ?? null; - - if ($value === null) { - $missingFields[] = 'label'; - goto after_label; - } - - $properties['label'] = $value; - - after_label: - - $value = $payload['ref'] ?? null; - - if ($value === null) { - $missingFields[] = 'ref'; - goto after_ref; - } - - $properties['ref'] = $value; - - after_ref: - - $value = $payload['repo'] ?? null; + $value = $payload['message'] ?? null; if ($value === null) { - $missingFields[] = 'repo'; - goto after_repo; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'repo'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️Repo($value); - } finally { - array_pop($this->hydrationStack); - } + $missingFields[] = 'message'; + goto after_message; } - $properties['repo'] = $value; + $properties['message'] = $value; - after_repo: + after_message: - $value = $payload['sha'] ?? null; + $value = $payload['documentation_url'] ?? null; if ($value === null) { - $missingFields[] = 'sha'; - goto after_sha; + $missingFields[] = 'documentation_url'; + goto after_documentationUrl; } - $properties['sha'] = $value; + $properties['documentationUrl'] = $value; - after_sha: + after_documentationUrl: - $value = $payload['user'] ?? null; + $value = $payload['errors'] ?? null; if ($value === null) { - $missingFields[] = 'user'; - goto after_user; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'user'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️User($value); - } finally { - array_pop($this->hydrationStack); - } + $properties['errors'] = null; + goto after_errors; } - $properties['user'] = $value; + $properties['errors'] = $value; - after_user: + after_errors: } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base', $exception, stack: $this->hydrationStack); + throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\ValidationError', $exception, stack: $this->hydrationStack); } if (count($missingFields) > 0) { - throw UnableToHydrateObject::dueToMissingFields(Base::class, $missingFields, stack: $this->hydrationStack); + throw UnableToHydrateObject::dueToMissingFields(ValidationError::class, $missingFields, stack: $this->hydrationStack); } try { - return new Base(...$properties); + return new ValidationError(...$properties); } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base', $exception, stack: $this->hydrationStack); + throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\ValidationError', $exception, stack: $this->hydrationStack); } } - private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️Repo(array $payload): \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo + private function serializeViaTypeMap(string $accessor, object $object, array $payloadToTypeMap): array { - $properties = []; - $missingFields = []; - try { - $value = $payload['archive_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'archive_url'; - goto after_archiveUrl; + foreach ($payloadToTypeMap as $payloadType => [$valueType, $method]) { + if (is_a($object, $valueType)) { + return [$accessor => $payloadType] + $this->{$method}($object); } + } - $properties['archiveUrl'] = $value; + throw new LogicException('No type mapped for object of class: ' . $object::class); + } - after_archiveUrl: + public function serializeObject(object $object): mixed + { + return $this->serializeObjectOfType($object, $object::class); + } - $value = $payload['assignees_url'] ?? null; + /** + * @param T $object + * @param class-string $className + * + * @template T + */ + public function serializeObjectOfType(object $object, string $className): mixed + { + try { + return match ($className) { + 'array' => $this->serializeValuearray($object), + 'Ramsey\Uuid\UuidInterface' => $this->serializeValueRamsey⚡️Uuid⚡️UuidInterface($object), + 'DateTime' => $this->serializeValueDateTime($object), + 'DateTimeImmutable' => $this->serializeValueDateTimeImmutable($object), + 'DateTimeInterface' => $this->serializeValueDateTimeInterface($object), + 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest($object), + 'ApiClients\Client\GitHubEnterpriseCloud\Schema\SimpleUser' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleUser($object), + 'ApiClients\Client\GitHubEnterpriseCloud\Schema\Milestone' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Milestone($object), + 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head($object), + 'ApiClients\Client\GitHubEnterpriseCloud\Schema\Repository' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Repository($object), + 'ApiClients\Client\GitHubEnterpriseCloud\Schema\LicenseSimple' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️LicenseSimple($object), + 'ApiClients\Client\GitHubEnterpriseCloud\Schema\Repository\Permissions' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Repository⚡️Permissions($object), + 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base($object), + 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Links' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Links($object), + 'ApiClients\Client\GitHubEnterpriseCloud\Schema\Link' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Link($object), + 'ApiClients\Client\GitHubEnterpriseCloud\Schema\AutoMerge' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️AutoMerge($object), + 'ApiClients\Client\GitHubEnterpriseCloud\Schema\BasicError' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️BasicError($object), + 'ApiClients\Client\GitHubEnterpriseCloud\Schema\Operations\CodeScanning\ListAlertsForEnterprise\Response\ApplicationJson\ServiceUnavailable' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Operations⚡️CodeScanning⚡️ListAlertsForEnterprise⚡️Response⚡️ApplicationJson⚡️ServiceUnavailable($object), + 'ApiClients\Client\GitHubEnterpriseCloud\Schema\ValidationError' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️ValidationError($object), + default => throw new LogicException("No serialization defined for $className"), + }; + } catch (Throwable $exception) { + throw UnableToSerializeObject::dueToError($className, $exception); + } + } - if ($value === null) { - $missingFields[] = 'assignees_url'; - goto after_assigneesUrl; - } + private function serializeValuearray(mixed $value): mixed + { + static $serializer; - $properties['assigneesUrl'] = $value; + if ($serializer === null) { + $serializer = new SerializeArrayItems(...[]); + } - after_assigneesUrl: + return $serializer->serialize($value, $this); + } - $value = $payload['blobs_url'] ?? null; + private function serializeValueRamsey⚡️Uuid⚡️UuidInterface(mixed $value): mixed + { + static $serializer; - if ($value === null) { - $missingFields[] = 'blobs_url'; - goto after_blobsUrl; - } + if ($serializer === null) { + $serializer = new SerializeUuidToString(...[]); + } - $properties['blobsUrl'] = $value; + return $serializer->serialize($value, $this); + } - after_blobsUrl: + private function serializeValueDateTime(mixed $value): mixed + { + static $serializer; - $value = $payload['branches_url'] ?? null; + if ($serializer === null) { + $serializer = new SerializeDateTime(...[]); + } - if ($value === null) { - $missingFields[] = 'branches_url'; - goto after_branchesUrl; - } + return $serializer->serialize($value, $this); + } - $properties['branchesUrl'] = $value; + private function serializeValueDateTimeImmutable(mixed $value): mixed + { + static $serializer; - after_branchesUrl: + if ($serializer === null) { + $serializer = new SerializeDateTime(...[]); + } - $value = $payload['collaborators_url'] ?? null; + return $serializer->serialize($value, $this); + } - if ($value === null) { - $missingFields[] = 'collaborators_url'; - goto after_collaboratorsUrl; - } + private function serializeValueDateTimeInterface(mixed $value): mixed + { + static $serializer; - $properties['collaboratorsUrl'] = $value; + if ($serializer === null) { + $serializer = new SerializeDateTime(...[]); + } - after_collaboratorsUrl: - - $value = $payload['comments_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'comments_url'; - goto after_commentsUrl; - } - - $properties['commentsUrl'] = $value; - - after_commentsUrl: - - $value = $payload['commits_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'commits_url'; - goto after_commitsUrl; - } - - $properties['commitsUrl'] = $value; - - after_commitsUrl: - - $value = $payload['compare_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'compare_url'; - goto after_compareUrl; - } - - $properties['compareUrl'] = $value; - - after_compareUrl: - - $value = $payload['contents_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'contents_url'; - goto after_contentsUrl; - } - - $properties['contentsUrl'] = $value; - - after_contentsUrl: - - $value = $payload['contributors_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'contributors_url'; - goto after_contributorsUrl; - } - - $properties['contributorsUrl'] = $value; - - after_contributorsUrl: - - $value = $payload['deployments_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'deployments_url'; - goto after_deploymentsUrl; - } - - $properties['deploymentsUrl'] = $value; - - after_deploymentsUrl: - - $value = $payload['description'] ?? null; - - if ($value === null) { - $properties['description'] = null; - goto after_description; - } - - $properties['description'] = $value; - - after_description: - - $value = $payload['downloads_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'downloads_url'; - goto after_downloadsUrl; - } - - $properties['downloadsUrl'] = $value; - - after_downloadsUrl: - - $value = $payload['events_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'events_url'; - goto after_eventsUrl; - } - - $properties['eventsUrl'] = $value; - - after_eventsUrl: - - $value = $payload['fork'] ?? null; - - if ($value === null) { - $missingFields[] = 'fork'; - goto after_fork; - } - - $properties['fork'] = $value; - - after_fork: - - $value = $payload['forks_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'forks_url'; - goto after_forksUrl; - } - - $properties['forksUrl'] = $value; - - after_forksUrl: - - $value = $payload['full_name'] ?? null; - - if ($value === null) { - $missingFields[] = 'full_name'; - goto after_fullName; - } - - $properties['fullName'] = $value; - - after_fullName: - - $value = $payload['git_commits_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'git_commits_url'; - goto after_gitCommitsUrl; - } - - $properties['gitCommitsUrl'] = $value; - - after_gitCommitsUrl: - - $value = $payload['git_refs_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'git_refs_url'; - goto after_gitRefsUrl; - } - - $properties['gitRefsUrl'] = $value; - - after_gitRefsUrl: - - $value = $payload['git_tags_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'git_tags_url'; - goto after_gitTagsUrl; - } - - $properties['gitTagsUrl'] = $value; - - after_gitTagsUrl: - - $value = $payload['hooks_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'hooks_url'; - goto after_hooksUrl; - } - - $properties['hooksUrl'] = $value; - - after_hooksUrl: - - $value = $payload['html_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'html_url'; - goto after_htmlUrl; - } - - $properties['htmlUrl'] = $value; - - after_htmlUrl: - - $value = $payload['id'] ?? null; - - if ($value === null) { - $missingFields[] = 'id'; - goto after_id; - } - - $properties['id'] = $value; - - after_id: - - $value = $payload['is_template'] ?? null; - - if ($value === null) { - $properties['isTemplate'] = null; - goto after_isTemplate; - } - - $properties['isTemplate'] = $value; - - after_isTemplate: - - $value = $payload['node_id'] ?? null; - - if ($value === null) { - $missingFields[] = 'node_id'; - goto after_nodeId; - } - - $properties['nodeId'] = $value; - - after_nodeId: - - $value = $payload['issue_comment_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'issue_comment_url'; - goto after_issueCommentUrl; - } - - $properties['issueCommentUrl'] = $value; - - after_issueCommentUrl: - - $value = $payload['issue_events_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'issue_events_url'; - goto after_issueEventsUrl; - } - - $properties['issueEventsUrl'] = $value; - - after_issueEventsUrl: - - $value = $payload['issues_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'issues_url'; - goto after_issuesUrl; - } - - $properties['issuesUrl'] = $value; - - after_issuesUrl: - - $value = $payload['keys_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'keys_url'; - goto after_keysUrl; - } - - $properties['keysUrl'] = $value; - - after_keysUrl: - - $value = $payload['labels_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'labels_url'; - goto after_labelsUrl; - } - - $properties['labelsUrl'] = $value; - - after_labelsUrl: - - $value = $payload['languages_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'languages_url'; - goto after_languagesUrl; - } - - $properties['languagesUrl'] = $value; - - after_languagesUrl: - - $value = $payload['merges_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'merges_url'; - goto after_mergesUrl; - } - - $properties['mergesUrl'] = $value; - - after_mergesUrl: - - $value = $payload['milestones_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'milestones_url'; - goto after_milestonesUrl; - } - - $properties['milestonesUrl'] = $value; - - after_milestonesUrl: - - $value = $payload['name'] ?? null; - - if ($value === null) { - $missingFields[] = 'name'; - goto after_name; - } - - $properties['name'] = $value; - - after_name: - - $value = $payload['notifications_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'notifications_url'; - goto after_notificationsUrl; - } - - $properties['notificationsUrl'] = $value; - - after_notificationsUrl: - - $value = $payload['owner'] ?? null; - - if ($value === null) { - $missingFields[] = 'owner'; - goto after_owner; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'owner'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️Repo⚡️Owner($value); - } finally { - array_pop($this->hydrationStack); - } - } - - $properties['owner'] = $value; - - after_owner: - - $value = $payload['private'] ?? null; - - if ($value === null) { - $missingFields[] = 'private'; - goto after_private; - } - - $properties['private'] = $value; - - after_private: - - $value = $payload['pulls_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'pulls_url'; - goto after_pullsUrl; - } - - $properties['pullsUrl'] = $value; - - after_pullsUrl: - - $value = $payload['releases_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'releases_url'; - goto after_releasesUrl; - } - - $properties['releasesUrl'] = $value; - - after_releasesUrl: - - $value = $payload['stargazers_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'stargazers_url'; - goto after_stargazersUrl; - } - - $properties['stargazersUrl'] = $value; - - after_stargazersUrl: - - $value = $payload['statuses_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'statuses_url'; - goto after_statusesUrl; - } - - $properties['statusesUrl'] = $value; - - after_statusesUrl: - - $value = $payload['subscribers_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'subscribers_url'; - goto after_subscribersUrl; - } - - $properties['subscribersUrl'] = $value; - - after_subscribersUrl: - - $value = $payload['subscription_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'subscription_url'; - goto after_subscriptionUrl; - } - - $properties['subscriptionUrl'] = $value; - - after_subscriptionUrl: - - $value = $payload['tags_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'tags_url'; - goto after_tagsUrl; - } - - $properties['tagsUrl'] = $value; - - after_tagsUrl: - - $value = $payload['teams_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'teams_url'; - goto after_teamsUrl; - } - - $properties['teamsUrl'] = $value; - - after_teamsUrl: - - $value = $payload['trees_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'trees_url'; - goto after_treesUrl; - } - - $properties['treesUrl'] = $value; - - after_treesUrl: - - $value = $payload['url'] ?? null; - - if ($value === null) { - $missingFields[] = 'url'; - goto after_url; - } - - $properties['url'] = $value; - - after_url: - - $value = $payload['clone_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'clone_url'; - goto after_cloneUrl; - } - - $properties['cloneUrl'] = $value; - - after_cloneUrl: - - $value = $payload['default_branch'] ?? null; - - if ($value === null) { - $missingFields[] = 'default_branch'; - goto after_defaultBranch; - } - - $properties['defaultBranch'] = $value; - - after_defaultBranch: - - $value = $payload['forks'] ?? null; - - if ($value === null) { - $missingFields[] = 'forks'; - goto after_forks; - } - - $properties['forks'] = $value; - - after_forks: - - $value = $payload['forks_count'] ?? null; - - if ($value === null) { - $missingFields[] = 'forks_count'; - goto after_forksCount; - } - - $properties['forksCount'] = $value; - - after_forksCount: - - $value = $payload['git_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'git_url'; - goto after_gitUrl; - } - - $properties['gitUrl'] = $value; - - after_gitUrl: - - $value = $payload['has_downloads'] ?? null; - - if ($value === null) { - $missingFields[] = 'has_downloads'; - goto after_hasDownloads; - } - - $properties['hasDownloads'] = $value; - - after_hasDownloads: - - $value = $payload['has_issues'] ?? null; - - if ($value === null) { - $missingFields[] = 'has_issues'; - goto after_hasIssues; - } - - $properties['hasIssues'] = $value; - - after_hasIssues: - - $value = $payload['has_projects'] ?? null; - - if ($value === null) { - $missingFields[] = 'has_projects'; - goto after_hasProjects; - } - - $properties['hasProjects'] = $value; - - after_hasProjects: - - $value = $payload['has_wiki'] ?? null; - - if ($value === null) { - $missingFields[] = 'has_wiki'; - goto after_hasWiki; - } - - $properties['hasWiki'] = $value; - - after_hasWiki: - - $value = $payload['has_pages'] ?? null; - - if ($value === null) { - $missingFields[] = 'has_pages'; - goto after_hasPages; - } - - $properties['hasPages'] = $value; - - after_hasPages: - - $value = $payload['has_discussions'] ?? null; - - if ($value === null) { - $missingFields[] = 'has_discussions'; - goto after_hasDiscussions; - } - - $properties['hasDiscussions'] = $value; - - after_hasDiscussions: - - $value = $payload['homepage'] ?? null; - - if ($value === null) { - $properties['homepage'] = null; - goto after_homepage; - } - - $properties['homepage'] = $value; - - after_homepage: - - $value = $payload['language'] ?? null; - - if ($value === null) { - $properties['language'] = null; - goto after_language; - } - - $properties['language'] = $value; - - after_language: - - $value = $payload['master_branch'] ?? null; - - if ($value === null) { - $properties['masterBranch'] = null; - goto after_masterBranch; - } - - $properties['masterBranch'] = $value; - - after_masterBranch: - - $value = $payload['archived'] ?? null; - - if ($value === null) { - $missingFields[] = 'archived'; - goto after_archived; - } - - $properties['archived'] = $value; - - after_archived: - - $value = $payload['disabled'] ?? null; - - if ($value === null) { - $missingFields[] = 'disabled'; - goto after_disabled; - } - - $properties['disabled'] = $value; - - after_disabled: - - $value = $payload['visibility'] ?? null; - - if ($value === null) { - $properties['visibility'] = null; - goto after_visibility; - } - - $properties['visibility'] = $value; - - after_visibility: - - $value = $payload['mirror_url'] ?? null; - - if ($value === null) { - $properties['mirrorUrl'] = null; - goto after_mirrorUrl; - } - - $properties['mirrorUrl'] = $value; - - after_mirrorUrl: - - $value = $payload['open_issues'] ?? null; - - if ($value === null) { - $missingFields[] = 'open_issues'; - goto after_openIssues; - } - - $properties['openIssues'] = $value; - - after_openIssues: - - $value = $payload['open_issues_count'] ?? null; - - if ($value === null) { - $missingFields[] = 'open_issues_count'; - goto after_openIssuesCount; - } - - $properties['openIssuesCount'] = $value; - - after_openIssuesCount: - - $value = $payload['permissions'] ?? null; - - if ($value === null) { - $properties['permissions'] = null; - goto after_permissions; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'permissions'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️Repo⚡️Permissions($value); - } finally { - array_pop($this->hydrationStack); - } - } - - $properties['permissions'] = $value; - - after_permissions: - - $value = $payload['temp_clone_token'] ?? null; - - if ($value === null) { - $properties['tempCloneToken'] = null; - goto after_tempCloneToken; - } - - $properties['tempCloneToken'] = $value; - - after_tempCloneToken: - - $value = $payload['allow_merge_commit'] ?? null; - - if ($value === null) { - $properties['allowMergeCommit'] = null; - goto after_allowMergeCommit; - } - - $properties['allowMergeCommit'] = $value; - - after_allowMergeCommit: - - $value = $payload['allow_squash_merge'] ?? null; - - if ($value === null) { - $properties['allowSquashMerge'] = null; - goto after_allowSquashMerge; - } - - $properties['allowSquashMerge'] = $value; - - after_allowSquashMerge: - - $value = $payload['allow_rebase_merge'] ?? null; - - if ($value === null) { - $properties['allowRebaseMerge'] = null; - goto after_allowRebaseMerge; - } - - $properties['allowRebaseMerge'] = $value; - - after_allowRebaseMerge: - - $value = $payload['license'] ?? null; - - if ($value === null) { - $properties['license'] = null; - goto after_license; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'license'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️LicenseSimple($value); - } finally { - array_pop($this->hydrationStack); - } - } - - $properties['license'] = $value; - - after_license: - - $value = $payload['pushed_at'] ?? null; - - if ($value === null) { - $missingFields[] = 'pushed_at'; - goto after_pushedAt; - } - - $properties['pushedAt'] = $value; - - after_pushedAt: - - $value = $payload['size'] ?? null; - - if ($value === null) { - $missingFields[] = 'size'; - goto after_size; - } - - $properties['size'] = $value; - - after_size: - - $value = $payload['ssh_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'ssh_url'; - goto after_sshUrl; - } - - $properties['sshUrl'] = $value; - - after_sshUrl: - - $value = $payload['stargazers_count'] ?? null; - - if ($value === null) { - $missingFields[] = 'stargazers_count'; - goto after_stargazersCount; - } - - $properties['stargazersCount'] = $value; - - after_stargazersCount: - - $value = $payload['svn_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'svn_url'; - goto after_svnUrl; - } - - $properties['svnUrl'] = $value; - - after_svnUrl: - - $value = $payload['topics'] ?? null; - - if ($value === null) { - $properties['topics'] = null; - goto after_topics; - } - - $properties['topics'] = $value; - - after_topics: - - $value = $payload['watchers'] ?? null; - - if ($value === null) { - $missingFields[] = 'watchers'; - goto after_watchers; - } - - $properties['watchers'] = $value; - - after_watchers: - - $value = $payload['watchers_count'] ?? null; - - if ($value === null) { - $missingFields[] = 'watchers_count'; - goto after_watchersCount; - } - - $properties['watchersCount'] = $value; - - after_watchersCount: - - $value = $payload['created_at'] ?? null; - - if ($value === null) { - $missingFields[] = 'created_at'; - goto after_createdAt; - } - - $properties['createdAt'] = $value; - - after_createdAt: - - $value = $payload['updated_at'] ?? null; - - if ($value === null) { - $missingFields[] = 'updated_at'; - goto after_updatedAt; - } - - $properties['updatedAt'] = $value; - - after_updatedAt: - - $value = $payload['allow_forking'] ?? null; - - if ($value === null) { - $properties['allowForking'] = null; - goto after_allowForking; - } - - $properties['allowForking'] = $value; - - after_allowForking: - - $value = $payload['web_commit_signoff_required'] ?? null; - - if ($value === null) { - $properties['webCommitSignoffRequired'] = null; - goto after_webCommitSignoffRequired; - } - - $properties['webCommitSignoffRequired'] = $value; - - after_webCommitSignoffRequired: - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo', $exception, stack: $this->hydrationStack); - } - - if (count($missingFields) > 0) { - throw UnableToHydrateObject::dueToMissingFields(\ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo::class, $missingFields, stack: $this->hydrationStack); - } - - try { - return new \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo(...$properties); - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo', $exception, stack: $this->hydrationStack); - } - } - - private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️Repo⚡️Owner(array $payload): \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo\Owner - { - $properties = []; - $missingFields = []; - try { - $value = $payload['avatar_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'avatar_url'; - goto after_avatarUrl; - } - - $properties['avatarUrl'] = $value; - - after_avatarUrl: - - $value = $payload['events_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'events_url'; - goto after_eventsUrl; - } - - $properties['eventsUrl'] = $value; - - after_eventsUrl: - - $value = $payload['followers_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'followers_url'; - goto after_followersUrl; - } - - $properties['followersUrl'] = $value; - - after_followersUrl: - - $value = $payload['following_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'following_url'; - goto after_followingUrl; - } - - $properties['followingUrl'] = $value; - - after_followingUrl: - - $value = $payload['gists_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'gists_url'; - goto after_gistsUrl; - } - - $properties['gistsUrl'] = $value; - - after_gistsUrl: - - $value = $payload['gravatar_id'] ?? null; - - if ($value === null) { - $properties['gravatarId'] = null; - goto after_gravatarId; - } - - $properties['gravatarId'] = $value; - - after_gravatarId: - - $value = $payload['html_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'html_url'; - goto after_htmlUrl; - } - - $properties['htmlUrl'] = $value; - - after_htmlUrl: - - $value = $payload['id'] ?? null; - - if ($value === null) { - $missingFields[] = 'id'; - goto after_id; - } - - $properties['id'] = $value; - - after_id: - - $value = $payload['node_id'] ?? null; - - if ($value === null) { - $missingFields[] = 'node_id'; - goto after_nodeId; - } - - $properties['nodeId'] = $value; - - after_nodeId: - - $value = $payload['login'] ?? null; - - if ($value === null) { - $missingFields[] = 'login'; - goto after_login; - } - - $properties['login'] = $value; - - after_login: - - $value = $payload['organizations_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'organizations_url'; - goto after_organizationsUrl; - } - - $properties['organizationsUrl'] = $value; - - after_organizationsUrl: - - $value = $payload['received_events_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'received_events_url'; - goto after_receivedEventsUrl; - } - - $properties['receivedEventsUrl'] = $value; - - after_receivedEventsUrl: - - $value = $payload['repos_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'repos_url'; - goto after_reposUrl; - } - - $properties['reposUrl'] = $value; - - after_reposUrl: - - $value = $payload['site_admin'] ?? null; - - if ($value === null) { - $missingFields[] = 'site_admin'; - goto after_siteAdmin; - } - - $properties['siteAdmin'] = $value; - - after_siteAdmin: - - $value = $payload['starred_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'starred_url'; - goto after_starredUrl; - } - - $properties['starredUrl'] = $value; - - after_starredUrl: - - $value = $payload['subscriptions_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'subscriptions_url'; - goto after_subscriptionsUrl; - } - - $properties['subscriptionsUrl'] = $value; - - after_subscriptionsUrl: - - $value = $payload['type'] ?? null; - - if ($value === null) { - $missingFields[] = 'type'; - goto after_type; - } - - $properties['type'] = $value; - - after_type: - - $value = $payload['url'] ?? null; - - if ($value === null) { - $missingFields[] = 'url'; - goto after_url; - } - - $properties['url'] = $value; - - after_url: - - $value = $payload['user_view_type'] ?? null; - - if ($value === null) { - $properties['userViewType'] = null; - goto after_userViewType; - } - - $properties['userViewType'] = $value; - - after_userViewType: - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo\Owner', $exception, stack: $this->hydrationStack); - } - - if (count($missingFields) > 0) { - throw UnableToHydrateObject::dueToMissingFields(\ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo\Owner::class, $missingFields, stack: $this->hydrationStack); - } - - try { - return new \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo\Owner(...$properties); - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo\Owner', $exception, stack: $this->hydrationStack); - } - } - - private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️Repo⚡️Permissions(array $payload): \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo\Permissions - { - $properties = []; - $missingFields = []; - try { - $value = $payload['admin'] ?? null; - - if ($value === null) { - $missingFields[] = 'admin'; - goto after_admin; - } - - $properties['admin'] = $value; - - after_admin: - - $value = $payload['maintain'] ?? null; - - if ($value === null) { - $properties['maintain'] = null; - goto after_maintain; - } - - $properties['maintain'] = $value; - - after_maintain: - - $value = $payload['push'] ?? null; - - if ($value === null) { - $missingFields[] = 'push'; - goto after_push; - } - - $properties['push'] = $value; - - after_push: - - $value = $payload['triage'] ?? null; - - if ($value === null) { - $properties['triage'] = null; - goto after_triage; - } - - $properties['triage'] = $value; - - after_triage: - - $value = $payload['pull'] ?? null; - - if ($value === null) { - $missingFields[] = 'pull'; - goto after_pull; - } - - $properties['pull'] = $value; - - after_pull: - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo\Permissions', $exception, stack: $this->hydrationStack); - } - - if (count($missingFields) > 0) { - throw UnableToHydrateObject::dueToMissingFields(\ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo\Permissions::class, $missingFields, stack: $this->hydrationStack); - } - - try { - return new \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo\Permissions(...$properties); - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo\Permissions', $exception, stack: $this->hydrationStack); - } - } - - private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️LicenseSimple(array $payload): LicenseSimple - { - $properties = []; - $missingFields = []; - try { - $value = $payload['key'] ?? null; - - if ($value === null) { - $missingFields[] = 'key'; - goto after_key; - } - - $properties['key'] = $value; - - after_key: - - $value = $payload['name'] ?? null; - - if ($value === null) { - $missingFields[] = 'name'; - goto after_name; - } - - $properties['name'] = $value; - - after_name: - - $value = $payload['url'] ?? null; - - if ($value === null) { - $properties['url'] = null; - goto after_url; - } - - $properties['url'] = $value; - - after_url: - - $value = $payload['spdx_id'] ?? null; - - if ($value === null) { - $properties['spdxId'] = null; - goto after_spdxId; - } - - $properties['spdxId'] = $value; - - after_spdxId: - - $value = $payload['node_id'] ?? null; - - if ($value === null) { - $missingFields[] = 'node_id'; - goto after_nodeId; - } - - $properties['nodeId'] = $value; - - after_nodeId: - - $value = $payload['html_url'] ?? null; - - if ($value === null) { - $properties['htmlUrl'] = null; - goto after_htmlUrl; - } - - $properties['htmlUrl'] = $value; - - after_htmlUrl: - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\LicenseSimple', $exception, stack: $this->hydrationStack); - } - - if (count($missingFields) > 0) { - throw UnableToHydrateObject::dueToMissingFields(LicenseSimple::class, $missingFields, stack: $this->hydrationStack); - } - - try { - return new LicenseSimple(...$properties); - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\LicenseSimple', $exception, stack: $this->hydrationStack); - } - } - - private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️User(array $payload): \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\User - { - $properties = []; - $missingFields = []; - try { - $value = $payload['avatar_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'avatar_url'; - goto after_avatarUrl; - } - - $properties['avatarUrl'] = $value; - - after_avatarUrl: - - $value = $payload['events_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'events_url'; - goto after_eventsUrl; - } - - $properties['eventsUrl'] = $value; - - after_eventsUrl: - - $value = $payload['followers_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'followers_url'; - goto after_followersUrl; - } - - $properties['followersUrl'] = $value; - - after_followersUrl: - - $value = $payload['following_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'following_url'; - goto after_followingUrl; - } - - $properties['followingUrl'] = $value; - - after_followingUrl: - - $value = $payload['gists_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'gists_url'; - goto after_gistsUrl; - } - - $properties['gistsUrl'] = $value; - - after_gistsUrl: - - $value = $payload['gravatar_id'] ?? null; - - if ($value === null) { - $properties['gravatarId'] = null; - goto after_gravatarId; - } - - $properties['gravatarId'] = $value; - - after_gravatarId: - - $value = $payload['html_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'html_url'; - goto after_htmlUrl; - } - - $properties['htmlUrl'] = $value; - - after_htmlUrl: - - $value = $payload['id'] ?? null; - - if ($value === null) { - $missingFields[] = 'id'; - goto after_id; - } - - $properties['id'] = $value; - - after_id: - - $value = $payload['node_id'] ?? null; - - if ($value === null) { - $missingFields[] = 'node_id'; - goto after_nodeId; - } - - $properties['nodeId'] = $value; - - after_nodeId: - - $value = $payload['login'] ?? null; - - if ($value === null) { - $missingFields[] = 'login'; - goto after_login; - } - - $properties['login'] = $value; - - after_login: - - $value = $payload['organizations_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'organizations_url'; - goto after_organizationsUrl; - } - - $properties['organizationsUrl'] = $value; - - after_organizationsUrl: - - $value = $payload['received_events_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'received_events_url'; - goto after_receivedEventsUrl; - } - - $properties['receivedEventsUrl'] = $value; - - after_receivedEventsUrl: - - $value = $payload['repos_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'repos_url'; - goto after_reposUrl; - } - - $properties['reposUrl'] = $value; - - after_reposUrl: - - $value = $payload['site_admin'] ?? null; - - if ($value === null) { - $missingFields[] = 'site_admin'; - goto after_siteAdmin; - } - - $properties['siteAdmin'] = $value; - - after_siteAdmin: - - $value = $payload['starred_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'starred_url'; - goto after_starredUrl; - } - - $properties['starredUrl'] = $value; - - after_starredUrl: - - $value = $payload['subscriptions_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'subscriptions_url'; - goto after_subscriptionsUrl; - } - - $properties['subscriptionsUrl'] = $value; - - after_subscriptionsUrl: - - $value = $payload['type'] ?? null; - - if ($value === null) { - $missingFields[] = 'type'; - goto after_type; - } - - $properties['type'] = $value; - - after_type: - - $value = $payload['url'] ?? null; - - if ($value === null) { - $missingFields[] = 'url'; - goto after_url; - } - - $properties['url'] = $value; - - after_url: - - $value = $payload['user_view_type'] ?? null; - - if ($value === null) { - $properties['userViewType'] = null; - goto after_userViewType; - } - - $properties['userViewType'] = $value; - - after_userViewType: - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\User', $exception, stack: $this->hydrationStack); - } - - if (count($missingFields) > 0) { - throw UnableToHydrateObject::dueToMissingFields(\ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\User::class, $missingFields, stack: $this->hydrationStack); - } - - try { - return new \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\User(...$properties); - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\User', $exception, stack: $this->hydrationStack); - } - } - - private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Links(array $payload): Links - { - $properties = []; - $missingFields = []; - try { - $value = $payload['comments'] ?? null; - - if ($value === null) { - $missingFields[] = 'comments'; - goto after_comments; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'comments'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Link($value); - } finally { - array_pop($this->hydrationStack); - } - } - - $properties['comments'] = $value; - - after_comments: - - $value = $payload['commits'] ?? null; - - if ($value === null) { - $missingFields[] = 'commits'; - goto after_commits; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'commits'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Link($value); - } finally { - array_pop($this->hydrationStack); - } - } - - $properties['commits'] = $value; - - after_commits: - - $value = $payload['statuses'] ?? null; - - if ($value === null) { - $missingFields[] = 'statuses'; - goto after_statuses; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'statuses'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Link($value); - } finally { - array_pop($this->hydrationStack); - } - } - - $properties['statuses'] = $value; - - after_statuses: - - $value = $payload['html'] ?? null; - - if ($value === null) { - $missingFields[] = 'html'; - goto after_html; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'html'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Link($value); - } finally { - array_pop($this->hydrationStack); - } - } - - $properties['html'] = $value; - - after_html: - - $value = $payload['issue'] ?? null; - - if ($value === null) { - $missingFields[] = 'issue'; - goto after_issue; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'issue'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Link($value); - } finally { - array_pop($this->hydrationStack); - } - } - - $properties['issue'] = $value; - - after_issue: - - $value = $payload['review_comments'] ?? null; - - if ($value === null) { - $missingFields[] = 'review_comments'; - goto after_reviewComments; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'reviewComments'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Link($value); - } finally { - array_pop($this->hydrationStack); - } - } - - $properties['reviewComments'] = $value; - - after_reviewComments: - - $value = $payload['review_comment'] ?? null; - - if ($value === null) { - $missingFields[] = 'review_comment'; - goto after_reviewComment; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'reviewComment'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Link($value); - } finally { - array_pop($this->hydrationStack); - } - } - - $properties['reviewComment'] = $value; - - after_reviewComment: - - $value = $payload['self'] ?? null; - - if ($value === null) { - $missingFields[] = 'self'; - goto after_self; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'self'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Link($value); - } finally { - array_pop($this->hydrationStack); - } - } - - $properties['self'] = $value; - - after_self: - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Links', $exception, stack: $this->hydrationStack); - } - - if (count($missingFields) > 0) { - throw UnableToHydrateObject::dueToMissingFields(Links::class, $missingFields, stack: $this->hydrationStack); - } - - try { - return new Links(...$properties); - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Links', $exception, stack: $this->hydrationStack); - } - } - - private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Link(array $payload): Link - { - $properties = []; - $missingFields = []; - try { - $value = $payload['href'] ?? null; - - if ($value === null) { - $missingFields[] = 'href'; - goto after_href; - } - - $properties['href'] = $value; - - after_href: - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\Link', $exception, stack: $this->hydrationStack); - } - - if (count($missingFields) > 0) { - throw UnableToHydrateObject::dueToMissingFields(Link::class, $missingFields, stack: $this->hydrationStack); - } - - try { - return new Link(...$properties); - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\Link', $exception, stack: $this->hydrationStack); - } - } - - private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️AutoMerge(array $payload): AutoMerge - { - $properties = []; - $missingFields = []; - try { - $value = $payload['enabled_by'] ?? null; - - if ($value === null) { - $missingFields[] = 'enabled_by'; - goto after_enabledBy; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'enabledBy'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleUser($value); - } finally { - array_pop($this->hydrationStack); - } - } - - $properties['enabledBy'] = $value; - - after_enabledBy: - - $value = $payload['merge_method'] ?? null; - - if ($value === null) { - $missingFields[] = 'merge_method'; - goto after_mergeMethod; - } - - $properties['mergeMethod'] = $value; - - after_mergeMethod: - - $value = $payload['commit_title'] ?? null; - - if ($value === null) { - $missingFields[] = 'commit_title'; - goto after_commitTitle; - } - - $properties['commitTitle'] = $value; - - after_commitTitle: - - $value = $payload['commit_message'] ?? null; - - if ($value === null) { - $missingFields[] = 'commit_message'; - goto after_commitMessage; - } - - $properties['commitMessage'] = $value; - - after_commitMessage: - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\AutoMerge', $exception, stack: $this->hydrationStack); - } - - if (count($missingFields) > 0) { - throw UnableToHydrateObject::dueToMissingFields(AutoMerge::class, $missingFields, stack: $this->hydrationStack); - } - - try { - return new AutoMerge(...$properties); - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\AutoMerge', $exception, stack: $this->hydrationStack); - } - } - - private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️BasicError(array $payload): BasicError - { - $properties = []; - $missingFields = []; - try { - $value = $payload['message'] ?? null; - - if ($value === null) { - $properties['message'] = null; - goto after_message; - } - - $properties['message'] = $value; - - after_message: - - $value = $payload['documentation_url'] ?? null; - - if ($value === null) { - $properties['documentationUrl'] = null; - goto after_documentationUrl; - } - - $properties['documentationUrl'] = $value; - - after_documentationUrl: - - $value = $payload['url'] ?? null; - - if ($value === null) { - $properties['url'] = null; - goto after_url; - } - - $properties['url'] = $value; - - after_url: - - $value = $payload['status'] ?? null; - - if ($value === null) { - $properties['status'] = null; - goto after_status; - } - - $properties['status'] = $value; - - after_status: - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\BasicError', $exception, stack: $this->hydrationStack); - } - - if (count($missingFields) > 0) { - throw UnableToHydrateObject::dueToMissingFields(BasicError::class, $missingFields, stack: $this->hydrationStack); - } - - try { - return new BasicError(...$properties); - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\BasicError', $exception, stack: $this->hydrationStack); - } - } - - private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Operations⚡️CodeScanning⚡️ListAlertsForEnterprise⚡️Response⚡️ApplicationJson⚡️ServiceUnavailable(array $payload): ServiceUnavailable - { - $properties = []; - $missingFields = []; - try { - $value = $payload['code'] ?? null; - - if ($value === null) { - $properties['code'] = null; - goto after_code; - } - - $properties['code'] = $value; - - after_code: - - $value = $payload['message'] ?? null; - - if ($value === null) { - $properties['message'] = null; - goto after_message; - } - - $properties['message'] = $value; - - after_message: - - $value = $payload['documentation_url'] ?? null; - - if ($value === null) { - $properties['documentationUrl'] = null; - goto after_documentationUrl; - } - - $properties['documentationUrl'] = $value; - - after_documentationUrl: - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\Operations\CodeScanning\ListAlertsForEnterprise\Response\ApplicationJson\ServiceUnavailable', $exception, stack: $this->hydrationStack); - } - - if (count($missingFields) > 0) { - throw UnableToHydrateObject::dueToMissingFields(ServiceUnavailable::class, $missingFields, stack: $this->hydrationStack); - } - - try { - return new ServiceUnavailable(...$properties); - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\Operations\CodeScanning\ListAlertsForEnterprise\Response\ApplicationJson\ServiceUnavailable', $exception, stack: $this->hydrationStack); - } - } - - private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️ValidationError(array $payload): ValidationError - { - $properties = []; - $missingFields = []; - try { - $value = $payload['message'] ?? null; - - if ($value === null) { - $missingFields[] = 'message'; - goto after_message; - } - - $properties['message'] = $value; - - after_message: - - $value = $payload['documentation_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'documentation_url'; - goto after_documentationUrl; - } - - $properties['documentationUrl'] = $value; - - after_documentationUrl: - - $value = $payload['errors'] ?? null; - - if ($value === null) { - $properties['errors'] = null; - goto after_errors; - } - - $properties['errors'] = $value; - - after_errors: - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\ValidationError', $exception, stack: $this->hydrationStack); - } - - if (count($missingFields) > 0) { - throw UnableToHydrateObject::dueToMissingFields(ValidationError::class, $missingFields, stack: $this->hydrationStack); - } - - try { - return new ValidationError(...$properties); - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\ValidationError', $exception, stack: $this->hydrationStack); - } - } - - private function serializeViaTypeMap(string $accessor, object $object, array $payloadToTypeMap): array - { - foreach ($payloadToTypeMap as $payloadType => [$valueType, $method]) { - if (is_a($object, $valueType)) { - return [$accessor => $payloadType] + $this->{$method}($object); - } - } - - throw new LogicException('No type mapped for object of class: ' . $object::class); - } - - public function serializeObject(object $object): mixed - { - return $this->serializeObjectOfType($object, $object::class); - } - - /** - * @param T $object - * @param class-string $className - * - * @template T - */ - public function serializeObjectOfType(object $object, string $className): mixed - { - try { - return match ($className) { - 'array' => $this->serializeValuearray($object), - 'Ramsey\Uuid\UuidInterface' => $this->serializeValueRamsey⚡️Uuid⚡️UuidInterface($object), - 'DateTime' => $this->serializeValueDateTime($object), - 'DateTimeImmutable' => $this->serializeValueDateTimeImmutable($object), - 'DateTimeInterface' => $this->serializeValueDateTimeInterface($object), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest($object), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\SimpleUser' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleUser($object), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\Milestone' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Milestone($object), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head($object), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo($object), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo\Owner' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo⚡️Owner($object), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo\Permissions' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo⚡️Permissions($object), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo\License' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo⚡️License($object), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\User' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️User($object), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base($object), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️Repo($object), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo\Owner' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️Repo⚡️Owner($object), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo\Permissions' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️Repo⚡️Permissions($object), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\LicenseSimple' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️LicenseSimple($object), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\User' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️User($object), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Links' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Links($object), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\Link' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Link($object), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\AutoMerge' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️AutoMerge($object), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\BasicError' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️BasicError($object), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\Operations\CodeScanning\ListAlertsForEnterprise\Response\ApplicationJson\ServiceUnavailable' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Operations⚡️CodeScanning⚡️ListAlertsForEnterprise⚡️Response⚡️ApplicationJson⚡️ServiceUnavailable($object), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\ValidationError' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️ValidationError($object), - default => throw new LogicException("No serialization defined for $className"), - }; - } catch (Throwable $exception) { - throw UnableToSerializeObject::dueToError($className, $exception); - } - } - - private function serializeValuearray(mixed $value): mixed - { - static $serializer; - - if ($serializer === null) { - $serializer = new SerializeArrayItems(...[]); - } - - return $serializer->serialize($value, $this); - } - - private function serializeValueRamsey⚡️Uuid⚡️UuidInterface(mixed $value): mixed - { - static $serializer; - - if ($serializer === null) { - $serializer = new SerializeUuidToString(...[]); - } - - return $serializer->serialize($value, $this); - } - - private function serializeValueDateTime(mixed $value): mixed - { - static $serializer; - - if ($serializer === null) { - $serializer = new SerializeDateTime(...[]); - } - - return $serializer->serialize($value, $this); - } - - private function serializeValueDateTimeImmutable(mixed $value): mixed - { - static $serializer; - - if ($serializer === null) { - $serializer = new SerializeDateTime(...[]); - } - - return $serializer->serialize($value, $this); - } - - private function serializeValueDateTimeInterface(mixed $value): mixed - { - static $serializer; - - if ($serializer === null) { - $serializer = new SerializeDateTime(...[]); - } - - return $serializer->serialize($value, $this); - } - - private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest(mixed $object): mixed - { - assert($object instanceof PullRequest); - $result = []; - - $url = $object->url; - after_url: $result['url'] = $url; - - $id = $object->id; - after_id: $result['id'] = $id; - - $nodeId = $object->nodeId; - after_nodeId: $result['node_id'] = $nodeId; - - $htmlUrl = $object->htmlUrl; - after_htmlUrl: $result['html_url'] = $htmlUrl; - - $diffUrl = $object->diffUrl; - after_diffUrl: $result['diff_url'] = $diffUrl; - - $patchUrl = $object->patchUrl; - after_patchUrl: $result['patch_url'] = $patchUrl; - - $issueUrl = $object->issueUrl; - after_issueUrl: $result['issue_url'] = $issueUrl; - - $commitsUrl = $object->commitsUrl; - after_commitsUrl: $result['commits_url'] = $commitsUrl; - - $reviewCommentsUrl = $object->reviewCommentsUrl; - after_reviewCommentsUrl: $result['review_comments_url'] = $reviewCommentsUrl; - - $reviewCommentUrl = $object->reviewCommentUrl; - after_reviewCommentUrl: $result['review_comment_url'] = $reviewCommentUrl; - - $commentsUrl = $object->commentsUrl; - after_commentsUrl: $result['comments_url'] = $commentsUrl; - - $statusesUrl = $object->statusesUrl; - after_statusesUrl: $result['statuses_url'] = $statusesUrl; - - $number = $object->number; - after_number: $result['number'] = $number; - - $state = $object->state; - after_state: $result['state'] = $state; - - $locked = $object->locked; - after_locked: $result['locked'] = $locked; - - $title = $object->title; - after_title: $result['title'] = $title; - - $user = $object->user; - $user = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleUser($user); - after_user: $result['user'] = $user; - - $body = $object->body; - - if ($body === null) { - goto after_body; - } - - after_body: $result['body'] = $body; - - $labels = $object->labels; - static $labelsSerializer0; - - if ($labelsSerializer0 === null) { - $labelsSerializer0 = new SerializeArrayItems(...[]); - } - - $labels = $labelsSerializer0->serialize($labels, $this); - after_labels: $result['labels'] = $labels; - - $milestone = $object->milestone; - - if ($milestone === null) { - goto after_milestone; - } - - $milestone = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Milestone($milestone); - after_milestone: $result['milestone'] = $milestone; - - $activeLockReason = $object->activeLockReason; - - if ($activeLockReason === null) { - goto after_activeLockReason; - } - - after_activeLockReason: $result['active_lock_reason'] = $activeLockReason; - - $createdAt = $object->createdAt; - after_createdAt: $result['created_at'] = $createdAt; - - $updatedAt = $object->updatedAt; - after_updatedAt: $result['updated_at'] = $updatedAt; - - $closedAt = $object->closedAt; - - if ($closedAt === null) { - goto after_closedAt; - } - - after_closedAt: $result['closed_at'] = $closedAt; - - $mergedAt = $object->mergedAt; - - if ($mergedAt === null) { - goto after_mergedAt; - } - - after_mergedAt: $result['merged_at'] = $mergedAt; - - $mergeCommitSha = $object->mergeCommitSha; - - if ($mergeCommitSha === null) { - goto after_mergeCommitSha; - } - - after_mergeCommitSha: $result['merge_commit_sha'] = $mergeCommitSha; - - $assignee = $object->assignee; - - if ($assignee === null) { - goto after_assignee; - } - - $assignee = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleUser($assignee); - after_assignee: $result['assignee'] = $assignee; - - $assignees = $object->assignees; - - if ($assignees === null) { - goto after_assignees; - } - - static $assigneesSerializer0; - - if ($assigneesSerializer0 === null) { - $assigneesSerializer0 = new SerializeArrayItems(...[]); - } - - $assignees = $assigneesSerializer0->serialize($assignees, $this); - after_assignees: $result['assignees'] = $assignees; - - $requestedReviewers = $object->requestedReviewers; - - if ($requestedReviewers === null) { - goto after_requestedReviewers; - } - - static $requestedReviewersSerializer0; - - if ($requestedReviewersSerializer0 === null) { - $requestedReviewersSerializer0 = new SerializeArrayItems(...[]); - } - - $requestedReviewers = $requestedReviewersSerializer0->serialize($requestedReviewers, $this); - after_requestedReviewers: $result['requested_reviewers'] = $requestedReviewers; - - $requestedTeams = $object->requestedTeams; - - if ($requestedTeams === null) { - goto after_requestedTeams; - } - - static $requestedTeamsSerializer0; - - if ($requestedTeamsSerializer0 === null) { - $requestedTeamsSerializer0 = new SerializeArrayItems(...[]); - } - - $requestedTeams = $requestedTeamsSerializer0->serialize($requestedTeams, $this); - after_requestedTeams: $result['requested_teams'] = $requestedTeams; - - $head = $object->head; - $head = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head($head); - after_head: $result['head'] = $head; - - $base = $object->base; - $base = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base($base); - after_base: $result['base'] = $base; - - $links = $object->links; - $links = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Links($links); - after_links: $result['_links'] = $links; - - $authorAssociation = $object->authorAssociation; - after_authorAssociation: $result['author_association'] = $authorAssociation; - - $autoMerge = $object->autoMerge; - - if ($autoMerge === null) { - goto after_autoMerge; - } - - $autoMerge = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️AutoMerge($autoMerge); - after_autoMerge: $result['auto_merge'] = $autoMerge; - - $draft = $object->draft; - - if ($draft === null) { - goto after_draft; - } - - after_draft: $result['draft'] = $draft; - - $merged = $object->merged; - after_merged: $result['merged'] = $merged; - - $mergeable = $object->mergeable; - - if ($mergeable === null) { - goto after_mergeable; - } - - after_mergeable: $result['mergeable'] = $mergeable; - - $rebaseable = $object->rebaseable; - - if ($rebaseable === null) { - goto after_rebaseable; - } - - after_rebaseable: $result['rebaseable'] = $rebaseable; - - $mergeableState = $object->mergeableState; - after_mergeableState: $result['mergeable_state'] = $mergeableState; - - $mergedBy = $object->mergedBy; - - if ($mergedBy === null) { - goto after_mergedBy; - } - - $mergedBy = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleUser($mergedBy); - after_mergedBy: $result['merged_by'] = $mergedBy; - - $comments = $object->comments; - after_comments: $result['comments'] = $comments; - - $reviewComments = $object->reviewComments; - after_reviewComments: $result['review_comments'] = $reviewComments; - - $maintainerCanModify = $object->maintainerCanModify; - after_maintainerCanModify: $result['maintainer_can_modify'] = $maintainerCanModify; - - $commits = $object->commits; - after_commits: $result['commits'] = $commits; - - $additions = $object->additions; - after_additions: $result['additions'] = $additions; - - $deletions = $object->deletions; - after_deletions: $result['deletions'] = $deletions; - - $changedFiles = $object->changedFiles; - after_changedFiles: $result['changed_files'] = $changedFiles; - - return $result; - } - - private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleUser(mixed $object): mixed - { - assert($object instanceof SimpleUser); - $result = []; - - $name = $object->name; - - if ($name === null) { - goto after_name; - } - - after_name: $result['name'] = $name; - - $email = $object->email; - - if ($email === null) { - goto after_email; - } - - after_email: $result['email'] = $email; - - $login = $object->login; - after_login: $result['login'] = $login; - - $id = $object->id; - after_id: $result['id'] = $id; - - $nodeId = $object->nodeId; - after_nodeId: $result['node_id'] = $nodeId; - - $avatarUrl = $object->avatarUrl; - after_avatarUrl: $result['avatar_url'] = $avatarUrl; - - $gravatarId = $object->gravatarId; - - if ($gravatarId === null) { - goto after_gravatarId; - } - - after_gravatarId: $result['gravatar_id'] = $gravatarId; - - $url = $object->url; - after_url: $result['url'] = $url; - - $htmlUrl = $object->htmlUrl; - after_htmlUrl: $result['html_url'] = $htmlUrl; - - $followersUrl = $object->followersUrl; - after_followersUrl: $result['followers_url'] = $followersUrl; - - $followingUrl = $object->followingUrl; - after_followingUrl: $result['following_url'] = $followingUrl; - - $gistsUrl = $object->gistsUrl; - after_gistsUrl: $result['gists_url'] = $gistsUrl; - - $starredUrl = $object->starredUrl; - after_starredUrl: $result['starred_url'] = $starredUrl; - - $subscriptionsUrl = $object->subscriptionsUrl; - after_subscriptionsUrl: $result['subscriptions_url'] = $subscriptionsUrl; - - $organizationsUrl = $object->organizationsUrl; - after_organizationsUrl: $result['organizations_url'] = $organizationsUrl; - - $reposUrl = $object->reposUrl; - after_reposUrl: $result['repos_url'] = $reposUrl; - - $eventsUrl = $object->eventsUrl; - after_eventsUrl: $result['events_url'] = $eventsUrl; - - $receivedEventsUrl = $object->receivedEventsUrl; - after_receivedEventsUrl: $result['received_events_url'] = $receivedEventsUrl; - - $type = $object->type; - after_type: $result['type'] = $type; - - $siteAdmin = $object->siteAdmin; - after_siteAdmin: $result['site_admin'] = $siteAdmin; - - $starredAt = $object->starredAt; - - if ($starredAt === null) { - goto after_starredAt; - } - - after_starredAt: $result['starred_at'] = $starredAt; - - $userViewType = $object->userViewType; - - if ($userViewType === null) { - goto after_userViewType; - } - - after_userViewType: $result['user_view_type'] = $userViewType; - - return $result; - } - - private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Milestone(mixed $object): mixed - { - assert($object instanceof Milestone); - $result = []; - - $url = $object->url; - after_url: $result['url'] = $url; - - $htmlUrl = $object->htmlUrl; - after_htmlUrl: $result['html_url'] = $htmlUrl; - - $labelsUrl = $object->labelsUrl; - after_labelsUrl: $result['labels_url'] = $labelsUrl; - - $id = $object->id; - after_id: $result['id'] = $id; - - $nodeId = $object->nodeId; - after_nodeId: $result['node_id'] = $nodeId; - - $number = $object->number; - after_number: $result['number'] = $number; - - $state = $object->state; - after_state: $result['state'] = $state; - - $title = $object->title; - after_title: $result['title'] = $title; - - $description = $object->description; - - if ($description === null) { - goto after_description; - } - - after_description: $result['description'] = $description; - - $creator = $object->creator; - - if ($creator === null) { - goto after_creator; - } - - $creator = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleUser($creator); - after_creator: $result['creator'] = $creator; - - $openIssues = $object->openIssues; - after_openIssues: $result['open_issues'] = $openIssues; - - $closedIssues = $object->closedIssues; - after_closedIssues: $result['closed_issues'] = $closedIssues; - - $createdAt = $object->createdAt; - after_createdAt: $result['created_at'] = $createdAt; - - $updatedAt = $object->updatedAt; - after_updatedAt: $result['updated_at'] = $updatedAt; - - $closedAt = $object->closedAt; - - if ($closedAt === null) { - goto after_closedAt; - } - - after_closedAt: $result['closed_at'] = $closedAt; - - $dueOn = $object->dueOn; - - if ($dueOn === null) { - goto after_dueOn; - } - - after_dueOn: $result['due_on'] = $dueOn; - - return $result; - } - - private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head(mixed $object): mixed - { - assert($object instanceof Head); - $result = []; - - $label = $object->label; - after_label: $result['label'] = $label; - - $ref = $object->ref; - after_ref: $result['ref'] = $ref; - - $repo = $object->repo; - - if ($repo === null) { - goto after_repo; - } - - $repo = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo($repo); - after_repo: $result['repo'] = $repo; - - $sha = $object->sha; - after_sha: $result['sha'] = $sha; - - $user = $object->user; - $user = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️User($user); - after_user: $result['user'] = $user; - - return $result; + return $serializer->serialize($value, $this); } - private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo(mixed $object): mixed - { - assert($object instanceof Repo); - $result = []; - - $archiveUrl = $object->archiveUrl; - after_archiveUrl: $result['archive_url'] = $archiveUrl; - - $assigneesUrl = $object->assigneesUrl; - after_assigneesUrl: $result['assignees_url'] = $assigneesUrl; - - $blobsUrl = $object->blobsUrl; - after_blobsUrl: $result['blobs_url'] = $blobsUrl; - - $branchesUrl = $object->branchesUrl; - after_branchesUrl: $result['branches_url'] = $branchesUrl; - - $collaboratorsUrl = $object->collaboratorsUrl; - after_collaboratorsUrl: $result['collaborators_url'] = $collaboratorsUrl; - - $commentsUrl = $object->commentsUrl; - after_commentsUrl: $result['comments_url'] = $commentsUrl; - - $commitsUrl = $object->commitsUrl; - after_commitsUrl: $result['commits_url'] = $commitsUrl; - - $compareUrl = $object->compareUrl; - after_compareUrl: $result['compare_url'] = $compareUrl; - - $contentsUrl = $object->contentsUrl; - after_contentsUrl: $result['contents_url'] = $contentsUrl; - - $contributorsUrl = $object->contributorsUrl; - after_contributorsUrl: $result['contributors_url'] = $contributorsUrl; - - $deploymentsUrl = $object->deploymentsUrl; - after_deploymentsUrl: $result['deployments_url'] = $deploymentsUrl; - - $description = $object->description; - - if ($description === null) { - goto after_description; - } - - after_description: $result['description'] = $description; - - $downloadsUrl = $object->downloadsUrl; - after_downloadsUrl: $result['downloads_url'] = $downloadsUrl; - - $eventsUrl = $object->eventsUrl; - after_eventsUrl: $result['events_url'] = $eventsUrl; - - $fork = $object->fork; - after_fork: $result['fork'] = $fork; - - $forksUrl = $object->forksUrl; - after_forksUrl: $result['forks_url'] = $forksUrl; - - $fullName = $object->fullName; - after_fullName: $result['full_name'] = $fullName; - - $gitCommitsUrl = $object->gitCommitsUrl; - after_gitCommitsUrl: $result['git_commits_url'] = $gitCommitsUrl; - - $gitRefsUrl = $object->gitRefsUrl; - after_gitRefsUrl: $result['git_refs_url'] = $gitRefsUrl; - - $gitTagsUrl = $object->gitTagsUrl; - after_gitTagsUrl: $result['git_tags_url'] = $gitTagsUrl; - - $hooksUrl = $object->hooksUrl; - after_hooksUrl: $result['hooks_url'] = $hooksUrl; + private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest(mixed $object): mixed + { + assert($object instanceof PullRequest); + $result = []; - $htmlUrl = $object->htmlUrl; - after_htmlUrl: $result['html_url'] = $htmlUrl; + $url = $object->url; + after_url: $result['url'] = $url; $id = $object->id; after_id: $result['id'] = $id; @@ -5643,296 +3158,287 @@ private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseClou $nodeId = $object->nodeId; after_nodeId: $result['node_id'] = $nodeId; - $issueCommentUrl = $object->issueCommentUrl; - after_issueCommentUrl: $result['issue_comment_url'] = $issueCommentUrl; - - $issueEventsUrl = $object->issueEventsUrl; - after_issueEventsUrl: $result['issue_events_url'] = $issueEventsUrl; - - $issuesUrl = $object->issuesUrl; - after_issuesUrl: $result['issues_url'] = $issuesUrl; - - $keysUrl = $object->keysUrl; - after_keysUrl: $result['keys_url'] = $keysUrl; - - $labelsUrl = $object->labelsUrl; - after_labelsUrl: $result['labels_url'] = $labelsUrl; - - $languagesUrl = $object->languagesUrl; - after_languagesUrl: $result['languages_url'] = $languagesUrl; - - $mergesUrl = $object->mergesUrl; - after_mergesUrl: $result['merges_url'] = $mergesUrl; - - $milestonesUrl = $object->milestonesUrl; - after_milestonesUrl: $result['milestones_url'] = $milestonesUrl; + $htmlUrl = $object->htmlUrl; + after_htmlUrl: $result['html_url'] = $htmlUrl; - $name = $object->name; - after_name: $result['name'] = $name; + $diffUrl = $object->diffUrl; + after_diffUrl: $result['diff_url'] = $diffUrl; - $notificationsUrl = $object->notificationsUrl; - after_notificationsUrl: $result['notifications_url'] = $notificationsUrl; + $patchUrl = $object->patchUrl; + after_patchUrl: $result['patch_url'] = $patchUrl; - $owner = $object->owner; - $owner = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo⚡️Owner($owner); - after_owner: $result['owner'] = $owner; + $issueUrl = $object->issueUrl; + after_issueUrl: $result['issue_url'] = $issueUrl; - $private = $object->private; - after_private: $result['private'] = $private; + $commitsUrl = $object->commitsUrl; + after_commitsUrl: $result['commits_url'] = $commitsUrl; - $pullsUrl = $object->pullsUrl; - after_pullsUrl: $result['pulls_url'] = $pullsUrl; + $reviewCommentsUrl = $object->reviewCommentsUrl; + after_reviewCommentsUrl: $result['review_comments_url'] = $reviewCommentsUrl; - $releasesUrl = $object->releasesUrl; - after_releasesUrl: $result['releases_url'] = $releasesUrl; + $reviewCommentUrl = $object->reviewCommentUrl; + after_reviewCommentUrl: $result['review_comment_url'] = $reviewCommentUrl; - $stargazersUrl = $object->stargazersUrl; - after_stargazersUrl: $result['stargazers_url'] = $stargazersUrl; + $commentsUrl = $object->commentsUrl; + after_commentsUrl: $result['comments_url'] = $commentsUrl; $statusesUrl = $object->statusesUrl; after_statusesUrl: $result['statuses_url'] = $statusesUrl; - $subscribersUrl = $object->subscribersUrl; - after_subscribersUrl: $result['subscribers_url'] = $subscribersUrl; - - $subscriptionUrl = $object->subscriptionUrl; - after_subscriptionUrl: $result['subscription_url'] = $subscriptionUrl; + $number = $object->number; + after_number: $result['number'] = $number; - $tagsUrl = $object->tagsUrl; - after_tagsUrl: $result['tags_url'] = $tagsUrl; + $state = $object->state; + after_state: $result['state'] = $state; - $teamsUrl = $object->teamsUrl; - after_teamsUrl: $result['teams_url'] = $teamsUrl; + $locked = $object->locked; + after_locked: $result['locked'] = $locked; - $treesUrl = $object->treesUrl; - after_treesUrl: $result['trees_url'] = $treesUrl; + $title = $object->title; + after_title: $result['title'] = $title; - $url = $object->url; - after_url: $result['url'] = $url; + $user = $object->user; + $user = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleUser($user); + after_user: $result['user'] = $user; - $cloneUrl = $object->cloneUrl; - after_cloneUrl: $result['clone_url'] = $cloneUrl; + $body = $object->body; - $defaultBranch = $object->defaultBranch; - after_defaultBranch: $result['default_branch'] = $defaultBranch; + if ($body === null) { + goto after_body; + } - $forks = $object->forks; - after_forks: $result['forks'] = $forks; + after_body: $result['body'] = $body; - $forksCount = $object->forksCount; - after_forksCount: $result['forks_count'] = $forksCount; + $labels = $object->labels; + static $labelsSerializer0; - $gitUrl = $object->gitUrl; - after_gitUrl: $result['git_url'] = $gitUrl; + if ($labelsSerializer0 === null) { + $labelsSerializer0 = new SerializeArrayItems(...[]); + } - $hasDownloads = $object->hasDownloads; - after_hasDownloads: $result['has_downloads'] = $hasDownloads; + $labels = $labelsSerializer0->serialize($labels, $this); + after_labels: $result['labels'] = $labels; - $hasIssues = $object->hasIssues; - after_hasIssues: $result['has_issues'] = $hasIssues; + $milestone = $object->milestone; - $hasProjects = $object->hasProjects; - after_hasProjects: $result['has_projects'] = $hasProjects; + if ($milestone === null) { + goto after_milestone; + } - $hasWiki = $object->hasWiki; - after_hasWiki: $result['has_wiki'] = $hasWiki; + $milestone = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Milestone($milestone); + after_milestone: $result['milestone'] = $milestone; - $hasPages = $object->hasPages; - after_hasPages: $result['has_pages'] = $hasPages; + $activeLockReason = $object->activeLockReason; - $hasDiscussions = $object->hasDiscussions; - after_hasDiscussions: $result['has_discussions'] = $hasDiscussions; + if ($activeLockReason === null) { + goto after_activeLockReason; + } - $homepage = $object->homepage; + after_activeLockReason: $result['active_lock_reason'] = $activeLockReason; - if ($homepage === null) { - goto after_homepage; - } + $createdAt = $object->createdAt; + after_createdAt: $result['created_at'] = $createdAt; - after_homepage: $result['homepage'] = $homepage; + $updatedAt = $object->updatedAt; + after_updatedAt: $result['updated_at'] = $updatedAt; - $language = $object->language; + $closedAt = $object->closedAt; - if ($language === null) { - goto after_language; + if ($closedAt === null) { + goto after_closedAt; } - after_language: $result['language'] = $language; + after_closedAt: $result['closed_at'] = $closedAt; - $masterBranch = $object->masterBranch; + $mergedAt = $object->mergedAt; - if ($masterBranch === null) { - goto after_masterBranch; + if ($mergedAt === null) { + goto after_mergedAt; } - after_masterBranch: $result['master_branch'] = $masterBranch; - - $archived = $object->archived; - after_archived: $result['archived'] = $archived; - - $disabled = $object->disabled; - after_disabled: $result['disabled'] = $disabled; + after_mergedAt: $result['merged_at'] = $mergedAt; - $visibility = $object->visibility; + $mergeCommitSha = $object->mergeCommitSha; - if ($visibility === null) { - goto after_visibility; + if ($mergeCommitSha === null) { + goto after_mergeCommitSha; } - after_visibility: $result['visibility'] = $visibility; + after_mergeCommitSha: $result['merge_commit_sha'] = $mergeCommitSha; - $mirrorUrl = $object->mirrorUrl; + $assignee = $object->assignee; - if ($mirrorUrl === null) { - goto after_mirrorUrl; + if ($assignee === null) { + goto after_assignee; } - after_mirrorUrl: $result['mirror_url'] = $mirrorUrl; + $assignee = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleUser($assignee); + after_assignee: $result['assignee'] = $assignee; - $openIssues = $object->openIssues; - after_openIssues: $result['open_issues'] = $openIssues; + $assignees = $object->assignees; - $openIssuesCount = $object->openIssuesCount; - after_openIssuesCount: $result['open_issues_count'] = $openIssuesCount; + if ($assignees === null) { + goto after_assignees; + } - $permissions = $object->permissions; + static $assigneesSerializer0; - if ($permissions === null) { - goto after_permissions; + if ($assigneesSerializer0 === null) { + $assigneesSerializer0 = new SerializeArrayItems(...[]); } - $permissions = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo⚡️Permissions($permissions); - after_permissions: $result['permissions'] = $permissions; + $assignees = $assigneesSerializer0->serialize($assignees, $this); + after_assignees: $result['assignees'] = $assignees; - $tempCloneToken = $object->tempCloneToken; + $requestedReviewers = $object->requestedReviewers; - if ($tempCloneToken === null) { - goto after_tempCloneToken; + if ($requestedReviewers === null) { + goto after_requestedReviewers; } - after_tempCloneToken: $result['temp_clone_token'] = $tempCloneToken; - - $allowMergeCommit = $object->allowMergeCommit; + static $requestedReviewersSerializer0; - if ($allowMergeCommit === null) { - goto after_allowMergeCommit; + if ($requestedReviewersSerializer0 === null) { + $requestedReviewersSerializer0 = new SerializeArrayItems(...[]); } - after_allowMergeCommit: $result['allow_merge_commit'] = $allowMergeCommit; + $requestedReviewers = $requestedReviewersSerializer0->serialize($requestedReviewers, $this); + after_requestedReviewers: $result['requested_reviewers'] = $requestedReviewers; - $allowSquashMerge = $object->allowSquashMerge; + $requestedTeams = $object->requestedTeams; - if ($allowSquashMerge === null) { - goto after_allowSquashMerge; + if ($requestedTeams === null) { + goto after_requestedTeams; } - after_allowSquashMerge: $result['allow_squash_merge'] = $allowSquashMerge; - - $allowRebaseMerge = $object->allowRebaseMerge; + static $requestedTeamsSerializer0; - if ($allowRebaseMerge === null) { - goto after_allowRebaseMerge; + if ($requestedTeamsSerializer0 === null) { + $requestedTeamsSerializer0 = new SerializeArrayItems(...[]); } - after_allowRebaseMerge: $result['allow_rebase_merge'] = $allowRebaseMerge; - - $license = $object->license; + $requestedTeams = $requestedTeamsSerializer0->serialize($requestedTeams, $this); + after_requestedTeams: $result['requested_teams'] = $requestedTeams; - if ($license === null) { - goto after_license; - } + $head = $object->head; + $head = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head($head); + after_head: $result['head'] = $head; - $license = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo⚡️License($license); - after_license: $result['license'] = $license; + $base = $object->base; + $base = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base($base); + after_base: $result['base'] = $base; - $pushedAt = $object->pushedAt; - after_pushedAt: $result['pushed_at'] = $pushedAt; + $links = $object->links; + $links = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Links($links); + after_links: $result['_links'] = $links; - $size = $object->size; - after_size: $result['size'] = $size; + $authorAssociation = $object->authorAssociation; + after_authorAssociation: $result['author_association'] = $authorAssociation; - $sshUrl = $object->sshUrl; - after_sshUrl: $result['ssh_url'] = $sshUrl; + $autoMerge = $object->autoMerge; - $stargazersCount = $object->stargazersCount; - after_stargazersCount: $result['stargazers_count'] = $stargazersCount; + if ($autoMerge === null) { + goto after_autoMerge; + } - $svnUrl = $object->svnUrl; - after_svnUrl: $result['svn_url'] = $svnUrl; + $autoMerge = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️AutoMerge($autoMerge); + after_autoMerge: $result['auto_merge'] = $autoMerge; - $topics = $object->topics; + $draft = $object->draft; - if ($topics === null) { - goto after_topics; + if ($draft === null) { + goto after_draft; } - static $topicsSerializer0; + after_draft: $result['draft'] = $draft; - if ($topicsSerializer0 === null) { - $topicsSerializer0 = new SerializeArrayItems(...[]); + $merged = $object->merged; + after_merged: $result['merged'] = $merged; + + $mergeable = $object->mergeable; + + if ($mergeable === null) { + goto after_mergeable; } - $topics = $topicsSerializer0->serialize($topics, $this); - after_topics: $result['topics'] = $topics; + after_mergeable: $result['mergeable'] = $mergeable; - $watchers = $object->watchers; - after_watchers: $result['watchers'] = $watchers; + $rebaseable = $object->rebaseable; - $watchersCount = $object->watchersCount; - after_watchersCount: $result['watchers_count'] = $watchersCount; + if ($rebaseable === null) { + goto after_rebaseable; + } - $createdAt = $object->createdAt; - after_createdAt: $result['created_at'] = $createdAt; + after_rebaseable: $result['rebaseable'] = $rebaseable; - $updatedAt = $object->updatedAt; - after_updatedAt: $result['updated_at'] = $updatedAt; + $mergeableState = $object->mergeableState; + after_mergeableState: $result['mergeable_state'] = $mergeableState; - $allowForking = $object->allowForking; + $mergedBy = $object->mergedBy; - if ($allowForking === null) { - goto after_allowForking; + if ($mergedBy === null) { + goto after_mergedBy; } - after_allowForking: $result['allow_forking'] = $allowForking; + $mergedBy = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleUser($mergedBy); + after_mergedBy: $result['merged_by'] = $mergedBy; - $isTemplate = $object->isTemplate; + $comments = $object->comments; + after_comments: $result['comments'] = $comments; - if ($isTemplate === null) { - goto after_isTemplate; - } + $reviewComments = $object->reviewComments; + after_reviewComments: $result['review_comments'] = $reviewComments; - after_isTemplate: $result['is_template'] = $isTemplate; + $maintainerCanModify = $object->maintainerCanModify; + after_maintainerCanModify: $result['maintainer_can_modify'] = $maintainerCanModify; - $webCommitSignoffRequired = $object->webCommitSignoffRequired; + $commits = $object->commits; + after_commits: $result['commits'] = $commits; - if ($webCommitSignoffRequired === null) { - goto after_webCommitSignoffRequired; - } + $additions = $object->additions; + after_additions: $result['additions'] = $additions; - after_webCommitSignoffRequired: $result['web_commit_signoff_required'] = $webCommitSignoffRequired; + $deletions = $object->deletions; + after_deletions: $result['deletions'] = $deletions; + + $changedFiles = $object->changedFiles; + after_changedFiles: $result['changed_files'] = $changedFiles; return $result; } - private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo⚡️Owner(mixed $object): mixed + private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleUser(mixed $object): mixed { - assert($object instanceof Owner); + assert($object instanceof SimpleUser); $result = []; - $avatarUrl = $object->avatarUrl; - after_avatarUrl: $result['avatar_url'] = $avatarUrl; + $name = $object->name; - $eventsUrl = $object->eventsUrl; - after_eventsUrl: $result['events_url'] = $eventsUrl; + if ($name === null) { + goto after_name; + } - $followersUrl = $object->followersUrl; - after_followersUrl: $result['followers_url'] = $followersUrl; + after_name: $result['name'] = $name; - $followingUrl = $object->followingUrl; - after_followingUrl: $result['following_url'] = $followingUrl; + $email = $object->email; - $gistsUrl = $object->gistsUrl; - after_gistsUrl: $result['gists_url'] = $gistsUrl; + if ($email === null) { + goto after_email; + } + + after_email: $result['email'] = $email; + + $login = $object->login; + after_login: $result['login'] = $login; + + $id = $object->id; + after_id: $result['id'] = $id; + + $nodeId = $object->nodeId; + after_nodeId: $result['node_id'] = $nodeId; + + $avatarUrl = $object->avatarUrl; + after_avatarUrl: $result['avatar_url'] = $avatarUrl; $gravatarId = $object->gravatarId; @@ -5942,41 +3448,52 @@ private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseClou after_gravatarId: $result['gravatar_id'] = $gravatarId; + $url = $object->url; + after_url: $result['url'] = $url; + $htmlUrl = $object->htmlUrl; after_htmlUrl: $result['html_url'] = $htmlUrl; - $id = $object->id; - after_id: $result['id'] = $id; + $followersUrl = $object->followersUrl; + after_followersUrl: $result['followers_url'] = $followersUrl; - $nodeId = $object->nodeId; - after_nodeId: $result['node_id'] = $nodeId; + $followingUrl = $object->followingUrl; + after_followingUrl: $result['following_url'] = $followingUrl; - $login = $object->login; - after_login: $result['login'] = $login; + $gistsUrl = $object->gistsUrl; + after_gistsUrl: $result['gists_url'] = $gistsUrl; + + $starredUrl = $object->starredUrl; + after_starredUrl: $result['starred_url'] = $starredUrl; + + $subscriptionsUrl = $object->subscriptionsUrl; + after_subscriptionsUrl: $result['subscriptions_url'] = $subscriptionsUrl; $organizationsUrl = $object->organizationsUrl; after_organizationsUrl: $result['organizations_url'] = $organizationsUrl; + $reposUrl = $object->reposUrl; + after_reposUrl: $result['repos_url'] = $reposUrl; + + $eventsUrl = $object->eventsUrl; + after_eventsUrl: $result['events_url'] = $eventsUrl; + $receivedEventsUrl = $object->receivedEventsUrl; after_receivedEventsUrl: $result['received_events_url'] = $receivedEventsUrl; - $reposUrl = $object->reposUrl; - after_reposUrl: $result['repos_url'] = $reposUrl; + $type = $object->type; + after_type: $result['type'] = $type; $siteAdmin = $object->siteAdmin; after_siteAdmin: $result['site_admin'] = $siteAdmin; - $starredUrl = $object->starredUrl; - after_starredUrl: $result['starred_url'] = $starredUrl; - - $subscriptionsUrl = $object->subscriptionsUrl; - after_subscriptionsUrl: $result['subscriptions_url'] = $subscriptionsUrl; + $starredAt = $object->starredAt; - $type = $object->type; - after_type: $result['type'] = $type; + if ($starredAt === null) { + goto after_starredAt; + } - $url = $object->url; - after_url: $result['url'] = $url; + after_starredAt: $result['starred_at'] = $starredAt; $userViewType = $object->userViewType; @@ -5989,150 +3506,86 @@ private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseClou return $result; } - private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo⚡️Permissions(mixed $object): mixed - { - assert($object instanceof Permissions); - $result = []; - - $admin = $object->admin; - after_admin: $result['admin'] = $admin; - - $maintain = $object->maintain; - - if ($maintain === null) { - goto after_maintain; - } - - after_maintain: $result['maintain'] = $maintain; - - $push = $object->push; - after_push: $result['push'] = $push; - - $triage = $object->triage; - - if ($triage === null) { - goto after_triage; - } - - after_triage: $result['triage'] = $triage; - - $pull = $object->pull; - after_pull: $result['pull'] = $pull; - - return $result; - } - - private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo⚡️License(mixed $object): mixed + private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Milestone(mixed $object): mixed { - assert($object instanceof License); + assert($object instanceof Milestone); $result = []; - $key = $object->key; - after_key: $result['key'] = $key; - - $name = $object->name; - after_name: $result['name'] = $name; - - $url = $object->url; - - if ($url === null) { - goto after_url; - } - + $url = $object->url; after_url: $result['url'] = $url; - $spdxId = $object->spdxId; + $htmlUrl = $object->htmlUrl; + after_htmlUrl: $result['html_url'] = $htmlUrl; - if ($spdxId === null) { - goto after_spdxId; - } + $labelsUrl = $object->labelsUrl; + after_labelsUrl: $result['labels_url'] = $labelsUrl; - after_spdxId: $result['spdx_id'] = $spdxId; + $id = $object->id; + after_id: $result['id'] = $id; $nodeId = $object->nodeId; after_nodeId: $result['node_id'] = $nodeId; - return $result; - } - - private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️User(mixed $object): mixed - { - assert($object instanceof User); - $result = []; - - $avatarUrl = $object->avatarUrl; - after_avatarUrl: $result['avatar_url'] = $avatarUrl; - - $eventsUrl = $object->eventsUrl; - after_eventsUrl: $result['events_url'] = $eventsUrl; - - $followersUrl = $object->followersUrl; - after_followersUrl: $result['followers_url'] = $followersUrl; + $number = $object->number; + after_number: $result['number'] = $number; - $followingUrl = $object->followingUrl; - after_followingUrl: $result['following_url'] = $followingUrl; + $state = $object->state; + after_state: $result['state'] = $state; - $gistsUrl = $object->gistsUrl; - after_gistsUrl: $result['gists_url'] = $gistsUrl; + $title = $object->title; + after_title: $result['title'] = $title; - $gravatarId = $object->gravatarId; + $description = $object->description; - if ($gravatarId === null) { - goto after_gravatarId; + if ($description === null) { + goto after_description; } - after_gravatarId: $result['gravatar_id'] = $gravatarId; - - $htmlUrl = $object->htmlUrl; - after_htmlUrl: $result['html_url'] = $htmlUrl; - - $id = $object->id; - after_id: $result['id'] = $id; + after_description: $result['description'] = $description; - $nodeId = $object->nodeId; - after_nodeId: $result['node_id'] = $nodeId; + $creator = $object->creator; - $login = $object->login; - after_login: $result['login'] = $login; + if ($creator === null) { + goto after_creator; + } - $organizationsUrl = $object->organizationsUrl; - after_organizationsUrl: $result['organizations_url'] = $organizationsUrl; + $creator = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleUser($creator); + after_creator: $result['creator'] = $creator; - $receivedEventsUrl = $object->receivedEventsUrl; - after_receivedEventsUrl: $result['received_events_url'] = $receivedEventsUrl; + $openIssues = $object->openIssues; + after_openIssues: $result['open_issues'] = $openIssues; - $reposUrl = $object->reposUrl; - after_reposUrl: $result['repos_url'] = $reposUrl; + $closedIssues = $object->closedIssues; + after_closedIssues: $result['closed_issues'] = $closedIssues; - $siteAdmin = $object->siteAdmin; - after_siteAdmin: $result['site_admin'] = $siteAdmin; + $createdAt = $object->createdAt; + after_createdAt: $result['created_at'] = $createdAt; - $starredUrl = $object->starredUrl; - after_starredUrl: $result['starred_url'] = $starredUrl; + $updatedAt = $object->updatedAt; + after_updatedAt: $result['updated_at'] = $updatedAt; - $subscriptionsUrl = $object->subscriptionsUrl; - after_subscriptionsUrl: $result['subscriptions_url'] = $subscriptionsUrl; + $closedAt = $object->closedAt; - $type = $object->type; - after_type: $result['type'] = $type; + if ($closedAt === null) { + goto after_closedAt; + } - $url = $object->url; - after_url: $result['url'] = $url; + after_closedAt: $result['closed_at'] = $closedAt; - $userViewType = $object->userViewType; + $dueOn = $object->dueOn; - if ($userViewType === null) { - goto after_userViewType; + if ($dueOn === null) { + goto after_dueOn; } - after_userViewType: $result['user_view_type'] = $userViewType; + after_dueOn: $result['due_on'] = $dueOn; return $result; } - private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base(mixed $object): mixed + private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head(mixed $object): mixed { - assert($object instanceof Base); + assert($object instanceof Head); $result = []; $label = $object->label; @@ -6142,24 +3595,81 @@ private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseClou after_ref: $result['ref'] = $ref; $repo = $object->repo; - $repo = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️Repo($repo); + $repo = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Repository($repo); after_repo: $result['repo'] = $repo; $sha = $object->sha; after_sha: $result['sha'] = $sha; $user = $object->user; - $user = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️User($user); + $user = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleUser($user); after_user: $result['user'] = $user; return $result; } - private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️Repo(mixed $object): mixed + private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Repository(mixed $object): mixed { - assert($object instanceof \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo); + assert($object instanceof Repository); $result = []; + $id = $object->id; + after_id: $result['id'] = $id; + + $nodeId = $object->nodeId; + after_nodeId: $result['node_id'] = $nodeId; + + $name = $object->name; + after_name: $result['name'] = $name; + + $fullName = $object->fullName; + after_fullName: $result['full_name'] = $fullName; + + $license = $object->license; + + if ($license === null) { + goto after_license; + } + + $license = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️LicenseSimple($license); + after_license: $result['license'] = $license; + + $forks = $object->forks; + after_forks: $result['forks'] = $forks; + + $permissions = $object->permissions; + + if ($permissions === null) { + goto after_permissions; + } + + $permissions = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Repository⚡️Permissions($permissions); + after_permissions: $result['permissions'] = $permissions; + + $owner = $object->owner; + $owner = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleUser($owner); + after_owner: $result['owner'] = $owner; + + $private = $object->private; + after_private: $result['private'] = $private; + + $htmlUrl = $object->htmlUrl; + after_htmlUrl: $result['html_url'] = $htmlUrl; + + $description = $object->description; + + if ($description === null) { + goto after_description; + } + + after_description: $result['description'] = $description; + + $fork = $object->fork; + after_fork: $result['fork'] = $fork; + + $url = $object->url; + after_url: $result['url'] = $url; + $archiveUrl = $object->archiveUrl; after_archiveUrl: $result['archive_url'] = $archiveUrl; @@ -6193,29 +3703,15 @@ private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseClou $deploymentsUrl = $object->deploymentsUrl; after_deploymentsUrl: $result['deployments_url'] = $deploymentsUrl; - $description = $object->description; - - if ($description === null) { - goto after_description; - } - - after_description: $result['description'] = $description; - $downloadsUrl = $object->downloadsUrl; after_downloadsUrl: $result['downloads_url'] = $downloadsUrl; $eventsUrl = $object->eventsUrl; after_eventsUrl: $result['events_url'] = $eventsUrl; - $fork = $object->fork; - after_fork: $result['fork'] = $fork; - $forksUrl = $object->forksUrl; after_forksUrl: $result['forks_url'] = $forksUrl; - $fullName = $object->fullName; - after_fullName: $result['full_name'] = $fullName; - $gitCommitsUrl = $object->gitCommitsUrl; after_gitCommitsUrl: $result['git_commits_url'] = $gitCommitsUrl; @@ -6225,25 +3721,8 @@ private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseClou $gitTagsUrl = $object->gitTagsUrl; after_gitTagsUrl: $result['git_tags_url'] = $gitTagsUrl; - $hooksUrl = $object->hooksUrl; - after_hooksUrl: $result['hooks_url'] = $hooksUrl; - - $htmlUrl = $object->htmlUrl; - after_htmlUrl: $result['html_url'] = $htmlUrl; - - $id = $object->id; - after_id: $result['id'] = $id; - - $isTemplate = $object->isTemplate; - - if ($isTemplate === null) { - goto after_isTemplate; - } - - after_isTemplate: $result['is_template'] = $isTemplate; - - $nodeId = $object->nodeId; - after_nodeId: $result['node_id'] = $nodeId; + $gitUrl = $object->gitUrl; + after_gitUrl: $result['git_url'] = $gitUrl; $issueCommentUrl = $object->issueCommentUrl; after_issueCommentUrl: $result['issue_comment_url'] = $issueCommentUrl; @@ -6269,25 +3748,18 @@ private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseClou $milestonesUrl = $object->milestonesUrl; after_milestonesUrl: $result['milestones_url'] = $milestonesUrl; - $name = $object->name; - after_name: $result['name'] = $name; - $notificationsUrl = $object->notificationsUrl; after_notificationsUrl: $result['notifications_url'] = $notificationsUrl; - $owner = $object->owner; - $owner = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️Repo⚡️Owner($owner); - after_owner: $result['owner'] = $owner; - - $private = $object->private; - after_private: $result['private'] = $private; - $pullsUrl = $object->pullsUrl; after_pullsUrl: $result['pulls_url'] = $pullsUrl; $releasesUrl = $object->releasesUrl; after_releasesUrl: $result['releases_url'] = $releasesUrl; + $sshUrl = $object->sshUrl; + after_sshUrl: $result['ssh_url'] = $sshUrl; + $stargazersUrl = $object->stargazersUrl; after_stargazersUrl: $result['stargazers_url'] = $stargazersUrl; @@ -6309,41 +3781,22 @@ private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseClou $treesUrl = $object->treesUrl; after_treesUrl: $result['trees_url'] = $treesUrl; - $url = $object->url; - after_url: $result['url'] = $url; - $cloneUrl = $object->cloneUrl; after_cloneUrl: $result['clone_url'] = $cloneUrl; - $defaultBranch = $object->defaultBranch; - after_defaultBranch: $result['default_branch'] = $defaultBranch; - - $forks = $object->forks; - after_forks: $result['forks'] = $forks; - - $forksCount = $object->forksCount; - after_forksCount: $result['forks_count'] = $forksCount; - - $gitUrl = $object->gitUrl; - after_gitUrl: $result['git_url'] = $gitUrl; - - $hasDownloads = $object->hasDownloads; - after_hasDownloads: $result['has_downloads'] = $hasDownloads; - - $hasIssues = $object->hasIssues; - after_hasIssues: $result['has_issues'] = $hasIssues; + $mirrorUrl = $object->mirrorUrl; - $hasProjects = $object->hasProjects; - after_hasProjects: $result['has_projects'] = $hasProjects; + if ($mirrorUrl === null) { + goto after_mirrorUrl; + } - $hasWiki = $object->hasWiki; - after_hasWiki: $result['has_wiki'] = $hasWiki; + after_mirrorUrl: $result['mirror_url'] = $mirrorUrl; - $hasPages = $object->hasPages; - after_hasPages: $result['has_pages'] = $hasPages; + $hooksUrl = $object->hooksUrl; + after_hooksUrl: $result['hooks_url'] = $hooksUrl; - $hasDiscussions = $object->hasDiscussions; - after_hasDiscussions: $result['has_discussions'] = $hasDiscussions; + $svnUrl = $object->svnUrl; + after_svnUrl: $result['svn_url'] = $svnUrl; $homepage = $object->homepage; @@ -6361,74 +3814,107 @@ private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseClou after_language: $result['language'] = $language; - $masterBranch = $object->masterBranch; + $forksCount = $object->forksCount; + after_forksCount: $result['forks_count'] = $forksCount; - if ($masterBranch === null) { - goto after_masterBranch; + $stargazersCount = $object->stargazersCount; + after_stargazersCount: $result['stargazers_count'] = $stargazersCount; + + $watchersCount = $object->watchersCount; + after_watchersCount: $result['watchers_count'] = $watchersCount; + + $size = $object->size; + after_size: $result['size'] = $size; + + $defaultBranch = $object->defaultBranch; + after_defaultBranch: $result['default_branch'] = $defaultBranch; + + $openIssuesCount = $object->openIssuesCount; + after_openIssuesCount: $result['open_issues_count'] = $openIssuesCount; + + $isTemplate = $object->isTemplate; + + if ($isTemplate === null) { + goto after_isTemplate; } - after_masterBranch: $result['master_branch'] = $masterBranch; + after_isTemplate: $result['is_template'] = $isTemplate; - $archived = $object->archived; - after_archived: $result['archived'] = $archived; + $topics = $object->topics; - $disabled = $object->disabled; - after_disabled: $result['disabled'] = $disabled; + if ($topics === null) { + goto after_topics; + } - $visibility = $object->visibility; + static $topicsSerializer0; - if ($visibility === null) { - goto after_visibility; + if ($topicsSerializer0 === null) { + $topicsSerializer0 = new SerializeArrayItems(...[]); } - after_visibility: $result['visibility'] = $visibility; + $topics = $topicsSerializer0->serialize($topics, $this); + after_topics: $result['topics'] = $topics; - $mirrorUrl = $object->mirrorUrl; + $hasIssues = $object->hasIssues; + after_hasIssues: $result['has_issues'] = $hasIssues; - if ($mirrorUrl === null) { - goto after_mirrorUrl; + $hasProjects = $object->hasProjects; + after_hasProjects: $result['has_projects'] = $hasProjects; + + $hasWiki = $object->hasWiki; + after_hasWiki: $result['has_wiki'] = $hasWiki; + + $hasPages = $object->hasPages; + after_hasPages: $result['has_pages'] = $hasPages; + + $hasDownloads = $object->hasDownloads; + after_hasDownloads: $result['has_downloads'] = $hasDownloads; + + $hasDiscussions = $object->hasDiscussions; + + if ($hasDiscussions === null) { + goto after_hasDiscussions; } - after_mirrorUrl: $result['mirror_url'] = $mirrorUrl; + after_hasDiscussions: $result['has_discussions'] = $hasDiscussions; - $openIssues = $object->openIssues; - after_openIssues: $result['open_issues'] = $openIssues; + $archived = $object->archived; + after_archived: $result['archived'] = $archived; - $openIssuesCount = $object->openIssuesCount; - after_openIssuesCount: $result['open_issues_count'] = $openIssuesCount; + $disabled = $object->disabled; + after_disabled: $result['disabled'] = $disabled; - $permissions = $object->permissions; + $visibility = $object->visibility; - if ($permissions === null) { - goto after_permissions; + if ($visibility === null) { + goto after_visibility; } - $permissions = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️Repo⚡️Permissions($permissions); - after_permissions: $result['permissions'] = $permissions; + after_visibility: $result['visibility'] = $visibility; - $tempCloneToken = $object->tempCloneToken; + $pushedAt = $object->pushedAt; - if ($tempCloneToken === null) { - goto after_tempCloneToken; + if ($pushedAt === null) { + goto after_pushedAt; } - after_tempCloneToken: $result['temp_clone_token'] = $tempCloneToken; + after_pushedAt: $result['pushed_at'] = $pushedAt; - $allowMergeCommit = $object->allowMergeCommit; + $createdAt = $object->createdAt; - if ($allowMergeCommit === null) { - goto after_allowMergeCommit; + if ($createdAt === null) { + goto after_createdAt; } - after_allowMergeCommit: $result['allow_merge_commit'] = $allowMergeCommit; + after_createdAt: $result['created_at'] = $createdAt; - $allowSquashMerge = $object->allowSquashMerge; + $updatedAt = $object->updatedAt; - if ($allowSquashMerge === null) { - goto after_allowSquashMerge; + if ($updatedAt === null) { + goto after_updatedAt; } - after_allowSquashMerge: $result['allow_squash_merge'] = $allowSquashMerge; + after_updatedAt: $result['updated_at'] = $updatedAt; $allowRebaseMerge = $object->allowRebaseMerge; @@ -6438,180 +3924,139 @@ private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseClou after_allowRebaseMerge: $result['allow_rebase_merge'] = $allowRebaseMerge; - $license = $object->license; + $tempCloneToken = $object->tempCloneToken; - if ($license === null) { - goto after_license; + if ($tempCloneToken === null) { + goto after_tempCloneToken; } - $license = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️LicenseSimple($license); - after_license: $result['license'] = $license; - - $pushedAt = $object->pushedAt; - after_pushedAt: $result['pushed_at'] = $pushedAt; - - $size = $object->size; - after_size: $result['size'] = $size; + after_tempCloneToken: $result['temp_clone_token'] = $tempCloneToken; - $sshUrl = $object->sshUrl; - after_sshUrl: $result['ssh_url'] = $sshUrl; + $allowSquashMerge = $object->allowSquashMerge; - $stargazersCount = $object->stargazersCount; - after_stargazersCount: $result['stargazers_count'] = $stargazersCount; + if ($allowSquashMerge === null) { + goto after_allowSquashMerge; + } - $svnUrl = $object->svnUrl; - after_svnUrl: $result['svn_url'] = $svnUrl; + after_allowSquashMerge: $result['allow_squash_merge'] = $allowSquashMerge; - $topics = $object->topics; + $allowAutoMerge = $object->allowAutoMerge; - if ($topics === null) { - goto after_topics; + if ($allowAutoMerge === null) { + goto after_allowAutoMerge; } - static $topicsSerializer0; + after_allowAutoMerge: $result['allow_auto_merge'] = $allowAutoMerge; - if ($topicsSerializer0 === null) { - $topicsSerializer0 = new SerializeArrayItems(...[]); - } + $deleteBranchOnMerge = $object->deleteBranchOnMerge; - $topics = $topicsSerializer0->serialize($topics, $this); - after_topics: $result['topics'] = $topics; + if ($deleteBranchOnMerge === null) { + goto after_deleteBranchOnMerge; + } - $watchers = $object->watchers; - after_watchers: $result['watchers'] = $watchers; + after_deleteBranchOnMerge: $result['delete_branch_on_merge'] = $deleteBranchOnMerge; - $watchersCount = $object->watchersCount; - after_watchersCount: $result['watchers_count'] = $watchersCount; + $allowUpdateBranch = $object->allowUpdateBranch; - $createdAt = $object->createdAt; - after_createdAt: $result['created_at'] = $createdAt; + if ($allowUpdateBranch === null) { + goto after_allowUpdateBranch; + } - $updatedAt = $object->updatedAt; - after_updatedAt: $result['updated_at'] = $updatedAt; + after_allowUpdateBranch: $result['allow_update_branch'] = $allowUpdateBranch; - $allowForking = $object->allowForking; + $useSquashPrTitleAsDefault = $object->useSquashPrTitleAsDefault; - if ($allowForking === null) { - goto after_allowForking; + if ($useSquashPrTitleAsDefault === null) { + goto after_useSquashPrTitleAsDefault; } - after_allowForking: $result['allow_forking'] = $allowForking; + after_useSquashPrTitleAsDefault: $result['use_squash_pr_title_as_default'] = $useSquashPrTitleAsDefault; - $webCommitSignoffRequired = $object->webCommitSignoffRequired; + $squashMergeCommitTitle = $object->squashMergeCommitTitle; - if ($webCommitSignoffRequired === null) { - goto after_webCommitSignoffRequired; + if ($squashMergeCommitTitle === null) { + goto after_squashMergeCommitTitle; } - after_webCommitSignoffRequired: $result['web_commit_signoff_required'] = $webCommitSignoffRequired; - - return $result; - } + after_squashMergeCommitTitle: $result['squash_merge_commit_title'] = $squashMergeCommitTitle; - private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️Repo⚡️Owner(mixed $object): mixed - { - assert($object instanceof \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo\Owner); - $result = []; + $squashMergeCommitMessage = $object->squashMergeCommitMessage; - $avatarUrl = $object->avatarUrl; - after_avatarUrl: $result['avatar_url'] = $avatarUrl; + if ($squashMergeCommitMessage === null) { + goto after_squashMergeCommitMessage; + } - $eventsUrl = $object->eventsUrl; - after_eventsUrl: $result['events_url'] = $eventsUrl; + after_squashMergeCommitMessage: $result['squash_merge_commit_message'] = $squashMergeCommitMessage; - $followersUrl = $object->followersUrl; - after_followersUrl: $result['followers_url'] = $followersUrl; + $mergeCommitTitle = $object->mergeCommitTitle; - $followingUrl = $object->followingUrl; - after_followingUrl: $result['following_url'] = $followingUrl; + if ($mergeCommitTitle === null) { + goto after_mergeCommitTitle; + } - $gistsUrl = $object->gistsUrl; - after_gistsUrl: $result['gists_url'] = $gistsUrl; + after_mergeCommitTitle: $result['merge_commit_title'] = $mergeCommitTitle; - $gravatarId = $object->gravatarId; + $mergeCommitMessage = $object->mergeCommitMessage; - if ($gravatarId === null) { - goto after_gravatarId; + if ($mergeCommitMessage === null) { + goto after_mergeCommitMessage; } - after_gravatarId: $result['gravatar_id'] = $gravatarId; - - $htmlUrl = $object->htmlUrl; - after_htmlUrl: $result['html_url'] = $htmlUrl; + after_mergeCommitMessage: $result['merge_commit_message'] = $mergeCommitMessage; - $id = $object->id; - after_id: $result['id'] = $id; + $allowMergeCommit = $object->allowMergeCommit; - $nodeId = $object->nodeId; - after_nodeId: $result['node_id'] = $nodeId; + if ($allowMergeCommit === null) { + goto after_allowMergeCommit; + } - $login = $object->login; - after_login: $result['login'] = $login; + after_allowMergeCommit: $result['allow_merge_commit'] = $allowMergeCommit; - $organizationsUrl = $object->organizationsUrl; - after_organizationsUrl: $result['organizations_url'] = $organizationsUrl; + $allowForking = $object->allowForking; - $receivedEventsUrl = $object->receivedEventsUrl; - after_receivedEventsUrl: $result['received_events_url'] = $receivedEventsUrl; + if ($allowForking === null) { + goto after_allowForking; + } - $reposUrl = $object->reposUrl; - after_reposUrl: $result['repos_url'] = $reposUrl; + after_allowForking: $result['allow_forking'] = $allowForking; - $siteAdmin = $object->siteAdmin; - after_siteAdmin: $result['site_admin'] = $siteAdmin; + $webCommitSignoffRequired = $object->webCommitSignoffRequired; - $starredUrl = $object->starredUrl; - after_starredUrl: $result['starred_url'] = $starredUrl; + if ($webCommitSignoffRequired === null) { + goto after_webCommitSignoffRequired; + } - $subscriptionsUrl = $object->subscriptionsUrl; - after_subscriptionsUrl: $result['subscriptions_url'] = $subscriptionsUrl; + after_webCommitSignoffRequired: $result['web_commit_signoff_required'] = $webCommitSignoffRequired; - $type = $object->type; - after_type: $result['type'] = $type; + $openIssues = $object->openIssues; + after_openIssues: $result['open_issues'] = $openIssues; - $url = $object->url; - after_url: $result['url'] = $url; + $watchers = $object->watchers; + after_watchers: $result['watchers'] = $watchers; - $userViewType = $object->userViewType; + $masterBranch = $object->masterBranch; - if ($userViewType === null) { - goto after_userViewType; + if ($masterBranch === null) { + goto after_masterBranch; } - after_userViewType: $result['user_view_type'] = $userViewType; - - return $result; - } - - private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️Repo⚡️Permissions(mixed $object): mixed - { - assert($object instanceof \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo\Permissions); - $result = []; - - $admin = $object->admin; - after_admin: $result['admin'] = $admin; + after_masterBranch: $result['master_branch'] = $masterBranch; - $maintain = $object->maintain; + $starredAt = $object->starredAt; - if ($maintain === null) { - goto after_maintain; + if ($starredAt === null) { + goto after_starredAt; } - after_maintain: $result['maintain'] = $maintain; - - $push = $object->push; - after_push: $result['push'] = $push; + after_starredAt: $result['starred_at'] = $starredAt; - $triage = $object->triage; + $anonymousAccessEnabled = $object->anonymousAccessEnabled; - if ($triage === null) { - goto after_triage; + if ($anonymousAccessEnabled === null) { + goto after_anonymousAccessEnabled; } - after_triage: $result['triage'] = $triage; - - $pull = $object->pull; - after_pull: $result['pull'] = $pull; + after_anonymousAccessEnabled: $result['anonymous_access_enabled'] = $anonymousAccessEnabled; return $result; } @@ -6657,77 +4102,60 @@ private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseClou return $result; } - private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️User(mixed $object): mixed + private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Repository⚡️Permissions(mixed $object): mixed { - assert($object instanceof \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\User); + assert($object instanceof Permissions); $result = []; - $avatarUrl = $object->avatarUrl; - after_avatarUrl: $result['avatar_url'] = $avatarUrl; - - $eventsUrl = $object->eventsUrl; - after_eventsUrl: $result['events_url'] = $eventsUrl; - - $followersUrl = $object->followersUrl; - after_followersUrl: $result['followers_url'] = $followersUrl; - - $followingUrl = $object->followingUrl; - after_followingUrl: $result['following_url'] = $followingUrl; + $admin = $object->admin; + after_admin: $result['admin'] = $admin; - $gistsUrl = $object->gistsUrl; - after_gistsUrl: $result['gists_url'] = $gistsUrl; + $pull = $object->pull; + after_pull: $result['pull'] = $pull; - $gravatarId = $object->gravatarId; + $triage = $object->triage; - if ($gravatarId === null) { - goto after_gravatarId; + if ($triage === null) { + goto after_triage; } - after_gravatarId: $result['gravatar_id'] = $gravatarId; - - $htmlUrl = $object->htmlUrl; - after_htmlUrl: $result['html_url'] = $htmlUrl; - - $id = $object->id; - after_id: $result['id'] = $id; - - $nodeId = $object->nodeId; - after_nodeId: $result['node_id'] = $nodeId; - - $login = $object->login; - after_login: $result['login'] = $login; + after_triage: $result['triage'] = $triage; - $organizationsUrl = $object->organizationsUrl; - after_organizationsUrl: $result['organizations_url'] = $organizationsUrl; + $push = $object->push; + after_push: $result['push'] = $push; - $receivedEventsUrl = $object->receivedEventsUrl; - after_receivedEventsUrl: $result['received_events_url'] = $receivedEventsUrl; + $maintain = $object->maintain; - $reposUrl = $object->reposUrl; - after_reposUrl: $result['repos_url'] = $reposUrl; + if ($maintain === null) { + goto after_maintain; + } - $siteAdmin = $object->siteAdmin; - after_siteAdmin: $result['site_admin'] = $siteAdmin; + after_maintain: $result['maintain'] = $maintain; - $starredUrl = $object->starredUrl; - after_starredUrl: $result['starred_url'] = $starredUrl; + return $result; + } - $subscriptionsUrl = $object->subscriptionsUrl; - after_subscriptionsUrl: $result['subscriptions_url'] = $subscriptionsUrl; + private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base(mixed $object): mixed + { + assert($object instanceof Base); + $result = []; - $type = $object->type; - after_type: $result['type'] = $type; + $label = $object->label; + after_label: $result['label'] = $label; - $url = $object->url; - after_url: $result['url'] = $url; + $ref = $object->ref; + after_ref: $result['ref'] = $ref; - $userViewType = $object->userViewType; + $repo = $object->repo; + $repo = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Repository($repo); + after_repo: $result['repo'] = $repo; - if ($userViewType === null) { - goto after_userViewType; - } + $sha = $object->sha; + after_sha: $result['sha'] = $sha; - after_userViewType: $result['user_view_type'] = $userViewType; + $user = $object->user; + $user = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleUser($user); + after_user: $result['user'] = $user; return $result; } diff --git a/clients/GitHubEnterpriseCloud/src/Internal/Hydrator/WebHook/CodeScanningAlert.php b/clients/GitHubEnterpriseCloud/src/Internal/Hydrator/WebHook/CodeScanningAlert.php index 59dbb494e08..9d99e4fdc4b 100644 --- a/clients/GitHubEnterpriseCloud/src/Internal/Hydrator/WebHook/CodeScanningAlert.php +++ b/clients/GitHubEnterpriseCloud/src/Internal/Hydrator/WebHook/CodeScanningAlert.php @@ -5591,7 +5591,7 @@ private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️S $value = $payload['state'] ?? null; if ($value === null) { - $missingFields[] = 'state'; + $properties['state'] = null; goto after_state; } @@ -11487,7 +11487,12 @@ private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseClou $rule = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️WebhookCodeScanningAlertCreated⚡️Alert⚡️Rule($rule); after_rule: $result['rule'] = $rule; - $state = $object->state; + $state = $object->state; + + if ($state === null) { + goto after_state; + } + after_state: $result['state'] = $state; $tool = $object->tool; diff --git a/clients/GitHubEnterpriseCloud/src/Internal/Hydrator/WebHook/PullRequest.php b/clients/GitHubEnterpriseCloud/src/Internal/Hydrator/WebHook/PullRequest.php index 125e81f3c1c..f263a2a44e9 100644 --- a/clients/GitHubEnterpriseCloud/src/Internal/Hydrator/WebHook/PullRequest.php +++ b/clients/GitHubEnterpriseCloud/src/Internal/Hydrator/WebHook/PullRequest.php @@ -8,6 +8,7 @@ use ApiClients\Client\GitHubEnterpriseCloud\Schema\LicenseSimple; use ApiClients\Client\GitHubEnterpriseCloud\Schema\Link; use ApiClients\Client\GitHubEnterpriseCloud\Schema\OrganizationSimpleWebhooks; +use ApiClients\Client\GitHubEnterpriseCloud\Schema\Repository; use ApiClients\Client\GitHubEnterpriseCloud\Schema\RepositoryWebhooks; use ApiClients\Client\GitHubEnterpriseCloud\Schema\RepositoryWebhooks\CustomProperties; use ApiClients\Client\GitHubEnterpriseCloud\Schema\RepositoryWebhooks\TemplateRepository; @@ -203,16 +204,9 @@ public function hydrateObject(string $className, array $payload): object 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest' => $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest($payload), 'ApiClients\Client\GitHubEnterpriseCloud\Schema\Milestone' => $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Milestone($payload), 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head' => $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head($payload), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo' => $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo($payload), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo\Owner' => $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo⚡️Owner($payload), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo\Permissions' => $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo⚡️Permissions($payload), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo\License' => $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo⚡️License($payload), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\User' => $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️User($payload), + 'ApiClients\Client\GitHubEnterpriseCloud\Schema\Repository' => $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Repository($payload), + 'ApiClients\Client\GitHubEnterpriseCloud\Schema\Repository\Permissions' => $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Repository⚡️Permissions($payload), 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base' => $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base($payload), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo' => $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️Repo($payload), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo\Owner' => $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️Repo⚡️Owner($payload), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo\Permissions' => $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️Repo⚡️Permissions($payload), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\User' => $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️User($payload), 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Links' => $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Links($payload), 'ApiClients\Client\GitHubEnterpriseCloud\Schema\Link' => $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Link($payload), 'ApiClients\Client\GitHubEnterpriseCloud\Schema\AutoMerge' => $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️AutoMerge($payload), @@ -24550,14 +24544,14 @@ private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️S $value = $payload['repo'] ?? null; if ($value === null) { - $properties['repo'] = null; + $missingFields[] = 'repo'; goto after_repo; } if (is_array($value)) { try { $this->hydrationStack[] = 'repo'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo($value); + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Repository($value); } finally { array_pop($this->hydrationStack); } @@ -24588,7 +24582,7 @@ private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️S if (is_array($value)) { try { $this->hydrationStack[] = 'user'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️User($value); + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleUser($value); } finally { array_pop($this->hydrationStack); } @@ -24612,11 +24606,181 @@ private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️S } } - private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo(array $payload): \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo + private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Repository(array $payload): Repository { $properties = []; $missingFields = []; try { + $value = $payload['id'] ?? null; + + if ($value === null) { + $missingFields[] = 'id'; + goto after_id; + } + + $properties['id'] = $value; + + after_id: + + $value = $payload['node_id'] ?? null; + + if ($value === null) { + $missingFields[] = 'node_id'; + goto after_nodeId; + } + + $properties['nodeId'] = $value; + + after_nodeId: + + $value = $payload['name'] ?? null; + + if ($value === null) { + $missingFields[] = 'name'; + goto after_name; + } + + $properties['name'] = $value; + + after_name: + + $value = $payload['full_name'] ?? null; + + if ($value === null) { + $missingFields[] = 'full_name'; + goto after_fullName; + } + + $properties['fullName'] = $value; + + after_fullName: + + $value = $payload['license'] ?? null; + + if ($value === null) { + $properties['license'] = null; + goto after_license; + } + + if (is_array($value)) { + try { + $this->hydrationStack[] = 'license'; + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️LicenseSimple($value); + } finally { + array_pop($this->hydrationStack); + } + } + + $properties['license'] = $value; + + after_license: + + $value = $payload['forks'] ?? null; + + if ($value === null) { + $missingFields[] = 'forks'; + goto after_forks; + } + + $properties['forks'] = $value; + + after_forks: + + $value = $payload['permissions'] ?? null; + + if ($value === null) { + $properties['permissions'] = null; + goto after_permissions; + } + + if (is_array($value)) { + try { + $this->hydrationStack[] = 'permissions'; + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Repository⚡️Permissions($value); + } finally { + array_pop($this->hydrationStack); + } + } + + $properties['permissions'] = $value; + + after_permissions: + + $value = $payload['owner'] ?? null; + + if ($value === null) { + $missingFields[] = 'owner'; + goto after_owner; + } + + if (is_array($value)) { + try { + $this->hydrationStack[] = 'owner'; + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleUser($value); + } finally { + array_pop($this->hydrationStack); + } + } + + $properties['owner'] = $value; + + after_owner: + + $value = $payload['private'] ?? null; + + if ($value === null) { + $missingFields[] = 'private'; + goto after_private; + } + + $properties['private'] = $value; + + after_private: + + $value = $payload['html_url'] ?? null; + + if ($value === null) { + $missingFields[] = 'html_url'; + goto after_htmlUrl; + } + + $properties['htmlUrl'] = $value; + + after_htmlUrl: + + $value = $payload['description'] ?? null; + + if ($value === null) { + $properties['description'] = null; + goto after_description; + } + + $properties['description'] = $value; + + after_description: + + $value = $payload['fork'] ?? null; + + if ($value === null) { + $missingFields[] = 'fork'; + goto after_fork; + } + + $properties['fork'] = $value; + + after_fork: + + $value = $payload['url'] ?? null; + + if ($value === null) { + $missingFields[] = 'url'; + goto after_url; + } + + $properties['url'] = $value; + + after_url: + $value = $payload['archive_url'] ?? null; if ($value === null) { @@ -24738,17 +24902,6 @@ private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️S after_deploymentsUrl: - $value = $payload['description'] ?? null; - - if ($value === null) { - $properties['description'] = null; - goto after_description; - } - - $properties['description'] = $value; - - after_description: - $value = $payload['downloads_url'] ?? null; if ($value === null) { @@ -24771,17 +24924,6 @@ private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️S after_eventsUrl: - $value = $payload['fork'] ?? null; - - if ($value === null) { - $missingFields[] = 'fork'; - goto after_fork; - } - - $properties['fork'] = $value; - - after_fork: - $value = $payload['forks_url'] ?? null; if ($value === null) { @@ -24793,17 +24935,6 @@ private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️S after_forksUrl: - $value = $payload['full_name'] ?? null; - - if ($value === null) { - $missingFields[] = 'full_name'; - goto after_fullName; - } - - $properties['fullName'] = $value; - - after_fullName: - $value = $payload['git_commits_url'] ?? null; if ($value === null) { @@ -24837,49 +24968,16 @@ private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️S after_gitTagsUrl: - $value = $payload['hooks_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'hooks_url'; - goto after_hooksUrl; - } - - $properties['hooksUrl'] = $value; - - after_hooksUrl: - - $value = $payload['html_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'html_url'; - goto after_htmlUrl; - } - - $properties['htmlUrl'] = $value; - - after_htmlUrl: - - $value = $payload['id'] ?? null; - - if ($value === null) { - $missingFields[] = 'id'; - goto after_id; - } - - $properties['id'] = $value; - - after_id: - - $value = $payload['node_id'] ?? null; + $value = $payload['git_url'] ?? null; if ($value === null) { - $missingFields[] = 'node_id'; - goto after_nodeId; + $missingFields[] = 'git_url'; + goto after_gitUrl; } - $properties['nodeId'] = $value; + $properties['gitUrl'] = $value; - after_nodeId: + after_gitUrl: $value = $payload['issue_comment_url'] ?? null; @@ -24969,17 +25067,6 @@ private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️S after_milestonesUrl: - $value = $payload['name'] ?? null; - - if ($value === null) { - $missingFields[] = 'name'; - goto after_name; - } - - $properties['name'] = $value; - - after_name: - $value = $payload['notifications_url'] ?? null; if ($value === null) { @@ -24991,37 +25078,6 @@ private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️S after_notificationsUrl: - $value = $payload['owner'] ?? null; - - if ($value === null) { - $missingFields[] = 'owner'; - goto after_owner; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'owner'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo⚡️Owner($value); - } finally { - array_pop($this->hydrationStack); - } - } - - $properties['owner'] = $value; - - after_owner: - - $value = $payload['private'] ?? null; - - if ($value === null) { - $missingFields[] = 'private'; - goto after_private; - } - - $properties['private'] = $value; - - after_private: - $value = $payload['pulls_url'] ?? null; if ($value === null) { @@ -25044,6 +25100,17 @@ private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️S after_releasesUrl: + $value = $payload['ssh_url'] ?? null; + + if ($value === null) { + $missingFields[] = 'ssh_url'; + goto after_sshUrl; + } + + $properties['sshUrl'] = $value; + + after_sshUrl: + $value = $payload['stargazers_url'] ?? null; if ($value === null) { @@ -25121,49 +25188,71 @@ private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️S after_treesUrl: - $value = $payload['url'] ?? null; + $value = $payload['clone_url'] ?? null; if ($value === null) { - $missingFields[] = 'url'; - goto after_url; + $missingFields[] = 'clone_url'; + goto after_cloneUrl; } - $properties['url'] = $value; + $properties['cloneUrl'] = $value; - after_url: + after_cloneUrl: - $value = $payload['clone_url'] ?? null; + $value = $payload['mirror_url'] ?? null; if ($value === null) { - $missingFields[] = 'clone_url'; - goto after_cloneUrl; + $properties['mirrorUrl'] = null; + goto after_mirrorUrl; } - $properties['cloneUrl'] = $value; + $properties['mirrorUrl'] = $value; - after_cloneUrl: + after_mirrorUrl: - $value = $payload['default_branch'] ?? null; + $value = $payload['hooks_url'] ?? null; if ($value === null) { - $missingFields[] = 'default_branch'; - goto after_defaultBranch; + $missingFields[] = 'hooks_url'; + goto after_hooksUrl; } - $properties['defaultBranch'] = $value; + $properties['hooksUrl'] = $value; - after_defaultBranch: + after_hooksUrl: - $value = $payload['forks'] ?? null; + $value = $payload['svn_url'] ?? null; if ($value === null) { - $missingFields[] = 'forks'; - goto after_forks; + $missingFields[] = 'svn_url'; + goto after_svnUrl; } - $properties['forks'] = $value; + $properties['svnUrl'] = $value; - after_forks: + after_svnUrl: + + $value = $payload['homepage'] ?? null; + + if ($value === null) { + $properties['homepage'] = null; + goto after_homepage; + } + + $properties['homepage'] = $value; + + after_homepage: + + $value = $payload['language'] ?? null; + + if ($value === null) { + $properties['language'] = null; + goto after_language; + } + + $properties['language'] = $value; + + after_language: $value = $payload['forks_count'] ?? null; @@ -25176,27 +25265,82 @@ private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️S after_forksCount: - $value = $payload['git_url'] ?? null; + $value = $payload['stargazers_count'] ?? null; if ($value === null) { - $missingFields[] = 'git_url'; - goto after_gitUrl; + $missingFields[] = 'stargazers_count'; + goto after_stargazersCount; } - $properties['gitUrl'] = $value; + $properties['stargazersCount'] = $value; - after_gitUrl: + after_stargazersCount: - $value = $payload['has_downloads'] ?? null; + $value = $payload['watchers_count'] ?? null; if ($value === null) { - $missingFields[] = 'has_downloads'; - goto after_hasDownloads; + $missingFields[] = 'watchers_count'; + goto after_watchersCount; } - $properties['hasDownloads'] = $value; + $properties['watchersCount'] = $value; - after_hasDownloads: + after_watchersCount: + + $value = $payload['size'] ?? null; + + if ($value === null) { + $missingFields[] = 'size'; + goto after_size; + } + + $properties['size'] = $value; + + after_size: + + $value = $payload['default_branch'] ?? null; + + if ($value === null) { + $missingFields[] = 'default_branch'; + goto after_defaultBranch; + } + + $properties['defaultBranch'] = $value; + + after_defaultBranch: + + $value = $payload['open_issues_count'] ?? null; + + if ($value === null) { + $missingFields[] = 'open_issues_count'; + goto after_openIssuesCount; + } + + $properties['openIssuesCount'] = $value; + + after_openIssuesCount: + + $value = $payload['is_template'] ?? null; + + if ($value === null) { + $properties['isTemplate'] = null; + goto after_isTemplate; + } + + $properties['isTemplate'] = $value; + + after_isTemplate: + + $value = $payload['topics'] ?? null; + + if ($value === null) { + $properties['topics'] = null; + goto after_topics; + } + + $properties['topics'] = $value; + + after_topics: $value = $payload['has_issues'] ?? null; @@ -25242,49 +25386,27 @@ private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️S after_hasPages: - $value = $payload['has_discussions'] ?? null; - - if ($value === null) { - $missingFields[] = 'has_discussions'; - goto after_hasDiscussions; - } - - $properties['hasDiscussions'] = $value; - - after_hasDiscussions: - - $value = $payload['homepage'] ?? null; - - if ($value === null) { - $properties['homepage'] = null; - goto after_homepage; - } - - $properties['homepage'] = $value; - - after_homepage: - - $value = $payload['language'] ?? null; + $value = $payload['has_downloads'] ?? null; if ($value === null) { - $properties['language'] = null; - goto after_language; + $missingFields[] = 'has_downloads'; + goto after_hasDownloads; } - $properties['language'] = $value; + $properties['hasDownloads'] = $value; - after_language: + after_hasDownloads: - $value = $payload['master_branch'] ?? null; + $value = $payload['has_discussions'] ?? null; if ($value === null) { - $properties['masterBranch'] = null; - goto after_masterBranch; + $properties['hasDiscussions'] = null; + goto after_hasDiscussions; } - $properties['masterBranch'] = $value; + $properties['hasDiscussions'] = $value; - after_masterBranch: + after_hasDiscussions: $value = $payload['archived'] ?? null; @@ -25319,58 +25441,49 @@ private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️S after_visibility: - $value = $payload['mirror_url'] ?? null; + $value = $payload['pushed_at'] ?? null; if ($value === null) { - $properties['mirrorUrl'] = null; - goto after_mirrorUrl; + $properties['pushedAt'] = null; + goto after_pushedAt; } - $properties['mirrorUrl'] = $value; + $properties['pushedAt'] = $value; - after_mirrorUrl: + after_pushedAt: - $value = $payload['open_issues'] ?? null; + $value = $payload['created_at'] ?? null; if ($value === null) { - $missingFields[] = 'open_issues'; - goto after_openIssues; + $properties['createdAt'] = null; + goto after_createdAt; } - $properties['openIssues'] = $value; + $properties['createdAt'] = $value; - after_openIssues: + after_createdAt: - $value = $payload['open_issues_count'] ?? null; + $value = $payload['updated_at'] ?? null; if ($value === null) { - $missingFields[] = 'open_issues_count'; - goto after_openIssuesCount; + $properties['updatedAt'] = null; + goto after_updatedAt; } - $properties['openIssuesCount'] = $value; + $properties['updatedAt'] = $value; - after_openIssuesCount: + after_updatedAt: - $value = $payload['permissions'] ?? null; + $value = $payload['allow_rebase_merge'] ?? null; if ($value === null) { - $properties['permissions'] = null; - goto after_permissions; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'permissions'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo⚡️Permissions($value); - } finally { - array_pop($this->hydrationStack); - } + $properties['allowRebaseMerge'] = null; + goto after_allowRebaseMerge; } - $properties['permissions'] = $value; + $properties['allowRebaseMerge'] = $value; - after_permissions: + after_allowRebaseMerge: $value = $payload['temp_clone_token'] ?? null; @@ -25383,17 +25496,6 @@ private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️S after_tempCloneToken: - $value = $payload['allow_merge_commit'] ?? null; - - if ($value === null) { - $properties['allowMergeCommit'] = null; - goto after_allowMergeCommit; - } - - $properties['allowMergeCommit'] = $value; - - after_allowMergeCommit: - $value = $payload['allow_squash_merge'] ?? null; if ($value === null) { @@ -25405,1125 +25507,1234 @@ private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️S after_allowSquashMerge: - $value = $payload['allow_rebase_merge'] ?? null; + $value = $payload['allow_auto_merge'] ?? null; if ($value === null) { - $properties['allowRebaseMerge'] = null; - goto after_allowRebaseMerge; + $properties['allowAutoMerge'] = null; + goto after_allowAutoMerge; } - $properties['allowRebaseMerge'] = $value; + $properties['allowAutoMerge'] = $value; - after_allowRebaseMerge: + after_allowAutoMerge: - $value = $payload['license'] ?? null; + $value = $payload['delete_branch_on_merge'] ?? null; if ($value === null) { - $properties['license'] = null; - goto after_license; + $properties['deleteBranchOnMerge'] = null; + goto after_deleteBranchOnMerge; } - if (is_array($value)) { - try { - $this->hydrationStack[] = 'license'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo⚡️License($value); - } finally { - array_pop($this->hydrationStack); - } + $properties['deleteBranchOnMerge'] = $value; + + after_deleteBranchOnMerge: + + $value = $payload['allow_update_branch'] ?? null; + + if ($value === null) { + $properties['allowUpdateBranch'] = null; + goto after_allowUpdateBranch; } - $properties['license'] = $value; + $properties['allowUpdateBranch'] = $value; - after_license: + after_allowUpdateBranch: - $value = $payload['pushed_at'] ?? null; + $value = $payload['use_squash_pr_title_as_default'] ?? null; if ($value === null) { - $missingFields[] = 'pushed_at'; - goto after_pushedAt; + $properties['useSquashPrTitleAsDefault'] = null; + goto after_useSquashPrTitleAsDefault; } - $properties['pushedAt'] = $value; + $properties['useSquashPrTitleAsDefault'] = $value; - after_pushedAt: + after_useSquashPrTitleAsDefault: - $value = $payload['size'] ?? null; + $value = $payload['squash_merge_commit_title'] ?? null; if ($value === null) { - $missingFields[] = 'size'; - goto after_size; + $properties['squashMergeCommitTitle'] = null; + goto after_squashMergeCommitTitle; } - $properties['size'] = $value; + $properties['squashMergeCommitTitle'] = $value; - after_size: + after_squashMergeCommitTitle: - $value = $payload['ssh_url'] ?? null; + $value = $payload['squash_merge_commit_message'] ?? null; if ($value === null) { - $missingFields[] = 'ssh_url'; - goto after_sshUrl; + $properties['squashMergeCommitMessage'] = null; + goto after_squashMergeCommitMessage; } - $properties['sshUrl'] = $value; + $properties['squashMergeCommitMessage'] = $value; - after_sshUrl: + after_squashMergeCommitMessage: - $value = $payload['stargazers_count'] ?? null; + $value = $payload['merge_commit_title'] ?? null; if ($value === null) { - $missingFields[] = 'stargazers_count'; - goto after_stargazersCount; + $properties['mergeCommitTitle'] = null; + goto after_mergeCommitTitle; } - $properties['stargazersCount'] = $value; + $properties['mergeCommitTitle'] = $value; - after_stargazersCount: + after_mergeCommitTitle: - $value = $payload['svn_url'] ?? null; + $value = $payload['merge_commit_message'] ?? null; if ($value === null) { - $missingFields[] = 'svn_url'; - goto after_svnUrl; + $properties['mergeCommitMessage'] = null; + goto after_mergeCommitMessage; } - $properties['svnUrl'] = $value; + $properties['mergeCommitMessage'] = $value; - after_svnUrl: + after_mergeCommitMessage: - $value = $payload['topics'] ?? null; + $value = $payload['allow_merge_commit'] ?? null; if ($value === null) { - $properties['topics'] = null; - goto after_topics; + $properties['allowMergeCommit'] = null; + goto after_allowMergeCommit; } - $properties['topics'] = $value; + $properties['allowMergeCommit'] = $value; - after_topics: + after_allowMergeCommit: - $value = $payload['watchers'] ?? null; + $value = $payload['allow_forking'] ?? null; if ($value === null) { - $missingFields[] = 'watchers'; - goto after_watchers; + $properties['allowForking'] = null; + goto after_allowForking; } - $properties['watchers'] = $value; + $properties['allowForking'] = $value; - after_watchers: + after_allowForking: - $value = $payload['watchers_count'] ?? null; + $value = $payload['web_commit_signoff_required'] ?? null; if ($value === null) { - $missingFields[] = 'watchers_count'; - goto after_watchersCount; + $properties['webCommitSignoffRequired'] = null; + goto after_webCommitSignoffRequired; } - $properties['watchersCount'] = $value; + $properties['webCommitSignoffRequired'] = $value; - after_watchersCount: + after_webCommitSignoffRequired: - $value = $payload['created_at'] ?? null; + $value = $payload['open_issues'] ?? null; if ($value === null) { - $missingFields[] = 'created_at'; - goto after_createdAt; + $missingFields[] = 'open_issues'; + goto after_openIssues; } - $properties['createdAt'] = $value; + $properties['openIssues'] = $value; - after_createdAt: + after_openIssues: - $value = $payload['updated_at'] ?? null; + $value = $payload['watchers'] ?? null; if ($value === null) { - $missingFields[] = 'updated_at'; - goto after_updatedAt; + $missingFields[] = 'watchers'; + goto after_watchers; } - $properties['updatedAt'] = $value; + $properties['watchers'] = $value; - after_updatedAt: + after_watchers: - $value = $payload['allow_forking'] ?? null; + $value = $payload['master_branch'] ?? null; if ($value === null) { - $properties['allowForking'] = null; - goto after_allowForking; + $properties['masterBranch'] = null; + goto after_masterBranch; } - $properties['allowForking'] = $value; + $properties['masterBranch'] = $value; - after_allowForking: + after_masterBranch: - $value = $payload['is_template'] ?? null; + $value = $payload['starred_at'] ?? null; if ($value === null) { - $properties['isTemplate'] = null; - goto after_isTemplate; + $properties['starredAt'] = null; + goto after_starredAt; } - $properties['isTemplate'] = $value; + $properties['starredAt'] = $value; - after_isTemplate: + after_starredAt: - $value = $payload['web_commit_signoff_required'] ?? null; + $value = $payload['anonymous_access_enabled'] ?? null; if ($value === null) { - $properties['webCommitSignoffRequired'] = null; - goto after_webCommitSignoffRequired; + $properties['anonymousAccessEnabled'] = null; + goto after_anonymousAccessEnabled; } - $properties['webCommitSignoffRequired'] = $value; + $properties['anonymousAccessEnabled'] = $value; - after_webCommitSignoffRequired: + after_anonymousAccessEnabled: } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo', $exception, stack: $this->hydrationStack); + throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\Repository', $exception, stack: $this->hydrationStack); } if (count($missingFields) > 0) { - throw UnableToHydrateObject::dueToMissingFields(\ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo::class, $missingFields, stack: $this->hydrationStack); + throw UnableToHydrateObject::dueToMissingFields(Repository::class, $missingFields, stack: $this->hydrationStack); } try { - return new \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo(...$properties); + return new Repository(...$properties); } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo', $exception, stack: $this->hydrationStack); + throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\Repository', $exception, stack: $this->hydrationStack); } } - private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo⚡️Owner(array $payload): \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo\Owner + private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Repository⚡️Permissions(array $payload): \ApiClients\Client\GitHubEnterpriseCloud\Schema\Repository\Permissions { $properties = []; $missingFields = []; try { - $value = $payload['avatar_url'] ?? null; + $value = $payload['admin'] ?? null; if ($value === null) { - $missingFields[] = 'avatar_url'; - goto after_avatarUrl; + $missingFields[] = 'admin'; + goto after_admin; } - $properties['avatarUrl'] = $value; + $properties['admin'] = $value; - after_avatarUrl: + after_admin: - $value = $payload['events_url'] ?? null; + $value = $payload['pull'] ?? null; if ($value === null) { - $missingFields[] = 'events_url'; - goto after_eventsUrl; + $missingFields[] = 'pull'; + goto after_pull; } - $properties['eventsUrl'] = $value; + $properties['pull'] = $value; - after_eventsUrl: + after_pull: - $value = $payload['followers_url'] ?? null; + $value = $payload['triage'] ?? null; if ($value === null) { - $missingFields[] = 'followers_url'; - goto after_followersUrl; + $properties['triage'] = null; + goto after_triage; } - $properties['followersUrl'] = $value; + $properties['triage'] = $value; - after_followersUrl: + after_triage: - $value = $payload['following_url'] ?? null; + $value = $payload['push'] ?? null; if ($value === null) { - $missingFields[] = 'following_url'; - goto after_followingUrl; + $missingFields[] = 'push'; + goto after_push; } - $properties['followingUrl'] = $value; + $properties['push'] = $value; - after_followingUrl: + after_push: - $value = $payload['gists_url'] ?? null; + $value = $payload['maintain'] ?? null; if ($value === null) { - $missingFields[] = 'gists_url'; - goto after_gistsUrl; + $properties['maintain'] = null; + goto after_maintain; } - $properties['gistsUrl'] = $value; + $properties['maintain'] = $value; - after_gistsUrl: + after_maintain: + } catch (Throwable $exception) { + throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\Repository\Permissions', $exception, stack: $this->hydrationStack); + } - $value = $payload['gravatar_id'] ?? null; + if (count($missingFields) > 0) { + throw UnableToHydrateObject::dueToMissingFields(\ApiClients\Client\GitHubEnterpriseCloud\Schema\Repository\Permissions::class, $missingFields, stack: $this->hydrationStack); + } + + try { + return new \ApiClients\Client\GitHubEnterpriseCloud\Schema\Repository\Permissions(...$properties); + } catch (Throwable $exception) { + throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\Repository\Permissions', $exception, stack: $this->hydrationStack); + } + } + + private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base(array $payload): \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base + { + $properties = []; + $missingFields = []; + try { + $value = $payload['label'] ?? null; if ($value === null) { - $properties['gravatarId'] = null; - goto after_gravatarId; + $missingFields[] = 'label'; + goto after_label; } - $properties['gravatarId'] = $value; + $properties['label'] = $value; - after_gravatarId: + after_label: - $value = $payload['html_url'] ?? null; + $value = $payload['ref'] ?? null; if ($value === null) { - $missingFields[] = 'html_url'; - goto after_htmlUrl; + $missingFields[] = 'ref'; + goto after_ref; } - $properties['htmlUrl'] = $value; + $properties['ref'] = $value; - after_htmlUrl: + after_ref: - $value = $payload['id'] ?? null; + $value = $payload['repo'] ?? null; if ($value === null) { - $missingFields[] = 'id'; - goto after_id; + $missingFields[] = 'repo'; + goto after_repo; } - $properties['id'] = $value; + if (is_array($value)) { + try { + $this->hydrationStack[] = 'repo'; + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Repository($value); + } finally { + array_pop($this->hydrationStack); + } + } - after_id: + $properties['repo'] = $value; - $value = $payload['node_id'] ?? null; + after_repo: + + $value = $payload['sha'] ?? null; if ($value === null) { - $missingFields[] = 'node_id'; - goto after_nodeId; + $missingFields[] = 'sha'; + goto after_sha; } - $properties['nodeId'] = $value; + $properties['sha'] = $value; - after_nodeId: + after_sha: - $value = $payload['login'] ?? null; + $value = $payload['user'] ?? null; if ($value === null) { - $missingFields[] = 'login'; - goto after_login; + $missingFields[] = 'user'; + goto after_user; } - $properties['login'] = $value; - - after_login: + if (is_array($value)) { + try { + $this->hydrationStack[] = 'user'; + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleUser($value); + } finally { + array_pop($this->hydrationStack); + } + } - $value = $payload['organizations_url'] ?? null; + $properties['user'] = $value; - if ($value === null) { - $missingFields[] = 'organizations_url'; - goto after_organizationsUrl; - } + after_user: + } catch (Throwable $exception) { + throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base', $exception, stack: $this->hydrationStack); + } - $properties['organizationsUrl'] = $value; + if (count($missingFields) > 0) { + throw UnableToHydrateObject::dueToMissingFields(\ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base::class, $missingFields, stack: $this->hydrationStack); + } - after_organizationsUrl: + try { + return new \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base(...$properties); + } catch (Throwable $exception) { + throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base', $exception, stack: $this->hydrationStack); + } + } - $value = $payload['received_events_url'] ?? null; + private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Links(array $payload): \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Links + { + $properties = []; + $missingFields = []; + try { + $value = $payload['comments'] ?? null; if ($value === null) { - $missingFields[] = 'received_events_url'; - goto after_receivedEventsUrl; + $missingFields[] = 'comments'; + goto after_comments; } - $properties['receivedEventsUrl'] = $value; + if (is_array($value)) { + try { + $this->hydrationStack[] = 'comments'; + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Link($value); + } finally { + array_pop($this->hydrationStack); + } + } - after_receivedEventsUrl: + $properties['comments'] = $value; - $value = $payload['repos_url'] ?? null; + after_comments: + + $value = $payload['commits'] ?? null; if ($value === null) { - $missingFields[] = 'repos_url'; - goto after_reposUrl; + $missingFields[] = 'commits'; + goto after_commits; } - $properties['reposUrl'] = $value; + if (is_array($value)) { + try { + $this->hydrationStack[] = 'commits'; + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Link($value); + } finally { + array_pop($this->hydrationStack); + } + } - after_reposUrl: + $properties['commits'] = $value; - $value = $payload['site_admin'] ?? null; + after_commits: + + $value = $payload['statuses'] ?? null; if ($value === null) { - $missingFields[] = 'site_admin'; - goto after_siteAdmin; + $missingFields[] = 'statuses'; + goto after_statuses; } - $properties['siteAdmin'] = $value; + if (is_array($value)) { + try { + $this->hydrationStack[] = 'statuses'; + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Link($value); + } finally { + array_pop($this->hydrationStack); + } + } - after_siteAdmin: + $properties['statuses'] = $value; - $value = $payload['starred_url'] ?? null; + after_statuses: + + $value = $payload['html'] ?? null; if ($value === null) { - $missingFields[] = 'starred_url'; - goto after_starredUrl; + $missingFields[] = 'html'; + goto after_html; } - $properties['starredUrl'] = $value; + if (is_array($value)) { + try { + $this->hydrationStack[] = 'html'; + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Link($value); + } finally { + array_pop($this->hydrationStack); + } + } - after_starredUrl: + $properties['html'] = $value; - $value = $payload['subscriptions_url'] ?? null; + after_html: + + $value = $payload['issue'] ?? null; if ($value === null) { - $missingFields[] = 'subscriptions_url'; - goto after_subscriptionsUrl; + $missingFields[] = 'issue'; + goto after_issue; } - $properties['subscriptionsUrl'] = $value; + if (is_array($value)) { + try { + $this->hydrationStack[] = 'issue'; + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Link($value); + } finally { + array_pop($this->hydrationStack); + } + } - after_subscriptionsUrl: + $properties['issue'] = $value; - $value = $payload['type'] ?? null; + after_issue: + + $value = $payload['review_comments'] ?? null; if ($value === null) { - $missingFields[] = 'type'; - goto after_type; + $missingFields[] = 'review_comments'; + goto after_reviewComments; } - $properties['type'] = $value; + if (is_array($value)) { + try { + $this->hydrationStack[] = 'reviewComments'; + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Link($value); + } finally { + array_pop($this->hydrationStack); + } + } - after_type: + $properties['reviewComments'] = $value; - $value = $payload['url'] ?? null; + after_reviewComments: + + $value = $payload['review_comment'] ?? null; if ($value === null) { - $missingFields[] = 'url'; - goto after_url; + $missingFields[] = 'review_comment'; + goto after_reviewComment; } - $properties['url'] = $value; + if (is_array($value)) { + try { + $this->hydrationStack[] = 'reviewComment'; + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Link($value); + } finally { + array_pop($this->hydrationStack); + } + } - after_url: + $properties['reviewComment'] = $value; - $value = $payload['user_view_type'] ?? null; + after_reviewComment: + + $value = $payload['self'] ?? null; if ($value === null) { - $properties['userViewType'] = null; - goto after_userViewType; + $missingFields[] = 'self'; + goto after_self; } - $properties['userViewType'] = $value; + if (is_array($value)) { + try { + $this->hydrationStack[] = 'self'; + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Link($value); + } finally { + array_pop($this->hydrationStack); + } + } - after_userViewType: + $properties['self'] = $value; + + after_self: } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo\Owner', $exception, stack: $this->hydrationStack); + throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Links', $exception, stack: $this->hydrationStack); } if (count($missingFields) > 0) { - throw UnableToHydrateObject::dueToMissingFields(\ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo\Owner::class, $missingFields, stack: $this->hydrationStack); + throw UnableToHydrateObject::dueToMissingFields(\ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Links::class, $missingFields, stack: $this->hydrationStack); } try { - return new \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo\Owner(...$properties); + return new \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Links(...$properties); } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo\Owner', $exception, stack: $this->hydrationStack); + throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Links', $exception, stack: $this->hydrationStack); } } - private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo⚡️Permissions(array $payload): \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo\Permissions + private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Link(array $payload): Link { $properties = []; $missingFields = []; try { - $value = $payload['admin'] ?? null; + $value = $payload['href'] ?? null; if ($value === null) { - $missingFields[] = 'admin'; - goto after_admin; + $missingFields[] = 'href'; + goto after_href; } - $properties['admin'] = $value; + $properties['href'] = $value; - after_admin: - - $value = $payload['maintain'] ?? null; - - if ($value === null) { - $properties['maintain'] = null; - goto after_maintain; - } - - $properties['maintain'] = $value; - - after_maintain: - - $value = $payload['push'] ?? null; - - if ($value === null) { - $missingFields[] = 'push'; - goto after_push; - } - - $properties['push'] = $value; - - after_push: - - $value = $payload['triage'] ?? null; - - if ($value === null) { - $properties['triage'] = null; - goto after_triage; - } - - $properties['triage'] = $value; - - after_triage: - - $value = $payload['pull'] ?? null; - - if ($value === null) { - $missingFields[] = 'pull'; - goto after_pull; - } - - $properties['pull'] = $value; - - after_pull: + after_href: } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo\Permissions', $exception, stack: $this->hydrationStack); + throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\Link', $exception, stack: $this->hydrationStack); } if (count($missingFields) > 0) { - throw UnableToHydrateObject::dueToMissingFields(\ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo\Permissions::class, $missingFields, stack: $this->hydrationStack); + throw UnableToHydrateObject::dueToMissingFields(Link::class, $missingFields, stack: $this->hydrationStack); } try { - return new \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo\Permissions(...$properties); + return new Link(...$properties); } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo\Permissions', $exception, stack: $this->hydrationStack); + throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\Link', $exception, stack: $this->hydrationStack); } } - private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo⚡️License(array $payload): \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo\License + private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️AutoMerge(array $payload): \ApiClients\Client\GitHubEnterpriseCloud\Schema\AutoMerge { $properties = []; $missingFields = []; try { - $value = $payload['key'] ?? null; + $value = $payload['enabled_by'] ?? null; if ($value === null) { - $missingFields[] = 'key'; - goto after_key; + $missingFields[] = 'enabled_by'; + goto after_enabledBy; } - $properties['key'] = $value; - - after_key: - - $value = $payload['name'] ?? null; - - if ($value === null) { - $missingFields[] = 'name'; - goto after_name; + if (is_array($value)) { + try { + $this->hydrationStack[] = 'enabledBy'; + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleUser($value); + } finally { + array_pop($this->hydrationStack); + } } - $properties['name'] = $value; + $properties['enabledBy'] = $value; - after_name: + after_enabledBy: - $value = $payload['url'] ?? null; + $value = $payload['merge_method'] ?? null; if ($value === null) { - $properties['url'] = null; - goto after_url; + $missingFields[] = 'merge_method'; + goto after_mergeMethod; } - $properties['url'] = $value; + $properties['mergeMethod'] = $value; - after_url: + after_mergeMethod: - $value = $payload['spdx_id'] ?? null; + $value = $payload['commit_title'] ?? null; if ($value === null) { - $properties['spdxId'] = null; - goto after_spdxId; + $missingFields[] = 'commit_title'; + goto after_commitTitle; } - $properties['spdxId'] = $value; + $properties['commitTitle'] = $value; - after_spdxId: + after_commitTitle: - $value = $payload['node_id'] ?? null; + $value = $payload['commit_message'] ?? null; if ($value === null) { - $missingFields[] = 'node_id'; - goto after_nodeId; + $missingFields[] = 'commit_message'; + goto after_commitMessage; } - $properties['nodeId'] = $value; + $properties['commitMessage'] = $value; - after_nodeId: + after_commitMessage: } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo\License', $exception, stack: $this->hydrationStack); + throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\AutoMerge', $exception, stack: $this->hydrationStack); } if (count($missingFields) > 0) { - throw UnableToHydrateObject::dueToMissingFields(\ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo\License::class, $missingFields, stack: $this->hydrationStack); + throw UnableToHydrateObject::dueToMissingFields(\ApiClients\Client\GitHubEnterpriseCloud\Schema\AutoMerge::class, $missingFields, stack: $this->hydrationStack); } try { - return new \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo\License(...$properties); + return new \ApiClients\Client\GitHubEnterpriseCloud\Schema\AutoMerge(...$properties); } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo\License', $exception, stack: $this->hydrationStack); + throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\AutoMerge', $exception, stack: $this->hydrationStack); } } - private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️User(array $payload): \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\User + private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️WebhookPullRequestConvertedToDraft(array $payload): WebhookPullRequestConvertedToDraft { $properties = []; $missingFields = []; try { - $value = $payload['avatar_url'] ?? null; + $value = $payload['action'] ?? null; if ($value === null) { - $missingFields[] = 'avatar_url'; - goto after_avatarUrl; + $missingFields[] = 'action'; + goto after_action; } - $properties['avatarUrl'] = $value; + $properties['action'] = $value; - after_avatarUrl: + after_action: - $value = $payload['events_url'] ?? null; + $value = $payload['enterprise'] ?? null; if ($value === null) { - $missingFields[] = 'events_url'; - goto after_eventsUrl; + $properties['enterprise'] = null; + goto after_enterprise; } - $properties['eventsUrl'] = $value; - - after_eventsUrl: - - $value = $payload['followers_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'followers_url'; - goto after_followersUrl; + if (is_array($value)) { + try { + $this->hydrationStack[] = 'enterprise'; + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️EnterpriseWebhooks($value); + } finally { + array_pop($this->hydrationStack); + } } - $properties['followersUrl'] = $value; + $properties['enterprise'] = $value; - after_followersUrl: + after_enterprise: - $value = $payload['following_url'] ?? null; + $value = $payload['installation'] ?? null; if ($value === null) { - $missingFields[] = 'following_url'; - goto after_followingUrl; + $properties['installation'] = null; + goto after_installation; } - $properties['followingUrl'] = $value; - - after_followingUrl: - - $value = $payload['gists_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'gists_url'; - goto after_gistsUrl; + if (is_array($value)) { + try { + $this->hydrationStack[] = 'installation'; + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleInstallation($value); + } finally { + array_pop($this->hydrationStack); + } } - $properties['gistsUrl'] = $value; + $properties['installation'] = $value; - after_gistsUrl: + after_installation: - $value = $payload['gravatar_id'] ?? null; + $value = $payload['number'] ?? null; if ($value === null) { - $properties['gravatarId'] = null; - goto after_gravatarId; + $missingFields[] = 'number'; + goto after_number; } - $properties['gravatarId'] = $value; + $properties['number'] = $value; - after_gravatarId: + after_number: - $value = $payload['html_url'] ?? null; + $value = $payload['organization'] ?? null; if ($value === null) { - $missingFields[] = 'html_url'; - goto after_htmlUrl; + $properties['organization'] = null; + goto after_organization; } - $properties['htmlUrl'] = $value; - - after_htmlUrl: - - $value = $payload['id'] ?? null; - - if ($value === null) { - $missingFields[] = 'id'; - goto after_id; + if (is_array($value)) { + try { + $this->hydrationStack[] = 'organization'; + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️OrganizationSimpleWebhooks($value); + } finally { + array_pop($this->hydrationStack); + } } - $properties['id'] = $value; + $properties['organization'] = $value; - after_id: + after_organization: - $value = $payload['node_id'] ?? null; + $value = $payload['pull_request'] ?? null; if ($value === null) { - $missingFields[] = 'node_id'; - goto after_nodeId; + $missingFields[] = 'pull_request'; + goto after_pullRequest; } - $properties['nodeId'] = $value; - - after_nodeId: - - $value = $payload['login'] ?? null; - - if ($value === null) { - $missingFields[] = 'login'; - goto after_login; + if (is_array($value)) { + try { + $this->hydrationStack[] = 'pullRequest'; + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest($value); + } finally { + array_pop($this->hydrationStack); + } } - $properties['login'] = $value; + $properties['pullRequest'] = $value; - after_login: + after_pullRequest: - $value = $payload['organizations_url'] ?? null; + $value = $payload['repository'] ?? null; if ($value === null) { - $missingFields[] = 'organizations_url'; - goto after_organizationsUrl; + $missingFields[] = 'repository'; + goto after_repository; } - $properties['organizationsUrl'] = $value; - - after_organizationsUrl: - - $value = $payload['received_events_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'received_events_url'; - goto after_receivedEventsUrl; + if (is_array($value)) { + try { + $this->hydrationStack[] = 'repository'; + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️RepositoryWebhooks($value); + } finally { + array_pop($this->hydrationStack); + } } - $properties['receivedEventsUrl'] = $value; + $properties['repository'] = $value; - after_receivedEventsUrl: + after_repository: - $value = $payload['repos_url'] ?? null; + $value = $payload['sender'] ?? null; if ($value === null) { - $missingFields[] = 'repos_url'; - goto after_reposUrl; + $missingFields[] = 'sender'; + goto after_sender; } - $properties['reposUrl'] = $value; - - after_reposUrl: - - $value = $payload['site_admin'] ?? null; - - if ($value === null) { - $missingFields[] = 'site_admin'; - goto after_siteAdmin; + if (is_array($value)) { + try { + $this->hydrationStack[] = 'sender'; + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleUser($value); + } finally { + array_pop($this->hydrationStack); + } } - $properties['siteAdmin'] = $value; - - after_siteAdmin: - - $value = $payload['starred_url'] ?? null; + $properties['sender'] = $value; - if ($value === null) { - $missingFields[] = 'starred_url'; - goto after_starredUrl; - } + after_sender: + } catch (Throwable $exception) { + throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\WebhookPullRequestConvertedToDraft', $exception, stack: $this->hydrationStack); + } - $properties['starredUrl'] = $value; + if (count($missingFields) > 0) { + throw UnableToHydrateObject::dueToMissingFields(WebhookPullRequestConvertedToDraft::class, $missingFields, stack: $this->hydrationStack); + } - after_starredUrl: + try { + return new WebhookPullRequestConvertedToDraft(...$properties); + } catch (Throwable $exception) { + throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\WebhookPullRequestConvertedToDraft', $exception, stack: $this->hydrationStack); + } + } - $value = $payload['subscriptions_url'] ?? null; + private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️WebhookPullRequestDemilestoned(array $payload): WebhookPullRequestDemilestoned + { + $properties = []; + $missingFields = []; + try { + $value = $payload['action'] ?? null; if ($value === null) { - $missingFields[] = 'subscriptions_url'; - goto after_subscriptionsUrl; + $missingFields[] = 'action'; + goto after_action; } - $properties['subscriptionsUrl'] = $value; + $properties['action'] = $value; - after_subscriptionsUrl: + after_action: - $value = $payload['type'] ?? null; + $value = $payload['enterprise'] ?? null; if ($value === null) { - $missingFields[] = 'type'; - goto after_type; + $properties['enterprise'] = null; + goto after_enterprise; } - $properties['type'] = $value; - - after_type: - - $value = $payload['url'] ?? null; - - if ($value === null) { - $missingFields[] = 'url'; - goto after_url; + if (is_array($value)) { + try { + $this->hydrationStack[] = 'enterprise'; + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️EnterpriseWebhooks($value); + } finally { + array_pop($this->hydrationStack); + } } - $properties['url'] = $value; + $properties['enterprise'] = $value; - after_url: + after_enterprise: - $value = $payload['user_view_type'] ?? null; + $value = $payload['milestone'] ?? null; if ($value === null) { - $properties['userViewType'] = null; - goto after_userViewType; + $properties['milestone'] = null; + goto after_milestone; } - $properties['userViewType'] = $value; - - after_userViewType: - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\User', $exception, stack: $this->hydrationStack); - } + if (is_array($value)) { + try { + $this->hydrationStack[] = 'milestone'; + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Milestone($value); + } finally { + array_pop($this->hydrationStack); + } + } - if (count($missingFields) > 0) { - throw UnableToHydrateObject::dueToMissingFields(\ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\User::class, $missingFields, stack: $this->hydrationStack); - } + $properties['milestone'] = $value; - try { - return new \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\User(...$properties); - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\User', $exception, stack: $this->hydrationStack); - } - } + after_milestone: - private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base(array $payload): \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base - { - $properties = []; - $missingFields = []; - try { - $value = $payload['label'] ?? null; + $value = $payload['number'] ?? null; if ($value === null) { - $missingFields[] = 'label'; - goto after_label; + $missingFields[] = 'number'; + goto after_number; } - $properties['label'] = $value; + $properties['number'] = $value; - after_label: + after_number: - $value = $payload['ref'] ?? null; + $value = $payload['organization'] ?? null; if ($value === null) { - $missingFields[] = 'ref'; - goto after_ref; + $properties['organization'] = null; + goto after_organization; } - $properties['ref'] = $value; + if (is_array($value)) { + try { + $this->hydrationStack[] = 'organization'; + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️OrganizationSimpleWebhooks($value); + } finally { + array_pop($this->hydrationStack); + } + } - after_ref: + $properties['organization'] = $value; - $value = $payload['repo'] ?? null; + after_organization: + + $value = $payload['pull_request'] ?? null; if ($value === null) { - $missingFields[] = 'repo'; - goto after_repo; + $missingFields[] = 'pull_request'; + goto after_pullRequest; } if (is_array($value)) { try { - $this->hydrationStack[] = 'repo'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️Repo($value); + $this->hydrationStack[] = 'pullRequest'; + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️WebhooksPullRequest5($value); } finally { array_pop($this->hydrationStack); } } - $properties['repo'] = $value; + $properties['pullRequest'] = $value; - after_repo: + after_pullRequest: - $value = $payload['sha'] ?? null; + $value = $payload['repository'] ?? null; if ($value === null) { - $missingFields[] = 'sha'; - goto after_sha; + $missingFields[] = 'repository'; + goto after_repository; } - $properties['sha'] = $value; + if (is_array($value)) { + try { + $this->hydrationStack[] = 'repository'; + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️RepositoryWebhooks($value); + } finally { + array_pop($this->hydrationStack); + } + } - after_sha: + $properties['repository'] = $value; - $value = $payload['user'] ?? null; + after_repository: + + $value = $payload['sender'] ?? null; if ($value === null) { - $missingFields[] = 'user'; - goto after_user; + $properties['sender'] = null; + goto after_sender; } if (is_array($value)) { try { - $this->hydrationStack[] = 'user'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️User($value); + $this->hydrationStack[] = 'sender'; + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleUser($value); } finally { array_pop($this->hydrationStack); } } - $properties['user'] = $value; + $properties['sender'] = $value; - after_user: + after_sender: } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base', $exception, stack: $this->hydrationStack); + throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\WebhookPullRequestDemilestoned', $exception, stack: $this->hydrationStack); } if (count($missingFields) > 0) { - throw UnableToHydrateObject::dueToMissingFields(\ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base::class, $missingFields, stack: $this->hydrationStack); + throw UnableToHydrateObject::dueToMissingFields(WebhookPullRequestDemilestoned::class, $missingFields, stack: $this->hydrationStack); } try { - return new \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base(...$properties); + return new WebhookPullRequestDemilestoned(...$properties); } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base', $exception, stack: $this->hydrationStack); + throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\WebhookPullRequestDemilestoned', $exception, stack: $this->hydrationStack); } } - private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️Repo(array $payload): \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo + private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️WebhooksPullRequest5(array $payload): WebhooksPullRequest5 { $properties = []; $missingFields = []; try { - $value = $payload['archive_url'] ?? null; + $value = $payload['_links'] ?? null; if ($value === null) { - $missingFields[] = 'archive_url'; - goto after_archiveUrl; + $missingFields[] = '_links'; + goto after_links; } - $properties['archiveUrl'] = $value; + if (is_array($value)) { + try { + $this->hydrationStack[] = 'links'; + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️WebhooksPullRequest5⚡️Links($value); + } finally { + array_pop($this->hydrationStack); + } + } - after_archiveUrl: + $properties['links'] = $value; - $value = $payload['assignees_url'] ?? null; + after_links: + + $value = $payload['active_lock_reason'] ?? null; if ($value === null) { - $missingFields[] = 'assignees_url'; - goto after_assigneesUrl; + $properties['activeLockReason'] = null; + goto after_activeLockReason; } - $properties['assigneesUrl'] = $value; + $properties['activeLockReason'] = $value; - after_assigneesUrl: + after_activeLockReason: - $value = $payload['blobs_url'] ?? null; + $value = $payload['additions'] ?? null; if ($value === null) { - $missingFields[] = 'blobs_url'; - goto after_blobsUrl; + $properties['additions'] = null; + goto after_additions; } - $properties['blobsUrl'] = $value; + $properties['additions'] = $value; - after_blobsUrl: + after_additions: - $value = $payload['branches_url'] ?? null; + $value = $payload['assignee'] ?? null; if ($value === null) { - $missingFields[] = 'branches_url'; - goto after_branchesUrl; + $properties['assignee'] = null; + goto after_assignee; } - $properties['branchesUrl'] = $value; - - after_branchesUrl: - - $value = $payload['collaborators_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'collaborators_url'; - goto after_collaboratorsUrl; + if (is_array($value)) { + try { + $this->hydrationStack[] = 'assignee'; + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️WebhooksPullRequest5⚡️Assignee($value); + } finally { + array_pop($this->hydrationStack); + } } - $properties['collaboratorsUrl'] = $value; + $properties['assignee'] = $value; - after_collaboratorsUrl: + after_assignee: - $value = $payload['comments_url'] ?? null; + $value = $payload['assignees'] ?? null; if ($value === null) { - $missingFields[] = 'comments_url'; - goto after_commentsUrl; + $missingFields[] = 'assignees'; + goto after_assignees; } - $properties['commentsUrl'] = $value; + $properties['assignees'] = $value; - after_commentsUrl: + after_assignees: - $value = $payload['commits_url'] ?? null; + $value = $payload['author_association'] ?? null; if ($value === null) { - $missingFields[] = 'commits_url'; - goto after_commitsUrl; + $missingFields[] = 'author_association'; + goto after_authorAssociation; } - $properties['commitsUrl'] = $value; + $properties['authorAssociation'] = $value; - after_commitsUrl: + after_authorAssociation: - $value = $payload['compare_url'] ?? null; + $value = $payload['auto_merge'] ?? null; if ($value === null) { - $missingFields[] = 'compare_url'; - goto after_compareUrl; + $properties['autoMerge'] = null; + goto after_autoMerge; } - $properties['compareUrl'] = $value; + if (is_array($value)) { + try { + $this->hydrationStack[] = 'autoMerge'; + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️WebhooksPullRequest5⚡️AutoMerge($value); + } finally { + array_pop($this->hydrationStack); + } + } - after_compareUrl: + $properties['autoMerge'] = $value; - $value = $payload['contents_url'] ?? null; + after_autoMerge: + + $value = $payload['base'] ?? null; if ($value === null) { - $missingFields[] = 'contents_url'; - goto after_contentsUrl; + $missingFields[] = 'base'; + goto after_base; } - $properties['contentsUrl'] = $value; + if (is_array($value)) { + try { + $this->hydrationStack[] = 'base'; + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️WebhooksPullRequest5⚡️Base($value); + } finally { + array_pop($this->hydrationStack); + } + } - after_contentsUrl: + $properties['base'] = $value; - $value = $payload['contributors_url'] ?? null; + after_base: + + $value = $payload['body'] ?? null; if ($value === null) { - $missingFields[] = 'contributors_url'; - goto after_contributorsUrl; + $properties['body'] = null; + goto after_body; } - $properties['contributorsUrl'] = $value; + $properties['body'] = $value; - after_contributorsUrl: + after_body: - $value = $payload['deployments_url'] ?? null; + $value = $payload['changed_files'] ?? null; if ($value === null) { - $missingFields[] = 'deployments_url'; - goto after_deploymentsUrl; + $properties['changedFiles'] = null; + goto after_changedFiles; } - $properties['deploymentsUrl'] = $value; + $properties['changedFiles'] = $value; - after_deploymentsUrl: + after_changedFiles: - $value = $payload['description'] ?? null; + $value = $payload['closed_at'] ?? null; if ($value === null) { - $properties['description'] = null; - goto after_description; + $properties['closedAt'] = null; + goto after_closedAt; } - $properties['description'] = $value; + $properties['closedAt'] = $value; - after_description: + after_closedAt: - $value = $payload['downloads_url'] ?? null; + $value = $payload['comments'] ?? null; if ($value === null) { - $missingFields[] = 'downloads_url'; - goto after_downloadsUrl; + $properties['comments'] = null; + goto after_comments; } - $properties['downloadsUrl'] = $value; + $properties['comments'] = $value; - after_downloadsUrl: + after_comments: - $value = $payload['events_url'] ?? null; + $value = $payload['comments_url'] ?? null; if ($value === null) { - $missingFields[] = 'events_url'; - goto after_eventsUrl; + $missingFields[] = 'comments_url'; + goto after_commentsUrl; } - $properties['eventsUrl'] = $value; + $properties['commentsUrl'] = $value; - after_eventsUrl: + after_commentsUrl: - $value = $payload['fork'] ?? null; + $value = $payload['commits'] ?? null; if ($value === null) { - $missingFields[] = 'fork'; - goto after_fork; + $properties['commits'] = null; + goto after_commits; } - $properties['fork'] = $value; + $properties['commits'] = $value; - after_fork: + after_commits: - $value = $payload['forks_url'] ?? null; + $value = $payload['commits_url'] ?? null; if ($value === null) { - $missingFields[] = 'forks_url'; - goto after_forksUrl; + $missingFields[] = 'commits_url'; + goto after_commitsUrl; } - $properties['forksUrl'] = $value; + $properties['commitsUrl'] = $value; - after_forksUrl: + after_commitsUrl: - $value = $payload['full_name'] ?? null; + $value = $payload['created_at'] ?? null; if ($value === null) { - $missingFields[] = 'full_name'; - goto after_fullName; + $missingFields[] = 'created_at'; + goto after_createdAt; } - $properties['fullName'] = $value; + $properties['createdAt'] = $value; - after_fullName: + after_createdAt: - $value = $payload['git_commits_url'] ?? null; + $value = $payload['deletions'] ?? null; if ($value === null) { - $missingFields[] = 'git_commits_url'; - goto after_gitCommitsUrl; + $properties['deletions'] = null; + goto after_deletions; } - $properties['gitCommitsUrl'] = $value; + $properties['deletions'] = $value; - after_gitCommitsUrl: + after_deletions: - $value = $payload['git_refs_url'] ?? null; + $value = $payload['diff_url'] ?? null; if ($value === null) { - $missingFields[] = 'git_refs_url'; - goto after_gitRefsUrl; + $missingFields[] = 'diff_url'; + goto after_diffUrl; } - $properties['gitRefsUrl'] = $value; + $properties['diffUrl'] = $value; - after_gitRefsUrl: + after_diffUrl: - $value = $payload['git_tags_url'] ?? null; + $value = $payload['draft'] ?? null; if ($value === null) { - $missingFields[] = 'git_tags_url'; - goto after_gitTagsUrl; + $missingFields[] = 'draft'; + goto after_draft; } - $properties['gitTagsUrl'] = $value; + $properties['draft'] = $value; - after_gitTagsUrl: + after_draft: - $value = $payload['hooks_url'] ?? null; + $value = $payload['head'] ?? null; if ($value === null) { - $missingFields[] = 'hooks_url'; - goto after_hooksUrl; + $missingFields[] = 'head'; + goto after_head; } - $properties['hooksUrl'] = $value; + if (is_array($value)) { + try { + $this->hydrationStack[] = 'head'; + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️WebhooksPullRequest5⚡️Head($value); + } finally { + array_pop($this->hydrationStack); + } + } - after_hooksUrl: + $properties['head'] = $value; + + after_head: $value = $payload['html_url'] ?? null; @@ -26547,2464 +26758,316 @@ private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️S after_id: - $value = $payload['is_template'] ?? null; - - if ($value === null) { - $properties['isTemplate'] = null; - goto after_isTemplate; - } - - $properties['isTemplate'] = $value; - - after_isTemplate: - - $value = $payload['node_id'] ?? null; + $value = $payload['issue_url'] ?? null; if ($value === null) { - $missingFields[] = 'node_id'; - goto after_nodeId; + $missingFields[] = 'issue_url'; + goto after_issueUrl; } - $properties['nodeId'] = $value; + $properties['issueUrl'] = $value; - after_nodeId: + after_issueUrl: - $value = $payload['issue_comment_url'] ?? null; + $value = $payload['labels'] ?? null; if ($value === null) { - $missingFields[] = 'issue_comment_url'; - goto after_issueCommentUrl; + $missingFields[] = 'labels'; + goto after_labels; } - $properties['issueCommentUrl'] = $value; + $properties['labels'] = $value; - after_issueCommentUrl: + after_labels: - $value = $payload['issue_events_url'] ?? null; + $value = $payload['locked'] ?? null; if ($value === null) { - $missingFields[] = 'issue_events_url'; - goto after_issueEventsUrl; + $missingFields[] = 'locked'; + goto after_locked; } - $properties['issueEventsUrl'] = $value; + $properties['locked'] = $value; - after_issueEventsUrl: + after_locked: - $value = $payload['issues_url'] ?? null; + $value = $payload['maintainer_can_modify'] ?? null; if ($value === null) { - $missingFields[] = 'issues_url'; - goto after_issuesUrl; + $properties['maintainerCanModify'] = null; + goto after_maintainerCanModify; } - $properties['issuesUrl'] = $value; + $properties['maintainerCanModify'] = $value; - after_issuesUrl: + after_maintainerCanModify: - $value = $payload['keys_url'] ?? null; + $value = $payload['merge_commit_sha'] ?? null; if ($value === null) { - $missingFields[] = 'keys_url'; - goto after_keysUrl; + $properties['mergeCommitSha'] = null; + goto after_mergeCommitSha; } - $properties['keysUrl'] = $value; + $properties['mergeCommitSha'] = $value; - after_keysUrl: + after_mergeCommitSha: - $value = $payload['labels_url'] ?? null; + $value = $payload['mergeable'] ?? null; if ($value === null) { - $missingFields[] = 'labels_url'; - goto after_labelsUrl; + $properties['mergeable'] = null; + goto after_mergeable; } - $properties['labelsUrl'] = $value; + $properties['mergeable'] = $value; - after_labelsUrl: + after_mergeable: - $value = $payload['languages_url'] ?? null; + $value = $payload['mergeable_state'] ?? null; if ($value === null) { - $missingFields[] = 'languages_url'; - goto after_languagesUrl; + $properties['mergeableState'] = null; + goto after_mergeableState; } - $properties['languagesUrl'] = $value; + $properties['mergeableState'] = $value; - after_languagesUrl: + after_mergeableState: - $value = $payload['merges_url'] ?? null; + $value = $payload['merged'] ?? null; if ($value === null) { - $missingFields[] = 'merges_url'; - goto after_mergesUrl; + $properties['merged'] = null; + goto after_merged; } - $properties['mergesUrl'] = $value; + $properties['merged'] = $value; - after_mergesUrl: + after_merged: - $value = $payload['milestones_url'] ?? null; + $value = $payload['merged_at'] ?? null; if ($value === null) { - $missingFields[] = 'milestones_url'; - goto after_milestonesUrl; + $properties['mergedAt'] = null; + goto after_mergedAt; } - $properties['milestonesUrl'] = $value; + $properties['mergedAt'] = $value; - after_milestonesUrl: + after_mergedAt: - $value = $payload['name'] ?? null; + $value = $payload['merged_by'] ?? null; if ($value === null) { - $missingFields[] = 'name'; - goto after_name; + $properties['mergedBy'] = null; + goto after_mergedBy; } - $properties['name'] = $value; - - after_name: - - $value = $payload['notifications_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'notifications_url'; - goto after_notificationsUrl; + if (is_array($value)) { + try { + $this->hydrationStack[] = 'mergedBy'; + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️WebhooksPullRequest5⚡️MergedBy($value); + } finally { + array_pop($this->hydrationStack); + } } - $properties['notificationsUrl'] = $value; + $properties['mergedBy'] = $value; - after_notificationsUrl: + after_mergedBy: - $value = $payload['owner'] ?? null; + $value = $payload['milestone'] ?? null; if ($value === null) { - $missingFields[] = 'owner'; - goto after_owner; + $properties['milestone'] = null; + goto after_milestone; } if (is_array($value)) { try { - $this->hydrationStack[] = 'owner'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️Repo⚡️Owner($value); + $this->hydrationStack[] = 'milestone'; + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️WebhooksPullRequest5⚡️Milestone($value); } finally { array_pop($this->hydrationStack); } } - $properties['owner'] = $value; + $properties['milestone'] = $value; - after_owner: + after_milestone: - $value = $payload['private'] ?? null; + $value = $payload['node_id'] ?? null; if ($value === null) { - $missingFields[] = 'private'; - goto after_private; + $missingFields[] = 'node_id'; + goto after_nodeId; } - $properties['private'] = $value; + $properties['nodeId'] = $value; - after_private: + after_nodeId: - $value = $payload['pulls_url'] ?? null; + $value = $payload['number'] ?? null; if ($value === null) { - $missingFields[] = 'pulls_url'; - goto after_pullsUrl; + $missingFields[] = 'number'; + goto after_number; } - $properties['pullsUrl'] = $value; + $properties['number'] = $value; - after_pullsUrl: + after_number: - $value = $payload['releases_url'] ?? null; + $value = $payload['patch_url'] ?? null; if ($value === null) { - $missingFields[] = 'releases_url'; - goto after_releasesUrl; + $missingFields[] = 'patch_url'; + goto after_patchUrl; } - $properties['releasesUrl'] = $value; + $properties['patchUrl'] = $value; - after_releasesUrl: + after_patchUrl: - $value = $payload['stargazers_url'] ?? null; + $value = $payload['rebaseable'] ?? null; if ($value === null) { - $missingFields[] = 'stargazers_url'; - goto after_stargazersUrl; + $properties['rebaseable'] = null; + goto after_rebaseable; } - $properties['stargazersUrl'] = $value; + $properties['rebaseable'] = $value; - after_stargazersUrl: + after_rebaseable: - $value = $payload['statuses_url'] ?? null; + $value = $payload['requested_reviewers'] ?? null; if ($value === null) { - $missingFields[] = 'statuses_url'; - goto after_statusesUrl; + $missingFields[] = 'requested_reviewers'; + goto after_requestedReviewers; } - $properties['statusesUrl'] = $value; + $properties['requestedReviewers'] = $value; - after_statusesUrl: + after_requestedReviewers: - $value = $payload['subscribers_url'] ?? null; + $value = $payload['requested_teams'] ?? null; if ($value === null) { - $missingFields[] = 'subscribers_url'; - goto after_subscribersUrl; + $missingFields[] = 'requested_teams'; + goto after_requestedTeams; } - $properties['subscribersUrl'] = $value; + $properties['requestedTeams'] = $value; - after_subscribersUrl: + after_requestedTeams: - $value = $payload['subscription_url'] ?? null; + $value = $payload['review_comment_url'] ?? null; if ($value === null) { - $missingFields[] = 'subscription_url'; - goto after_subscriptionUrl; + $missingFields[] = 'review_comment_url'; + goto after_reviewCommentUrl; } - $properties['subscriptionUrl'] = $value; + $properties['reviewCommentUrl'] = $value; - after_subscriptionUrl: + after_reviewCommentUrl: - $value = $payload['tags_url'] ?? null; + $value = $payload['review_comments'] ?? null; if ($value === null) { - $missingFields[] = 'tags_url'; - goto after_tagsUrl; + $properties['reviewComments'] = null; + goto after_reviewComments; } - $properties['tagsUrl'] = $value; + $properties['reviewComments'] = $value; - after_tagsUrl: + after_reviewComments: - $value = $payload['teams_url'] ?? null; + $value = $payload['review_comments_url'] ?? null; if ($value === null) { - $missingFields[] = 'teams_url'; - goto after_teamsUrl; + $missingFields[] = 'review_comments_url'; + goto after_reviewCommentsUrl; } - $properties['teamsUrl'] = $value; + $properties['reviewCommentsUrl'] = $value; - after_teamsUrl: + after_reviewCommentsUrl: - $value = $payload['trees_url'] ?? null; + $value = $payload['state'] ?? null; if ($value === null) { - $missingFields[] = 'trees_url'; - goto after_treesUrl; + $missingFields[] = 'state'; + goto after_state; } - $properties['treesUrl'] = $value; + $properties['state'] = $value; - after_treesUrl: + after_state: - $value = $payload['url'] ?? null; + $value = $payload['statuses_url'] ?? null; if ($value === null) { - $missingFields[] = 'url'; - goto after_url; + $missingFields[] = 'statuses_url'; + goto after_statusesUrl; } - $properties['url'] = $value; + $properties['statusesUrl'] = $value; - after_url: + after_statusesUrl: - $value = $payload['clone_url'] ?? null; + $value = $payload['title'] ?? null; if ($value === null) { - $missingFields[] = 'clone_url'; - goto after_cloneUrl; + $missingFields[] = 'title'; + goto after_title; } - $properties['cloneUrl'] = $value; + $properties['title'] = $value; - after_cloneUrl: + after_title: - $value = $payload['default_branch'] ?? null; + $value = $payload['updated_at'] ?? null; if ($value === null) { - $missingFields[] = 'default_branch'; - goto after_defaultBranch; + $missingFields[] = 'updated_at'; + goto after_updatedAt; } - $properties['defaultBranch'] = $value; + $properties['updatedAt'] = $value; - after_defaultBranch: + after_updatedAt: - $value = $payload['forks'] ?? null; + $value = $payload['url'] ?? null; if ($value === null) { - $missingFields[] = 'forks'; - goto after_forks; + $missingFields[] = 'url'; + goto after_url; } - $properties['forks'] = $value; + $properties['url'] = $value; - after_forks: + after_url: - $value = $payload['forks_count'] ?? null; + $value = $payload['user'] ?? null; if ($value === null) { - $missingFields[] = 'forks_count'; - goto after_forksCount; + $properties['user'] = null; + goto after_user; } - $properties['forksCount'] = $value; - - after_forksCount: - - $value = $payload['git_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'git_url'; - goto after_gitUrl; + if (is_array($value)) { + try { + $this->hydrationStack[] = 'user'; + $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️WebhooksPullRequest5⚡️User($value); + } finally { + array_pop($this->hydrationStack); + } } - $properties['gitUrl'] = $value; - - after_gitUrl: - - $value = $payload['has_downloads'] ?? null; - - if ($value === null) { - $missingFields[] = 'has_downloads'; - goto after_hasDownloads; - } - - $properties['hasDownloads'] = $value; - - after_hasDownloads: - - $value = $payload['has_issues'] ?? null; - - if ($value === null) { - $missingFields[] = 'has_issues'; - goto after_hasIssues; - } - - $properties['hasIssues'] = $value; - - after_hasIssues: - - $value = $payload['has_projects'] ?? null; - - if ($value === null) { - $missingFields[] = 'has_projects'; - goto after_hasProjects; - } - - $properties['hasProjects'] = $value; - - after_hasProjects: - - $value = $payload['has_wiki'] ?? null; - - if ($value === null) { - $missingFields[] = 'has_wiki'; - goto after_hasWiki; - } - - $properties['hasWiki'] = $value; - - after_hasWiki: - - $value = $payload['has_pages'] ?? null; - - if ($value === null) { - $missingFields[] = 'has_pages'; - goto after_hasPages; - } - - $properties['hasPages'] = $value; - - after_hasPages: - - $value = $payload['has_discussions'] ?? null; - - if ($value === null) { - $missingFields[] = 'has_discussions'; - goto after_hasDiscussions; - } - - $properties['hasDiscussions'] = $value; - - after_hasDiscussions: - - $value = $payload['homepage'] ?? null; - - if ($value === null) { - $properties['homepage'] = null; - goto after_homepage; - } - - $properties['homepage'] = $value; - - after_homepage: - - $value = $payload['language'] ?? null; - - if ($value === null) { - $properties['language'] = null; - goto after_language; - } - - $properties['language'] = $value; - - after_language: - - $value = $payload['master_branch'] ?? null; - - if ($value === null) { - $properties['masterBranch'] = null; - goto after_masterBranch; - } - - $properties['masterBranch'] = $value; - - after_masterBranch: - - $value = $payload['archived'] ?? null; - - if ($value === null) { - $missingFields[] = 'archived'; - goto after_archived; - } - - $properties['archived'] = $value; - - after_archived: - - $value = $payload['disabled'] ?? null; - - if ($value === null) { - $missingFields[] = 'disabled'; - goto after_disabled; - } - - $properties['disabled'] = $value; - - after_disabled: - - $value = $payload['visibility'] ?? null; - - if ($value === null) { - $properties['visibility'] = null; - goto after_visibility; - } - - $properties['visibility'] = $value; - - after_visibility: - - $value = $payload['mirror_url'] ?? null; - - if ($value === null) { - $properties['mirrorUrl'] = null; - goto after_mirrorUrl; - } - - $properties['mirrorUrl'] = $value; - - after_mirrorUrl: - - $value = $payload['open_issues'] ?? null; - - if ($value === null) { - $missingFields[] = 'open_issues'; - goto after_openIssues; - } - - $properties['openIssues'] = $value; - - after_openIssues: - - $value = $payload['open_issues_count'] ?? null; - - if ($value === null) { - $missingFields[] = 'open_issues_count'; - goto after_openIssuesCount; - } - - $properties['openIssuesCount'] = $value; - - after_openIssuesCount: - - $value = $payload['permissions'] ?? null; - - if ($value === null) { - $properties['permissions'] = null; - goto after_permissions; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'permissions'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️Repo⚡️Permissions($value); - } finally { - array_pop($this->hydrationStack); - } - } - - $properties['permissions'] = $value; - - after_permissions: - - $value = $payload['temp_clone_token'] ?? null; - - if ($value === null) { - $properties['tempCloneToken'] = null; - goto after_tempCloneToken; - } - - $properties['tempCloneToken'] = $value; - - after_tempCloneToken: - - $value = $payload['allow_merge_commit'] ?? null; - - if ($value === null) { - $properties['allowMergeCommit'] = null; - goto after_allowMergeCommit; - } - - $properties['allowMergeCommit'] = $value; - - after_allowMergeCommit: - - $value = $payload['allow_squash_merge'] ?? null; - - if ($value === null) { - $properties['allowSquashMerge'] = null; - goto after_allowSquashMerge; - } - - $properties['allowSquashMerge'] = $value; - - after_allowSquashMerge: - - $value = $payload['allow_rebase_merge'] ?? null; - - if ($value === null) { - $properties['allowRebaseMerge'] = null; - goto after_allowRebaseMerge; - } - - $properties['allowRebaseMerge'] = $value; - - after_allowRebaseMerge: - - $value = $payload['license'] ?? null; - - if ($value === null) { - $properties['license'] = null; - goto after_license; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'license'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️LicenseSimple($value); - } finally { - array_pop($this->hydrationStack); - } - } - - $properties['license'] = $value; - - after_license: - - $value = $payload['pushed_at'] ?? null; - - if ($value === null) { - $missingFields[] = 'pushed_at'; - goto after_pushedAt; - } - - $properties['pushedAt'] = $value; - - after_pushedAt: - - $value = $payload['size'] ?? null; - - if ($value === null) { - $missingFields[] = 'size'; - goto after_size; - } - - $properties['size'] = $value; - - after_size: - - $value = $payload['ssh_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'ssh_url'; - goto after_sshUrl; - } - - $properties['sshUrl'] = $value; - - after_sshUrl: - - $value = $payload['stargazers_count'] ?? null; - - if ($value === null) { - $missingFields[] = 'stargazers_count'; - goto after_stargazersCount; - } - - $properties['stargazersCount'] = $value; - - after_stargazersCount: - - $value = $payload['svn_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'svn_url'; - goto after_svnUrl; - } - - $properties['svnUrl'] = $value; - - after_svnUrl: - - $value = $payload['topics'] ?? null; - - if ($value === null) { - $properties['topics'] = null; - goto after_topics; - } - - $properties['topics'] = $value; - - after_topics: - - $value = $payload['watchers'] ?? null; - - if ($value === null) { - $missingFields[] = 'watchers'; - goto after_watchers; - } - - $properties['watchers'] = $value; - - after_watchers: - - $value = $payload['watchers_count'] ?? null; - - if ($value === null) { - $missingFields[] = 'watchers_count'; - goto after_watchersCount; - } - - $properties['watchersCount'] = $value; - - after_watchersCount: - - $value = $payload['created_at'] ?? null; - - if ($value === null) { - $missingFields[] = 'created_at'; - goto after_createdAt; - } - - $properties['createdAt'] = $value; - - after_createdAt: - - $value = $payload['updated_at'] ?? null; - - if ($value === null) { - $missingFields[] = 'updated_at'; - goto after_updatedAt; - } - - $properties['updatedAt'] = $value; - - after_updatedAt: - - $value = $payload['allow_forking'] ?? null; - - if ($value === null) { - $properties['allowForking'] = null; - goto after_allowForking; - } - - $properties['allowForking'] = $value; - - after_allowForking: - - $value = $payload['web_commit_signoff_required'] ?? null; - - if ($value === null) { - $properties['webCommitSignoffRequired'] = null; - goto after_webCommitSignoffRequired; - } - - $properties['webCommitSignoffRequired'] = $value; - - after_webCommitSignoffRequired: - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo', $exception, stack: $this->hydrationStack); - } - - if (count($missingFields) > 0) { - throw UnableToHydrateObject::dueToMissingFields(\ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo::class, $missingFields, stack: $this->hydrationStack); - } - - try { - return new \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo(...$properties); - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo', $exception, stack: $this->hydrationStack); - } - } - - private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️Repo⚡️Owner(array $payload): \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo\Owner - { - $properties = []; - $missingFields = []; - try { - $value = $payload['avatar_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'avatar_url'; - goto after_avatarUrl; - } - - $properties['avatarUrl'] = $value; - - after_avatarUrl: - - $value = $payload['events_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'events_url'; - goto after_eventsUrl; - } - - $properties['eventsUrl'] = $value; - - after_eventsUrl: - - $value = $payload['followers_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'followers_url'; - goto after_followersUrl; - } - - $properties['followersUrl'] = $value; - - after_followersUrl: - - $value = $payload['following_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'following_url'; - goto after_followingUrl; - } - - $properties['followingUrl'] = $value; - - after_followingUrl: - - $value = $payload['gists_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'gists_url'; - goto after_gistsUrl; - } - - $properties['gistsUrl'] = $value; - - after_gistsUrl: - - $value = $payload['gravatar_id'] ?? null; - - if ($value === null) { - $properties['gravatarId'] = null; - goto after_gravatarId; - } - - $properties['gravatarId'] = $value; - - after_gravatarId: - - $value = $payload['html_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'html_url'; - goto after_htmlUrl; - } - - $properties['htmlUrl'] = $value; - - after_htmlUrl: - - $value = $payload['id'] ?? null; - - if ($value === null) { - $missingFields[] = 'id'; - goto after_id; - } - - $properties['id'] = $value; - - after_id: - - $value = $payload['node_id'] ?? null; - - if ($value === null) { - $missingFields[] = 'node_id'; - goto after_nodeId; - } - - $properties['nodeId'] = $value; - - after_nodeId: - - $value = $payload['login'] ?? null; - - if ($value === null) { - $missingFields[] = 'login'; - goto after_login; - } - - $properties['login'] = $value; - - after_login: - - $value = $payload['organizations_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'organizations_url'; - goto after_organizationsUrl; - } - - $properties['organizationsUrl'] = $value; - - after_organizationsUrl: - - $value = $payload['received_events_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'received_events_url'; - goto after_receivedEventsUrl; - } - - $properties['receivedEventsUrl'] = $value; - - after_receivedEventsUrl: - - $value = $payload['repos_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'repos_url'; - goto after_reposUrl; - } - - $properties['reposUrl'] = $value; - - after_reposUrl: - - $value = $payload['site_admin'] ?? null; - - if ($value === null) { - $missingFields[] = 'site_admin'; - goto after_siteAdmin; - } - - $properties['siteAdmin'] = $value; - - after_siteAdmin: - - $value = $payload['starred_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'starred_url'; - goto after_starredUrl; - } - - $properties['starredUrl'] = $value; - - after_starredUrl: - - $value = $payload['subscriptions_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'subscriptions_url'; - goto after_subscriptionsUrl; - } - - $properties['subscriptionsUrl'] = $value; - - after_subscriptionsUrl: - - $value = $payload['type'] ?? null; - - if ($value === null) { - $missingFields[] = 'type'; - goto after_type; - } - - $properties['type'] = $value; - - after_type: - - $value = $payload['url'] ?? null; - - if ($value === null) { - $missingFields[] = 'url'; - goto after_url; - } - - $properties['url'] = $value; - - after_url: - - $value = $payload['user_view_type'] ?? null; - - if ($value === null) { - $properties['userViewType'] = null; - goto after_userViewType; - } - - $properties['userViewType'] = $value; - - after_userViewType: - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo\Owner', $exception, stack: $this->hydrationStack); - } - - if (count($missingFields) > 0) { - throw UnableToHydrateObject::dueToMissingFields(\ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo\Owner::class, $missingFields, stack: $this->hydrationStack); - } - - try { - return new \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo\Owner(...$properties); - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo\Owner', $exception, stack: $this->hydrationStack); - } - } - - private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️Repo⚡️Permissions(array $payload): \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo\Permissions - { - $properties = []; - $missingFields = []; - try { - $value = $payload['admin'] ?? null; - - if ($value === null) { - $missingFields[] = 'admin'; - goto after_admin; - } - - $properties['admin'] = $value; - - after_admin: - - $value = $payload['maintain'] ?? null; - - if ($value === null) { - $properties['maintain'] = null; - goto after_maintain; - } - - $properties['maintain'] = $value; - - after_maintain: - - $value = $payload['push'] ?? null; - - if ($value === null) { - $missingFields[] = 'push'; - goto after_push; - } - - $properties['push'] = $value; - - after_push: - - $value = $payload['triage'] ?? null; - - if ($value === null) { - $properties['triage'] = null; - goto after_triage; - } - - $properties['triage'] = $value; - - after_triage: - - $value = $payload['pull'] ?? null; - - if ($value === null) { - $missingFields[] = 'pull'; - goto after_pull; - } - - $properties['pull'] = $value; - - after_pull: - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo\Permissions', $exception, stack: $this->hydrationStack); - } - - if (count($missingFields) > 0) { - throw UnableToHydrateObject::dueToMissingFields(\ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo\Permissions::class, $missingFields, stack: $this->hydrationStack); - } - - try { - return new \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo\Permissions(...$properties); - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo\Permissions', $exception, stack: $this->hydrationStack); - } - } - - private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️User(array $payload): \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\User - { - $properties = []; - $missingFields = []; - try { - $value = $payload['avatar_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'avatar_url'; - goto after_avatarUrl; - } - - $properties['avatarUrl'] = $value; - - after_avatarUrl: - - $value = $payload['events_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'events_url'; - goto after_eventsUrl; - } - - $properties['eventsUrl'] = $value; - - after_eventsUrl: - - $value = $payload['followers_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'followers_url'; - goto after_followersUrl; - } - - $properties['followersUrl'] = $value; - - after_followersUrl: - - $value = $payload['following_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'following_url'; - goto after_followingUrl; - } - - $properties['followingUrl'] = $value; - - after_followingUrl: - - $value = $payload['gists_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'gists_url'; - goto after_gistsUrl; - } - - $properties['gistsUrl'] = $value; - - after_gistsUrl: - - $value = $payload['gravatar_id'] ?? null; - - if ($value === null) { - $properties['gravatarId'] = null; - goto after_gravatarId; - } - - $properties['gravatarId'] = $value; - - after_gravatarId: - - $value = $payload['html_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'html_url'; - goto after_htmlUrl; - } - - $properties['htmlUrl'] = $value; - - after_htmlUrl: - - $value = $payload['id'] ?? null; - - if ($value === null) { - $missingFields[] = 'id'; - goto after_id; - } - - $properties['id'] = $value; - - after_id: - - $value = $payload['node_id'] ?? null; - - if ($value === null) { - $missingFields[] = 'node_id'; - goto after_nodeId; - } - - $properties['nodeId'] = $value; - - after_nodeId: - - $value = $payload['login'] ?? null; - - if ($value === null) { - $missingFields[] = 'login'; - goto after_login; - } - - $properties['login'] = $value; - - after_login: - - $value = $payload['organizations_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'organizations_url'; - goto after_organizationsUrl; - } - - $properties['organizationsUrl'] = $value; - - after_organizationsUrl: - - $value = $payload['received_events_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'received_events_url'; - goto after_receivedEventsUrl; - } - - $properties['receivedEventsUrl'] = $value; - - after_receivedEventsUrl: - - $value = $payload['repos_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'repos_url'; - goto after_reposUrl; - } - - $properties['reposUrl'] = $value; - - after_reposUrl: - - $value = $payload['site_admin'] ?? null; - - if ($value === null) { - $missingFields[] = 'site_admin'; - goto after_siteAdmin; - } - - $properties['siteAdmin'] = $value; - - after_siteAdmin: - - $value = $payload['starred_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'starred_url'; - goto after_starredUrl; - } - - $properties['starredUrl'] = $value; - - after_starredUrl: - - $value = $payload['subscriptions_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'subscriptions_url'; - goto after_subscriptionsUrl; - } - - $properties['subscriptionsUrl'] = $value; - - after_subscriptionsUrl: - - $value = $payload['type'] ?? null; - - if ($value === null) { - $missingFields[] = 'type'; - goto after_type; - } - - $properties['type'] = $value; - - after_type: - - $value = $payload['url'] ?? null; - - if ($value === null) { - $missingFields[] = 'url'; - goto after_url; - } - - $properties['url'] = $value; - - after_url: - - $value = $payload['user_view_type'] ?? null; - - if ($value === null) { - $properties['userViewType'] = null; - goto after_userViewType; - } - - $properties['userViewType'] = $value; - - after_userViewType: - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\User', $exception, stack: $this->hydrationStack); - } - - if (count($missingFields) > 0) { - throw UnableToHydrateObject::dueToMissingFields(\ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\User::class, $missingFields, stack: $this->hydrationStack); - } - - try { - return new \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\User(...$properties); - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\User', $exception, stack: $this->hydrationStack); - } - } - - private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Links(array $payload): \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Links - { - $properties = []; - $missingFields = []; - try { - $value = $payload['comments'] ?? null; - - if ($value === null) { - $missingFields[] = 'comments'; - goto after_comments; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'comments'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Link($value); - } finally { - array_pop($this->hydrationStack); - } - } - - $properties['comments'] = $value; - - after_comments: - - $value = $payload['commits'] ?? null; - - if ($value === null) { - $missingFields[] = 'commits'; - goto after_commits; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'commits'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Link($value); - } finally { - array_pop($this->hydrationStack); - } - } - - $properties['commits'] = $value; - - after_commits: - - $value = $payload['statuses'] ?? null; - - if ($value === null) { - $missingFields[] = 'statuses'; - goto after_statuses; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'statuses'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Link($value); - } finally { - array_pop($this->hydrationStack); - } - } - - $properties['statuses'] = $value; - - after_statuses: - - $value = $payload['html'] ?? null; - - if ($value === null) { - $missingFields[] = 'html'; - goto after_html; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'html'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Link($value); - } finally { - array_pop($this->hydrationStack); - } - } - - $properties['html'] = $value; - - after_html: - - $value = $payload['issue'] ?? null; - - if ($value === null) { - $missingFields[] = 'issue'; - goto after_issue; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'issue'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Link($value); - } finally { - array_pop($this->hydrationStack); - } - } - - $properties['issue'] = $value; - - after_issue: - - $value = $payload['review_comments'] ?? null; - - if ($value === null) { - $missingFields[] = 'review_comments'; - goto after_reviewComments; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'reviewComments'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Link($value); - } finally { - array_pop($this->hydrationStack); - } - } - - $properties['reviewComments'] = $value; - - after_reviewComments: - - $value = $payload['review_comment'] ?? null; - - if ($value === null) { - $missingFields[] = 'review_comment'; - goto after_reviewComment; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'reviewComment'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Link($value); - } finally { - array_pop($this->hydrationStack); - } - } - - $properties['reviewComment'] = $value; - - after_reviewComment: - - $value = $payload['self'] ?? null; - - if ($value === null) { - $missingFields[] = 'self'; - goto after_self; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'self'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Link($value); - } finally { - array_pop($this->hydrationStack); - } - } - - $properties['self'] = $value; - - after_self: - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Links', $exception, stack: $this->hydrationStack); - } - - if (count($missingFields) > 0) { - throw UnableToHydrateObject::dueToMissingFields(\ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Links::class, $missingFields, stack: $this->hydrationStack); - } - - try { - return new \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Links(...$properties); - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Links', $exception, stack: $this->hydrationStack); - } - } - - private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Link(array $payload): Link - { - $properties = []; - $missingFields = []; - try { - $value = $payload['href'] ?? null; - - if ($value === null) { - $missingFields[] = 'href'; - goto after_href; - } - - $properties['href'] = $value; - - after_href: - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\Link', $exception, stack: $this->hydrationStack); - } - - if (count($missingFields) > 0) { - throw UnableToHydrateObject::dueToMissingFields(Link::class, $missingFields, stack: $this->hydrationStack); - } - - try { - return new Link(...$properties); - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\Link', $exception, stack: $this->hydrationStack); - } - } - - private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️AutoMerge(array $payload): \ApiClients\Client\GitHubEnterpriseCloud\Schema\AutoMerge - { - $properties = []; - $missingFields = []; - try { - $value = $payload['enabled_by'] ?? null; - - if ($value === null) { - $missingFields[] = 'enabled_by'; - goto after_enabledBy; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'enabledBy'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleUser($value); - } finally { - array_pop($this->hydrationStack); - } - } - - $properties['enabledBy'] = $value; - - after_enabledBy: - - $value = $payload['merge_method'] ?? null; - - if ($value === null) { - $missingFields[] = 'merge_method'; - goto after_mergeMethod; - } - - $properties['mergeMethod'] = $value; - - after_mergeMethod: - - $value = $payload['commit_title'] ?? null; - - if ($value === null) { - $missingFields[] = 'commit_title'; - goto after_commitTitle; - } - - $properties['commitTitle'] = $value; - - after_commitTitle: - - $value = $payload['commit_message'] ?? null; - - if ($value === null) { - $missingFields[] = 'commit_message'; - goto after_commitMessage; - } - - $properties['commitMessage'] = $value; - - after_commitMessage: - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\AutoMerge', $exception, stack: $this->hydrationStack); - } - - if (count($missingFields) > 0) { - throw UnableToHydrateObject::dueToMissingFields(\ApiClients\Client\GitHubEnterpriseCloud\Schema\AutoMerge::class, $missingFields, stack: $this->hydrationStack); - } - - try { - return new \ApiClients\Client\GitHubEnterpriseCloud\Schema\AutoMerge(...$properties); - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\AutoMerge', $exception, stack: $this->hydrationStack); - } - } - - private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️WebhookPullRequestConvertedToDraft(array $payload): WebhookPullRequestConvertedToDraft - { - $properties = []; - $missingFields = []; - try { - $value = $payload['action'] ?? null; - - if ($value === null) { - $missingFields[] = 'action'; - goto after_action; - } - - $properties['action'] = $value; - - after_action: - - $value = $payload['enterprise'] ?? null; - - if ($value === null) { - $properties['enterprise'] = null; - goto after_enterprise; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'enterprise'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️EnterpriseWebhooks($value); - } finally { - array_pop($this->hydrationStack); - } - } - - $properties['enterprise'] = $value; - - after_enterprise: - - $value = $payload['installation'] ?? null; - - if ($value === null) { - $properties['installation'] = null; - goto after_installation; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'installation'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleInstallation($value); - } finally { - array_pop($this->hydrationStack); - } - } - - $properties['installation'] = $value; - - after_installation: - - $value = $payload['number'] ?? null; - - if ($value === null) { - $missingFields[] = 'number'; - goto after_number; - } - - $properties['number'] = $value; - - after_number: - - $value = $payload['organization'] ?? null; - - if ($value === null) { - $properties['organization'] = null; - goto after_organization; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'organization'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️OrganizationSimpleWebhooks($value); - } finally { - array_pop($this->hydrationStack); - } - } - - $properties['organization'] = $value; - - after_organization: - - $value = $payload['pull_request'] ?? null; - - if ($value === null) { - $missingFields[] = 'pull_request'; - goto after_pullRequest; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'pullRequest'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest($value); - } finally { - array_pop($this->hydrationStack); - } - } - - $properties['pullRequest'] = $value; - - after_pullRequest: - - $value = $payload['repository'] ?? null; - - if ($value === null) { - $missingFields[] = 'repository'; - goto after_repository; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'repository'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️RepositoryWebhooks($value); - } finally { - array_pop($this->hydrationStack); - } - } - - $properties['repository'] = $value; - - after_repository: - - $value = $payload['sender'] ?? null; - - if ($value === null) { - $missingFields[] = 'sender'; - goto after_sender; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'sender'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleUser($value); - } finally { - array_pop($this->hydrationStack); - } - } - - $properties['sender'] = $value; - - after_sender: - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\WebhookPullRequestConvertedToDraft', $exception, stack: $this->hydrationStack); - } - - if (count($missingFields) > 0) { - throw UnableToHydrateObject::dueToMissingFields(WebhookPullRequestConvertedToDraft::class, $missingFields, stack: $this->hydrationStack); - } - - try { - return new WebhookPullRequestConvertedToDraft(...$properties); - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\WebhookPullRequestConvertedToDraft', $exception, stack: $this->hydrationStack); - } - } - - private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️WebhookPullRequestDemilestoned(array $payload): WebhookPullRequestDemilestoned - { - $properties = []; - $missingFields = []; - try { - $value = $payload['action'] ?? null; - - if ($value === null) { - $missingFields[] = 'action'; - goto after_action; - } - - $properties['action'] = $value; - - after_action: - - $value = $payload['enterprise'] ?? null; - - if ($value === null) { - $properties['enterprise'] = null; - goto after_enterprise; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'enterprise'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️EnterpriseWebhooks($value); - } finally { - array_pop($this->hydrationStack); - } - } - - $properties['enterprise'] = $value; - - after_enterprise: - - $value = $payload['milestone'] ?? null; - - if ($value === null) { - $properties['milestone'] = null; - goto after_milestone; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'milestone'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Milestone($value); - } finally { - array_pop($this->hydrationStack); - } - } - - $properties['milestone'] = $value; - - after_milestone: - - $value = $payload['number'] ?? null; - - if ($value === null) { - $missingFields[] = 'number'; - goto after_number; - } - - $properties['number'] = $value; - - after_number: - - $value = $payload['organization'] ?? null; - - if ($value === null) { - $properties['organization'] = null; - goto after_organization; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'organization'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️OrganizationSimpleWebhooks($value); - } finally { - array_pop($this->hydrationStack); - } - } - - $properties['organization'] = $value; - - after_organization: - - $value = $payload['pull_request'] ?? null; - - if ($value === null) { - $missingFields[] = 'pull_request'; - goto after_pullRequest; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'pullRequest'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️WebhooksPullRequest5($value); - } finally { - array_pop($this->hydrationStack); - } - } - - $properties['pullRequest'] = $value; - - after_pullRequest: - - $value = $payload['repository'] ?? null; - - if ($value === null) { - $missingFields[] = 'repository'; - goto after_repository; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'repository'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️RepositoryWebhooks($value); - } finally { - array_pop($this->hydrationStack); - } - } - - $properties['repository'] = $value; - - after_repository: - - $value = $payload['sender'] ?? null; - - if ($value === null) { - $properties['sender'] = null; - goto after_sender; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'sender'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleUser($value); - } finally { - array_pop($this->hydrationStack); - } - } - - $properties['sender'] = $value; - - after_sender: - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\WebhookPullRequestDemilestoned', $exception, stack: $this->hydrationStack); - } - - if (count($missingFields) > 0) { - throw UnableToHydrateObject::dueToMissingFields(WebhookPullRequestDemilestoned::class, $missingFields, stack: $this->hydrationStack); - } - - try { - return new WebhookPullRequestDemilestoned(...$properties); - } catch (Throwable $exception) { - throw UnableToHydrateObject::dueToError('ApiClients\Client\GitHubEnterpriseCloud\Schema\WebhookPullRequestDemilestoned', $exception, stack: $this->hydrationStack); - } - } - - private function hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️WebhooksPullRequest5(array $payload): WebhooksPullRequest5 - { - $properties = []; - $missingFields = []; - try { - $value = $payload['_links'] ?? null; - - if ($value === null) { - $missingFields[] = '_links'; - goto after_links; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'links'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️WebhooksPullRequest5⚡️Links($value); - } finally { - array_pop($this->hydrationStack); - } - } - - $properties['links'] = $value; - - after_links: - - $value = $payload['active_lock_reason'] ?? null; - - if ($value === null) { - $properties['activeLockReason'] = null; - goto after_activeLockReason; - } - - $properties['activeLockReason'] = $value; - - after_activeLockReason: - - $value = $payload['additions'] ?? null; - - if ($value === null) { - $properties['additions'] = null; - goto after_additions; - } - - $properties['additions'] = $value; - - after_additions: - - $value = $payload['assignee'] ?? null; - - if ($value === null) { - $properties['assignee'] = null; - goto after_assignee; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'assignee'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️WebhooksPullRequest5⚡️Assignee($value); - } finally { - array_pop($this->hydrationStack); - } - } - - $properties['assignee'] = $value; - - after_assignee: - - $value = $payload['assignees'] ?? null; - - if ($value === null) { - $missingFields[] = 'assignees'; - goto after_assignees; - } - - $properties['assignees'] = $value; - - after_assignees: - - $value = $payload['author_association'] ?? null; - - if ($value === null) { - $missingFields[] = 'author_association'; - goto after_authorAssociation; - } - - $properties['authorAssociation'] = $value; - - after_authorAssociation: - - $value = $payload['auto_merge'] ?? null; - - if ($value === null) { - $properties['autoMerge'] = null; - goto after_autoMerge; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'autoMerge'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️WebhooksPullRequest5⚡️AutoMerge($value); - } finally { - array_pop($this->hydrationStack); - } - } - - $properties['autoMerge'] = $value; - - after_autoMerge: - - $value = $payload['base'] ?? null; - - if ($value === null) { - $missingFields[] = 'base'; - goto after_base; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'base'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️WebhooksPullRequest5⚡️Base($value); - } finally { - array_pop($this->hydrationStack); - } - } - - $properties['base'] = $value; - - after_base: - - $value = $payload['body'] ?? null; - - if ($value === null) { - $properties['body'] = null; - goto after_body; - } - - $properties['body'] = $value; - - after_body: - - $value = $payload['changed_files'] ?? null; - - if ($value === null) { - $properties['changedFiles'] = null; - goto after_changedFiles; - } - - $properties['changedFiles'] = $value; - - after_changedFiles: - - $value = $payload['closed_at'] ?? null; - - if ($value === null) { - $properties['closedAt'] = null; - goto after_closedAt; - } - - $properties['closedAt'] = $value; - - after_closedAt: - - $value = $payload['comments'] ?? null; - - if ($value === null) { - $properties['comments'] = null; - goto after_comments; - } - - $properties['comments'] = $value; - - after_comments: - - $value = $payload['comments_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'comments_url'; - goto after_commentsUrl; - } - - $properties['commentsUrl'] = $value; - - after_commentsUrl: - - $value = $payload['commits'] ?? null; - - if ($value === null) { - $properties['commits'] = null; - goto after_commits; - } - - $properties['commits'] = $value; - - after_commits: - - $value = $payload['commits_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'commits_url'; - goto after_commitsUrl; - } - - $properties['commitsUrl'] = $value; - - after_commitsUrl: - - $value = $payload['created_at'] ?? null; - - if ($value === null) { - $missingFields[] = 'created_at'; - goto after_createdAt; - } - - $properties['createdAt'] = $value; - - after_createdAt: - - $value = $payload['deletions'] ?? null; - - if ($value === null) { - $properties['deletions'] = null; - goto after_deletions; - } - - $properties['deletions'] = $value; - - after_deletions: - - $value = $payload['diff_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'diff_url'; - goto after_diffUrl; - } - - $properties['diffUrl'] = $value; - - after_diffUrl: - - $value = $payload['draft'] ?? null; - - if ($value === null) { - $missingFields[] = 'draft'; - goto after_draft; - } - - $properties['draft'] = $value; - - after_draft: - - $value = $payload['head'] ?? null; - - if ($value === null) { - $missingFields[] = 'head'; - goto after_head; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'head'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️WebhooksPullRequest5⚡️Head($value); - } finally { - array_pop($this->hydrationStack); - } - } - - $properties['head'] = $value; - - after_head: - - $value = $payload['html_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'html_url'; - goto after_htmlUrl; - } - - $properties['htmlUrl'] = $value; - - after_htmlUrl: - - $value = $payload['id'] ?? null; - - if ($value === null) { - $missingFields[] = 'id'; - goto after_id; - } - - $properties['id'] = $value; - - after_id: - - $value = $payload['issue_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'issue_url'; - goto after_issueUrl; - } - - $properties['issueUrl'] = $value; - - after_issueUrl: - - $value = $payload['labels'] ?? null; - - if ($value === null) { - $missingFields[] = 'labels'; - goto after_labels; - } - - $properties['labels'] = $value; - - after_labels: - - $value = $payload['locked'] ?? null; - - if ($value === null) { - $missingFields[] = 'locked'; - goto after_locked; - } - - $properties['locked'] = $value; - - after_locked: - - $value = $payload['maintainer_can_modify'] ?? null; - - if ($value === null) { - $properties['maintainerCanModify'] = null; - goto after_maintainerCanModify; - } - - $properties['maintainerCanModify'] = $value; - - after_maintainerCanModify: - - $value = $payload['merge_commit_sha'] ?? null; - - if ($value === null) { - $properties['mergeCommitSha'] = null; - goto after_mergeCommitSha; - } - - $properties['mergeCommitSha'] = $value; - - after_mergeCommitSha: - - $value = $payload['mergeable'] ?? null; - - if ($value === null) { - $properties['mergeable'] = null; - goto after_mergeable; - } - - $properties['mergeable'] = $value; - - after_mergeable: - - $value = $payload['mergeable_state'] ?? null; - - if ($value === null) { - $properties['mergeableState'] = null; - goto after_mergeableState; - } - - $properties['mergeableState'] = $value; - - after_mergeableState: - - $value = $payload['merged'] ?? null; - - if ($value === null) { - $properties['merged'] = null; - goto after_merged; - } - - $properties['merged'] = $value; - - after_merged: - - $value = $payload['merged_at'] ?? null; - - if ($value === null) { - $properties['mergedAt'] = null; - goto after_mergedAt; - } - - $properties['mergedAt'] = $value; - - after_mergedAt: - - $value = $payload['merged_by'] ?? null; - - if ($value === null) { - $properties['mergedBy'] = null; - goto after_mergedBy; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'mergedBy'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️WebhooksPullRequest5⚡️MergedBy($value); - } finally { - array_pop($this->hydrationStack); - } - } - - $properties['mergedBy'] = $value; - - after_mergedBy: - - $value = $payload['milestone'] ?? null; - - if ($value === null) { - $properties['milestone'] = null; - goto after_milestone; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'milestone'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️WebhooksPullRequest5⚡️Milestone($value); - } finally { - array_pop($this->hydrationStack); - } - } - - $properties['milestone'] = $value; - - after_milestone: - - $value = $payload['node_id'] ?? null; - - if ($value === null) { - $missingFields[] = 'node_id'; - goto after_nodeId; - } - - $properties['nodeId'] = $value; - - after_nodeId: - - $value = $payload['number'] ?? null; - - if ($value === null) { - $missingFields[] = 'number'; - goto after_number; - } - - $properties['number'] = $value; - - after_number: - - $value = $payload['patch_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'patch_url'; - goto after_patchUrl; - } - - $properties['patchUrl'] = $value; - - after_patchUrl: - - $value = $payload['rebaseable'] ?? null; - - if ($value === null) { - $properties['rebaseable'] = null; - goto after_rebaseable; - } - - $properties['rebaseable'] = $value; - - after_rebaseable: - - $value = $payload['requested_reviewers'] ?? null; - - if ($value === null) { - $missingFields[] = 'requested_reviewers'; - goto after_requestedReviewers; - } - - $properties['requestedReviewers'] = $value; - - after_requestedReviewers: - - $value = $payload['requested_teams'] ?? null; - - if ($value === null) { - $missingFields[] = 'requested_teams'; - goto after_requestedTeams; - } - - $properties['requestedTeams'] = $value; - - after_requestedTeams: - - $value = $payload['review_comment_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'review_comment_url'; - goto after_reviewCommentUrl; - } - - $properties['reviewCommentUrl'] = $value; - - after_reviewCommentUrl: - - $value = $payload['review_comments'] ?? null; - - if ($value === null) { - $properties['reviewComments'] = null; - goto after_reviewComments; - } - - $properties['reviewComments'] = $value; - - after_reviewComments: - - $value = $payload['review_comments_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'review_comments_url'; - goto after_reviewCommentsUrl; - } - - $properties['reviewCommentsUrl'] = $value; - - after_reviewCommentsUrl: - - $value = $payload['state'] ?? null; - - if ($value === null) { - $missingFields[] = 'state'; - goto after_state; - } - - $properties['state'] = $value; - - after_state: - - $value = $payload['statuses_url'] ?? null; - - if ($value === null) { - $missingFields[] = 'statuses_url'; - goto after_statusesUrl; - } - - $properties['statusesUrl'] = $value; - - after_statusesUrl: - - $value = $payload['title'] ?? null; - - if ($value === null) { - $missingFields[] = 'title'; - goto after_title; - } - - $properties['title'] = $value; - - after_title: - - $value = $payload['updated_at'] ?? null; - - if ($value === null) { - $missingFields[] = 'updated_at'; - goto after_updatedAt; - } - - $properties['updatedAt'] = $value; - - after_updatedAt: - - $value = $payload['url'] ?? null; - - if ($value === null) { - $missingFields[] = 'url'; - goto after_url; - } - - $properties['url'] = $value; - - after_url: - - $value = $payload['user'] ?? null; - - if ($value === null) { - $properties['user'] = null; - goto after_user; - } - - if (is_array($value)) { - try { - $this->hydrationStack[] = 'user'; - $value = $this->hydrateApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️WebhooksPullRequest5⚡️User($value); - } finally { - array_pop($this->hydrationStack); - } - } - - $properties['user'] = $value; + $properties['user'] = $value; after_user: } catch (Throwable $exception) { @@ -90649,16 +88712,9 @@ public function serializeObjectOfType(object $object, string $className): mixed 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest($object), 'ApiClients\Client\GitHubEnterpriseCloud\Schema\Milestone' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Milestone($object), 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head($object), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo($object), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo\Owner' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo⚡️Owner($object), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo\Permissions' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo⚡️Permissions($object), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo\License' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo⚡️License($object), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\User' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️User($object), + 'ApiClients\Client\GitHubEnterpriseCloud\Schema\Repository' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Repository($object), + 'ApiClients\Client\GitHubEnterpriseCloud\Schema\Repository\Permissions' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Repository⚡️Permissions($object), 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base($object), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️Repo($object), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo\Owner' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️Repo⚡️Owner($object), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo\Permissions' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️Repo⚡️Permissions($object), - 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\User' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️User($object), 'ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Links' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Links($object), 'ApiClients\Client\GitHubEnterpriseCloud\Schema\Link' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Link($object), 'ApiClients\Client\GitHubEnterpriseCloud\Schema\AutoMerge' => $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️AutoMerge($object), @@ -101343,610 +99399,237 @@ private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseClou $license = $object->license; - if ($license === null) { - goto after_license; - } - - $license = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️WebhookPullRequestAutoMergeEnabled⚡️PullRequest⚡️Head⚡️Repo⚡️License($license); - after_license: $result['license'] = $license; - - $masterBranch = $object->masterBranch; - - if ($masterBranch === null) { - goto after_masterBranch; - } - - after_masterBranch: $result['master_branch'] = $masterBranch; - - $mergeCommitMessage = $object->mergeCommitMessage; - - if ($mergeCommitMessage === null) { - goto after_mergeCommitMessage; - } - - after_mergeCommitMessage: $result['merge_commit_message'] = $mergeCommitMessage; - - $mergeCommitTitle = $object->mergeCommitTitle; - - if ($mergeCommitTitle === null) { - goto after_mergeCommitTitle; - } - - after_mergeCommitTitle: $result['merge_commit_title'] = $mergeCommitTitle; - - $mergesUrl = $object->mergesUrl; - after_mergesUrl: $result['merges_url'] = $mergesUrl; - - $milestonesUrl = $object->milestonesUrl; - after_milestonesUrl: $result['milestones_url'] = $milestonesUrl; - - $mirrorUrl = $object->mirrorUrl; - - if ($mirrorUrl === null) { - goto after_mirrorUrl; - } - - after_mirrorUrl: $result['mirror_url'] = $mirrorUrl; - - $name = $object->name; - after_name: $result['name'] = $name; - - $nodeId = $object->nodeId; - after_nodeId: $result['node_id'] = $nodeId; - - $notificationsUrl = $object->notificationsUrl; - after_notificationsUrl: $result['notifications_url'] = $notificationsUrl; - - $openIssues = $object->openIssues; - after_openIssues: $result['open_issues'] = $openIssues; - - $openIssuesCount = $object->openIssuesCount; - after_openIssuesCount: $result['open_issues_count'] = $openIssuesCount; - - $organization = $object->organization; - - if ($organization === null) { - goto after_organization; - } - - after_organization: $result['organization'] = $organization; - - $owner = $object->owner; - - if ($owner === null) { - goto after_owner; - } - - $owner = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️WebhookPullRequestAutoMergeEnabled⚡️PullRequest⚡️Head⚡️Repo⚡️Owner($owner); - after_owner: $result['owner'] = $owner; - - $permissions = $object->permissions; - - if ($permissions === null) { - goto after_permissions; - } - - $permissions = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️WebhookPullRequestAutoMergeEnabled⚡️PullRequest⚡️Head⚡️Repo⚡️Permissions($permissions); - after_permissions: $result['permissions'] = $permissions; - - $private = $object->private; - after_private: $result['private'] = $private; - - $public = $object->public; - - if ($public === null) { - goto after_public; - } - - after_public: $result['public'] = $public; - - $pullsUrl = $object->pullsUrl; - after_pullsUrl: $result['pulls_url'] = $pullsUrl; - - $pushedAt = $object->pushedAt; - after_pushedAt: $result['pushed_at'] = $pushedAt; - - $releasesUrl = $object->releasesUrl; - after_releasesUrl: $result['releases_url'] = $releasesUrl; - - $roleName = $object->roleName; - - if ($roleName === null) { - goto after_roleName; - } - - after_roleName: $result['role_name'] = $roleName; - - $size = $object->size; - after_size: $result['size'] = $size; - - $squashMergeCommitMessage = $object->squashMergeCommitMessage; - - if ($squashMergeCommitMessage === null) { - goto after_squashMergeCommitMessage; - } - - after_squashMergeCommitMessage: $result['squash_merge_commit_message'] = $squashMergeCommitMessage; - - $squashMergeCommitTitle = $object->squashMergeCommitTitle; - - if ($squashMergeCommitTitle === null) { - goto after_squashMergeCommitTitle; - } - - after_squashMergeCommitTitle: $result['squash_merge_commit_title'] = $squashMergeCommitTitle; - - $sshUrl = $object->sshUrl; - after_sshUrl: $result['ssh_url'] = $sshUrl; - - $stargazers = $object->stargazers; - - if ($stargazers === null) { - goto after_stargazers; - } - - after_stargazers: $result['stargazers'] = $stargazers; - - $stargazersCount = $object->stargazersCount; - after_stargazersCount: $result['stargazers_count'] = $stargazersCount; - - $stargazersUrl = $object->stargazersUrl; - after_stargazersUrl: $result['stargazers_url'] = $stargazersUrl; - - $statusesUrl = $object->statusesUrl; - after_statusesUrl: $result['statuses_url'] = $statusesUrl; - - $subscribersUrl = $object->subscribersUrl; - after_subscribersUrl: $result['subscribers_url'] = $subscribersUrl; - - $subscriptionUrl = $object->subscriptionUrl; - after_subscriptionUrl: $result['subscription_url'] = $subscriptionUrl; - - $svnUrl = $object->svnUrl; - after_svnUrl: $result['svn_url'] = $svnUrl; - - $tagsUrl = $object->tagsUrl; - after_tagsUrl: $result['tags_url'] = $tagsUrl; - - $teamsUrl = $object->teamsUrl; - after_teamsUrl: $result['teams_url'] = $teamsUrl; - - $topics = $object->topics; - static $topicsSerializer0; - - if ($topicsSerializer0 === null) { - $topicsSerializer0 = new SerializeArrayItems(...[]); - } - - $topics = $topicsSerializer0->serialize($topics, $this); - after_topics: $result['topics'] = $topics; - - $treesUrl = $object->treesUrl; - after_treesUrl: $result['trees_url'] = $treesUrl; - - $updatedAt = $object->updatedAt; - after_updatedAt: $result['updated_at'] = $updatedAt; - - $url = $object->url; - after_url: $result['url'] = $url; - - $useSquashPrTitleAsDefault = $object->useSquashPrTitleAsDefault; - - if ($useSquashPrTitleAsDefault === null) { - goto after_useSquashPrTitleAsDefault; - } - - after_useSquashPrTitleAsDefault: $result['use_squash_pr_title_as_default'] = $useSquashPrTitleAsDefault; - - $visibility = $object->visibility; - after_visibility: $result['visibility'] = $visibility; - - $watchers = $object->watchers; - after_watchers: $result['watchers'] = $watchers; - - $watchersCount = $object->watchersCount; - after_watchersCount: $result['watchers_count'] = $watchersCount; - - $webCommitSignoffRequired = $object->webCommitSignoffRequired; - - if ($webCommitSignoffRequired === null) { - goto after_webCommitSignoffRequired; - } - - after_webCommitSignoffRequired: $result['web_commit_signoff_required'] = $webCommitSignoffRequired; - - return $result; - } - - private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️WebhookPullRequestAutoMergeEnabled⚡️PullRequest⚡️Head⚡️Repo⚡️License(mixed $object): mixed - { - assert($object instanceof \ApiClients\Client\GitHubEnterpriseCloud\Schema\WebhookPullRequestAutoMergeEnabled\PullRequest\Head\Repo\License); - $result = []; - - $key = $object->key; - after_key: $result['key'] = $key; - - $name = $object->name; - after_name: $result['name'] = $name; - - $nodeId = $object->nodeId; - after_nodeId: $result['node_id'] = $nodeId; - - $spdxId = $object->spdxId; - after_spdxId: $result['spdx_id'] = $spdxId; - - $url = $object->url; - - if ($url === null) { - goto after_url; - } - - after_url: $result['url'] = $url; - - return $result; - } - - private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️WebhookPullRequestAutoMergeEnabled⚡️PullRequest⚡️Head⚡️Repo⚡️Owner(mixed $object): mixed - { - assert($object instanceof \ApiClients\Client\GitHubEnterpriseCloud\Schema\WebhookPullRequestAutoMergeEnabled\PullRequest\Head\Repo\Owner); - $result = []; - - $avatarUrl = $object->avatarUrl; - - if ($avatarUrl === null) { - goto after_avatarUrl; - } - - after_avatarUrl: $result['avatar_url'] = $avatarUrl; - - $deleted = $object->deleted; - - if ($deleted === null) { - goto after_deleted; - } - - after_deleted: $result['deleted'] = $deleted; - - $email = $object->email; - - if ($email === null) { - goto after_email; - } - - after_email: $result['email'] = $email; - - $eventsUrl = $object->eventsUrl; - - if ($eventsUrl === null) { - goto after_eventsUrl; - } - - after_eventsUrl: $result['events_url'] = $eventsUrl; - - $followersUrl = $object->followersUrl; - - if ($followersUrl === null) { - goto after_followersUrl; - } - - after_followersUrl: $result['followers_url'] = $followersUrl; - - $followingUrl = $object->followingUrl; - - if ($followingUrl === null) { - goto after_followingUrl; - } - - after_followingUrl: $result['following_url'] = $followingUrl; - - $gistsUrl = $object->gistsUrl; - - if ($gistsUrl === null) { - goto after_gistsUrl; - } - - after_gistsUrl: $result['gists_url'] = $gistsUrl; - - $gravatarId = $object->gravatarId; - - if ($gravatarId === null) { - goto after_gravatarId; - } - - after_gravatarId: $result['gravatar_id'] = $gravatarId; - - $htmlUrl = $object->htmlUrl; - - if ($htmlUrl === null) { - goto after_htmlUrl; - } - - after_htmlUrl: $result['html_url'] = $htmlUrl; - - $id = $object->id; - after_id: $result['id'] = $id; - - $login = $object->login; - after_login: $result['login'] = $login; - - $name = $object->name; - - if ($name === null) { - goto after_name; - } - - after_name: $result['name'] = $name; - - $nodeId = $object->nodeId; - - if ($nodeId === null) { - goto after_nodeId; - } - - after_nodeId: $result['node_id'] = $nodeId; - - $organizationsUrl = $object->organizationsUrl; - - if ($organizationsUrl === null) { - goto after_organizationsUrl; - } - - after_organizationsUrl: $result['organizations_url'] = $organizationsUrl; - - $receivedEventsUrl = $object->receivedEventsUrl; - - if ($receivedEventsUrl === null) { - goto after_receivedEventsUrl; - } - - after_receivedEventsUrl: $result['received_events_url'] = $receivedEventsUrl; - - $reposUrl = $object->reposUrl; - - if ($reposUrl === null) { - goto after_reposUrl; - } - - after_reposUrl: $result['repos_url'] = $reposUrl; - - $siteAdmin = $object->siteAdmin; - - if ($siteAdmin === null) { - goto after_siteAdmin; - } - - after_siteAdmin: $result['site_admin'] = $siteAdmin; - - $starredUrl = $object->starredUrl; - - if ($starredUrl === null) { - goto after_starredUrl; - } - - after_starredUrl: $result['starred_url'] = $starredUrl; - - $subscriptionsUrl = $object->subscriptionsUrl; - - if ($subscriptionsUrl === null) { - goto after_subscriptionsUrl; + if ($license === null) { + goto after_license; } - after_subscriptionsUrl: $result['subscriptions_url'] = $subscriptionsUrl; + $license = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️WebhookPullRequestAutoMergeEnabled⚡️PullRequest⚡️Head⚡️Repo⚡️License($license); + after_license: $result['license'] = $license; - $type = $object->type; + $masterBranch = $object->masterBranch; - if ($type === null) { - goto after_type; + if ($masterBranch === null) { + goto after_masterBranch; } - after_type: $result['type'] = $type; + after_masterBranch: $result['master_branch'] = $masterBranch; - $url = $object->url; + $mergeCommitMessage = $object->mergeCommitMessage; - if ($url === null) { - goto after_url; + if ($mergeCommitMessage === null) { + goto after_mergeCommitMessage; } - after_url: $result['url'] = $url; + after_mergeCommitMessage: $result['merge_commit_message'] = $mergeCommitMessage; - $userViewType = $object->userViewType; + $mergeCommitTitle = $object->mergeCommitTitle; - if ($userViewType === null) { - goto after_userViewType; + if ($mergeCommitTitle === null) { + goto after_mergeCommitTitle; } - after_userViewType: $result['user_view_type'] = $userViewType; - - return $result; - } + after_mergeCommitTitle: $result['merge_commit_title'] = $mergeCommitTitle; - private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️WebhookPullRequestAutoMergeEnabled⚡️PullRequest⚡️Head⚡️Repo⚡️Permissions(mixed $object): mixed - { - assert($object instanceof \ApiClients\Client\GitHubEnterpriseCloud\Schema\WebhookPullRequestAutoMergeEnabled\PullRequest\Head\Repo\Permissions); - $result = []; + $mergesUrl = $object->mergesUrl; + after_mergesUrl: $result['merges_url'] = $mergesUrl; - $admin = $object->admin; - after_admin: $result['admin'] = $admin; + $milestonesUrl = $object->milestonesUrl; + after_milestonesUrl: $result['milestones_url'] = $milestonesUrl; - $maintain = $object->maintain; + $mirrorUrl = $object->mirrorUrl; - if ($maintain === null) { - goto after_maintain; + if ($mirrorUrl === null) { + goto after_mirrorUrl; } - after_maintain: $result['maintain'] = $maintain; - - $pull = $object->pull; - after_pull: $result['pull'] = $pull; - - $push = $object->push; - after_push: $result['push'] = $push; + after_mirrorUrl: $result['mirror_url'] = $mirrorUrl; - $triage = $object->triage; + $name = $object->name; + after_name: $result['name'] = $name; - if ($triage === null) { - goto after_triage; - } + $nodeId = $object->nodeId; + after_nodeId: $result['node_id'] = $nodeId; - after_triage: $result['triage'] = $triage; + $notificationsUrl = $object->notificationsUrl; + after_notificationsUrl: $result['notifications_url'] = $notificationsUrl; - return $result; - } + $openIssues = $object->openIssues; + after_openIssues: $result['open_issues'] = $openIssues; - private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️WebhookPullRequestAutoMergeEnabled⚡️PullRequest⚡️Head⚡️User(mixed $object): mixed - { - assert($object instanceof \ApiClients\Client\GitHubEnterpriseCloud\Schema\WebhookPullRequestAutoMergeEnabled\PullRequest\Head\User); - $result = []; + $openIssuesCount = $object->openIssuesCount; + after_openIssuesCount: $result['open_issues_count'] = $openIssuesCount; - $avatarUrl = $object->avatarUrl; + $organization = $object->organization; - if ($avatarUrl === null) { - goto after_avatarUrl; + if ($organization === null) { + goto after_organization; } - after_avatarUrl: $result['avatar_url'] = $avatarUrl; + after_organization: $result['organization'] = $organization; - $deleted = $object->deleted; + $owner = $object->owner; - if ($deleted === null) { - goto after_deleted; + if ($owner === null) { + goto after_owner; } - after_deleted: $result['deleted'] = $deleted; + $owner = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️WebhookPullRequestAutoMergeEnabled⚡️PullRequest⚡️Head⚡️Repo⚡️Owner($owner); + after_owner: $result['owner'] = $owner; - $email = $object->email; + $permissions = $object->permissions; - if ($email === null) { - goto after_email; + if ($permissions === null) { + goto after_permissions; } - after_email: $result['email'] = $email; + $permissions = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️WebhookPullRequestAutoMergeEnabled⚡️PullRequest⚡️Head⚡️Repo⚡️Permissions($permissions); + after_permissions: $result['permissions'] = $permissions; - $eventsUrl = $object->eventsUrl; + $private = $object->private; + after_private: $result['private'] = $private; - if ($eventsUrl === null) { - goto after_eventsUrl; + $public = $object->public; + + if ($public === null) { + goto after_public; } - after_eventsUrl: $result['events_url'] = $eventsUrl; + after_public: $result['public'] = $public; - $followersUrl = $object->followersUrl; + $pullsUrl = $object->pullsUrl; + after_pullsUrl: $result['pulls_url'] = $pullsUrl; - if ($followersUrl === null) { - goto after_followersUrl; - } + $pushedAt = $object->pushedAt; + after_pushedAt: $result['pushed_at'] = $pushedAt; - after_followersUrl: $result['followers_url'] = $followersUrl; + $releasesUrl = $object->releasesUrl; + after_releasesUrl: $result['releases_url'] = $releasesUrl; - $followingUrl = $object->followingUrl; + $roleName = $object->roleName; - if ($followingUrl === null) { - goto after_followingUrl; + if ($roleName === null) { + goto after_roleName; } - after_followingUrl: $result['following_url'] = $followingUrl; + after_roleName: $result['role_name'] = $roleName; - $gistsUrl = $object->gistsUrl; + $size = $object->size; + after_size: $result['size'] = $size; - if ($gistsUrl === null) { - goto after_gistsUrl; + $squashMergeCommitMessage = $object->squashMergeCommitMessage; + + if ($squashMergeCommitMessage === null) { + goto after_squashMergeCommitMessage; } - after_gistsUrl: $result['gists_url'] = $gistsUrl; + after_squashMergeCommitMessage: $result['squash_merge_commit_message'] = $squashMergeCommitMessage; - $gravatarId = $object->gravatarId; + $squashMergeCommitTitle = $object->squashMergeCommitTitle; - if ($gravatarId === null) { - goto after_gravatarId; + if ($squashMergeCommitTitle === null) { + goto after_squashMergeCommitTitle; } - after_gravatarId: $result['gravatar_id'] = $gravatarId; + after_squashMergeCommitTitle: $result['squash_merge_commit_title'] = $squashMergeCommitTitle; - $htmlUrl = $object->htmlUrl; + $sshUrl = $object->sshUrl; + after_sshUrl: $result['ssh_url'] = $sshUrl; - if ($htmlUrl === null) { - goto after_htmlUrl; + $stargazers = $object->stargazers; + + if ($stargazers === null) { + goto after_stargazers; } - after_htmlUrl: $result['html_url'] = $htmlUrl; + after_stargazers: $result['stargazers'] = $stargazers; - $id = $object->id; - after_id: $result['id'] = $id; + $stargazersCount = $object->stargazersCount; + after_stargazersCount: $result['stargazers_count'] = $stargazersCount; - $login = $object->login; - after_login: $result['login'] = $login; + $stargazersUrl = $object->stargazersUrl; + after_stargazersUrl: $result['stargazers_url'] = $stargazersUrl; - $name = $object->name; + $statusesUrl = $object->statusesUrl; + after_statusesUrl: $result['statuses_url'] = $statusesUrl; - if ($name === null) { - goto after_name; - } + $subscribersUrl = $object->subscribersUrl; + after_subscribersUrl: $result['subscribers_url'] = $subscribersUrl; - after_name: $result['name'] = $name; + $subscriptionUrl = $object->subscriptionUrl; + after_subscriptionUrl: $result['subscription_url'] = $subscriptionUrl; - $nodeId = $object->nodeId; + $svnUrl = $object->svnUrl; + after_svnUrl: $result['svn_url'] = $svnUrl; - if ($nodeId === null) { - goto after_nodeId; - } + $tagsUrl = $object->tagsUrl; + after_tagsUrl: $result['tags_url'] = $tagsUrl; - after_nodeId: $result['node_id'] = $nodeId; + $teamsUrl = $object->teamsUrl; + after_teamsUrl: $result['teams_url'] = $teamsUrl; - $organizationsUrl = $object->organizationsUrl; + $topics = $object->topics; + static $topicsSerializer0; - if ($organizationsUrl === null) { - goto after_organizationsUrl; + if ($topicsSerializer0 === null) { + $topicsSerializer0 = new SerializeArrayItems(...[]); } - after_organizationsUrl: $result['organizations_url'] = $organizationsUrl; + $topics = $topicsSerializer0->serialize($topics, $this); + after_topics: $result['topics'] = $topics; - $receivedEventsUrl = $object->receivedEventsUrl; + $treesUrl = $object->treesUrl; + after_treesUrl: $result['trees_url'] = $treesUrl; - if ($receivedEventsUrl === null) { - goto after_receivedEventsUrl; - } + $updatedAt = $object->updatedAt; + after_updatedAt: $result['updated_at'] = $updatedAt; - after_receivedEventsUrl: $result['received_events_url'] = $receivedEventsUrl; + $url = $object->url; + after_url: $result['url'] = $url; - $reposUrl = $object->reposUrl; + $useSquashPrTitleAsDefault = $object->useSquashPrTitleAsDefault; - if ($reposUrl === null) { - goto after_reposUrl; + if ($useSquashPrTitleAsDefault === null) { + goto after_useSquashPrTitleAsDefault; } - after_reposUrl: $result['repos_url'] = $reposUrl; + after_useSquashPrTitleAsDefault: $result['use_squash_pr_title_as_default'] = $useSquashPrTitleAsDefault; - $siteAdmin = $object->siteAdmin; + $visibility = $object->visibility; + after_visibility: $result['visibility'] = $visibility; - if ($siteAdmin === null) { - goto after_siteAdmin; - } + $watchers = $object->watchers; + after_watchers: $result['watchers'] = $watchers; - after_siteAdmin: $result['site_admin'] = $siteAdmin; + $watchersCount = $object->watchersCount; + after_watchersCount: $result['watchers_count'] = $watchersCount; - $starredUrl = $object->starredUrl; + $webCommitSignoffRequired = $object->webCommitSignoffRequired; - if ($starredUrl === null) { - goto after_starredUrl; + if ($webCommitSignoffRequired === null) { + goto after_webCommitSignoffRequired; } - after_starredUrl: $result['starred_url'] = $starredUrl; + after_webCommitSignoffRequired: $result['web_commit_signoff_required'] = $webCommitSignoffRequired; - $subscriptionsUrl = $object->subscriptionsUrl; + return $result; + } - if ($subscriptionsUrl === null) { - goto after_subscriptionsUrl; - } + private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️WebhookPullRequestAutoMergeEnabled⚡️PullRequest⚡️Head⚡️Repo⚡️License(mixed $object): mixed + { + assert($object instanceof \ApiClients\Client\GitHubEnterpriseCloud\Schema\WebhookPullRequestAutoMergeEnabled\PullRequest\Head\Repo\License); + $result = []; - after_subscriptionsUrl: $result['subscriptions_url'] = $subscriptionsUrl; + $key = $object->key; + after_key: $result['key'] = $key; - $type = $object->type; + $name = $object->name; + after_name: $result['name'] = $name; - if ($type === null) { - goto after_type; - } + $nodeId = $object->nodeId; + after_nodeId: $result['node_id'] = $nodeId; - after_type: $result['type'] = $type; + $spdxId = $object->spdxId; + after_spdxId: $result['spdx_id'] = $spdxId; $url = $object->url; @@ -101956,20 +99639,12 @@ private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseClou after_url: $result['url'] = $url; - $userViewType = $object->userViewType; - - if ($userViewType === null) { - goto after_userViewType; - } - - after_userViewType: $result['user_view_type'] = $userViewType; - return $result; } - private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️WebhookPullRequestAutoMergeEnabled⚡️PullRequest⚡️MergedBy(mixed $object): mixed + private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️WebhookPullRequestAutoMergeEnabled⚡️PullRequest⚡️Head⚡️Repo⚡️Owner(mixed $object): mixed { - assert($object instanceof \ApiClients\Client\GitHubEnterpriseCloud\Schema\WebhookPullRequestAutoMergeEnabled\PullRequest\MergedBy); + assert($object instanceof \ApiClients\Client\GitHubEnterpriseCloud\Schema\WebhookPullRequestAutoMergeEnabled\PullRequest\Head\Repo\Owner); $result = []; $avatarUrl = $object->avatarUrl; @@ -102141,86 +99816,42 @@ private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseClou return $result; } - private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️WebhookPullRequestAutoMergeEnabled⚡️PullRequest⚡️Milestone(mixed $object): mixed + private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️WebhookPullRequestAutoMergeEnabled⚡️PullRequest⚡️Head⚡️Repo⚡️Permissions(mixed $object): mixed { - assert($object instanceof \ApiClients\Client\GitHubEnterpriseCloud\Schema\WebhookPullRequestAutoMergeEnabled\PullRequest\Milestone); + assert($object instanceof \ApiClients\Client\GitHubEnterpriseCloud\Schema\WebhookPullRequestAutoMergeEnabled\PullRequest\Head\Repo\Permissions); $result = []; - $closedAt = $object->closedAt; - - if ($closedAt === null) { - goto after_closedAt; - } - - after_closedAt: $result['closed_at'] = $closedAt; - - $closedIssues = $object->closedIssues; - after_closedIssues: $result['closed_issues'] = $closedIssues; - - $createdAt = $object->createdAt; - after_createdAt: $result['created_at'] = $createdAt; + $admin = $object->admin; + after_admin: $result['admin'] = $admin; - $creator = $object->creator; + $maintain = $object->maintain; - if ($creator === null) { - goto after_creator; + if ($maintain === null) { + goto after_maintain; } - $creator = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️WebhooksIssue⚡️Milestone⚡️Creator($creator); - after_creator: $result['creator'] = $creator; - - $description = $object->description; + after_maintain: $result['maintain'] = $maintain; - if ($description === null) { - goto after_description; - } + $pull = $object->pull; + after_pull: $result['pull'] = $pull; - after_description: $result['description'] = $description; + $push = $object->push; + after_push: $result['push'] = $push; - $dueOn = $object->dueOn; + $triage = $object->triage; - if ($dueOn === null) { - goto after_dueOn; + if ($triage === null) { + goto after_triage; } - after_dueOn: $result['due_on'] = $dueOn; - - $htmlUrl = $object->htmlUrl; - after_htmlUrl: $result['html_url'] = $htmlUrl; - - $id = $object->id; - after_id: $result['id'] = $id; - - $labelsUrl = $object->labelsUrl; - after_labelsUrl: $result['labels_url'] = $labelsUrl; - - $nodeId = $object->nodeId; - after_nodeId: $result['node_id'] = $nodeId; - - $number = $object->number; - after_number: $result['number'] = $number; - - $openIssues = $object->openIssues; - after_openIssues: $result['open_issues'] = $openIssues; - - $state = $object->state; - after_state: $result['state'] = $state; - - $title = $object->title; - after_title: $result['title'] = $title; - - $updatedAt = $object->updatedAt; - after_updatedAt: $result['updated_at'] = $updatedAt; - - $url = $object->url; - after_url: $result['url'] = $url; + after_triage: $result['triage'] = $triage; return $result; } - private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️WebhookPullRequestAutoMergeEnabled⚡️PullRequest⚡️Milestone⚡️Creator(mixed $object): mixed + private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️WebhookPullRequestAutoMergeEnabled⚡️PullRequest⚡️Head⚡️User(mixed $object): mixed { - assert($object instanceof \ApiClients\Client\GitHubEnterpriseCloud\Schema\WebhookPullRequestAutoMergeEnabled\PullRequest\Milestone\Creator); + assert($object instanceof \ApiClients\Client\GitHubEnterpriseCloud\Schema\WebhookPullRequestAutoMergeEnabled\PullRequest\Head\User); $result = []; $avatarUrl = $object->avatarUrl; @@ -102392,9 +100023,9 @@ private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseClou return $result; } - private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️WebhookPullRequestAutoMergeEnabled⚡️PullRequest⚡️User(mixed $object): mixed + private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️WebhookPullRequestAutoMergeEnabled⚡️PullRequest⚡️MergedBy(mixed $object): mixed { - assert($object instanceof \ApiClients\Client\GitHubEnterpriseCloud\Schema\WebhookPullRequestAutoMergeEnabled\PullRequest\User); + assert($object instanceof \ApiClients\Client\GitHubEnterpriseCloud\Schema\WebhookPullRequestAutoMergeEnabled\PullRequest\MergedBy); $result = []; $avatarUrl = $object->avatarUrl; @@ -102540,182 +100171,36 @@ private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseClou after_subscriptionsUrl: $result['subscriptions_url'] = $subscriptionsUrl; $type = $object->type; - - if ($type === null) { - goto after_type; - } - - after_type: $result['type'] = $type; - - $url = $object->url; - - if ($url === null) { - goto after_url; - } - - after_url: $result['url'] = $url; - - $userViewType = $object->userViewType; - - if ($userViewType === null) { - goto after_userViewType; - } - - after_userViewType: $result['user_view_type'] = $userViewType; - - return $result; - } - - private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️WebhookPullRequestClosed(mixed $object): mixed - { - assert($object instanceof WebhookPullRequestClosed); - $result = []; - - $action = $object->action; - after_action: $result['action'] = $action; - - $enterprise = $object->enterprise; - - if ($enterprise === null) { - goto after_enterprise; - } - - $enterprise = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️EnterpriseWebhooks($enterprise); - after_enterprise: $result['enterprise'] = $enterprise; - - $installation = $object->installation; - - if ($installation === null) { - goto after_installation; - } - - $installation = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleInstallation($installation); - after_installation: $result['installation'] = $installation; - - $number = $object->number; - after_number: $result['number'] = $number; - - $organization = $object->organization; - - if ($organization === null) { - goto after_organization; - } - - $organization = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️OrganizationSimpleWebhooks($organization); - after_organization: $result['organization'] = $organization; - - $pullRequest = $object->pullRequest; - $pullRequest = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest($pullRequest); - after_pullRequest: $result['pull_request'] = $pullRequest; - - $repository = $object->repository; - $repository = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️RepositoryWebhooks($repository); - after_repository: $result['repository'] = $repository; - - $sender = $object->sender; - $sender = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleUser($sender); - after_sender: $result['sender'] = $sender; - - return $result; - } - - private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest(mixed $object): mixed - { - assert($object instanceof \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest); - $result = []; - - $url = $object->url; - after_url: $result['url'] = $url; - - $id = $object->id; - after_id: $result['id'] = $id; - - $nodeId = $object->nodeId; - after_nodeId: $result['node_id'] = $nodeId; - - $htmlUrl = $object->htmlUrl; - after_htmlUrl: $result['html_url'] = $htmlUrl; - - $diffUrl = $object->diffUrl; - after_diffUrl: $result['diff_url'] = $diffUrl; - - $patchUrl = $object->patchUrl; - after_patchUrl: $result['patch_url'] = $patchUrl; - - $issueUrl = $object->issueUrl; - after_issueUrl: $result['issue_url'] = $issueUrl; - - $commitsUrl = $object->commitsUrl; - after_commitsUrl: $result['commits_url'] = $commitsUrl; - - $reviewCommentsUrl = $object->reviewCommentsUrl; - after_reviewCommentsUrl: $result['review_comments_url'] = $reviewCommentsUrl; - - $reviewCommentUrl = $object->reviewCommentUrl; - after_reviewCommentUrl: $result['review_comment_url'] = $reviewCommentUrl; - - $commentsUrl = $object->commentsUrl; - after_commentsUrl: $result['comments_url'] = $commentsUrl; - - $statusesUrl = $object->statusesUrl; - after_statusesUrl: $result['statuses_url'] = $statusesUrl; - - $number = $object->number; - after_number: $result['number'] = $number; - - $state = $object->state; - after_state: $result['state'] = $state; - - $locked = $object->locked; - after_locked: $result['locked'] = $locked; - - $title = $object->title; - after_title: $result['title'] = $title; - - $user = $object->user; - $user = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleUser($user); - after_user: $result['user'] = $user; - - $body = $object->body; - - if ($body === null) { - goto after_body; - } - - after_body: $result['body'] = $body; - - $labels = $object->labels; - static $labelsSerializer0; - - if ($labelsSerializer0 === null) { - $labelsSerializer0 = new SerializeArrayItems(...[]); + + if ($type === null) { + goto after_type; } - $labels = $labelsSerializer0->serialize($labels, $this); - after_labels: $result['labels'] = $labels; + after_type: $result['type'] = $type; - $milestone = $object->milestone; + $url = $object->url; - if ($milestone === null) { - goto after_milestone; + if ($url === null) { + goto after_url; } - $milestone = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Milestone($milestone); - after_milestone: $result['milestone'] = $milestone; + after_url: $result['url'] = $url; - $activeLockReason = $object->activeLockReason; + $userViewType = $object->userViewType; - if ($activeLockReason === null) { - goto after_activeLockReason; + if ($userViewType === null) { + goto after_userViewType; } - after_activeLockReason: $result['active_lock_reason'] = $activeLockReason; + after_userViewType: $result['user_view_type'] = $userViewType; - $createdAt = $object->createdAt; - after_createdAt: $result['created_at'] = $createdAt; + return $result; + } - $updatedAt = $object->updatedAt; - after_updatedAt: $result['updated_at'] = $updatedAt; + private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️WebhookPullRequestAutoMergeEnabled⚡️PullRequest⚡️Milestone(mixed $object): mixed + { + assert($object instanceof \ApiClients\Client\GitHubEnterpriseCloud\Schema\WebhookPullRequestAutoMergeEnabled\PullRequest\Milestone); + $result = []; $closedAt = $object->closedAt; @@ -102725,589 +100210,562 @@ private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseClou after_closedAt: $result['closed_at'] = $closedAt; - $mergedAt = $object->mergedAt; + $closedIssues = $object->closedIssues; + after_closedIssues: $result['closed_issues'] = $closedIssues; - if ($mergedAt === null) { - goto after_mergedAt; + $createdAt = $object->createdAt; + after_createdAt: $result['created_at'] = $createdAt; + + $creator = $object->creator; + + if ($creator === null) { + goto after_creator; } - after_mergedAt: $result['merged_at'] = $mergedAt; + $creator = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️WebhooksIssue⚡️Milestone⚡️Creator($creator); + after_creator: $result['creator'] = $creator; - $mergeCommitSha = $object->mergeCommitSha; + $description = $object->description; - if ($mergeCommitSha === null) { - goto after_mergeCommitSha; + if ($description === null) { + goto after_description; } - after_mergeCommitSha: $result['merge_commit_sha'] = $mergeCommitSha; + after_description: $result['description'] = $description; - $assignee = $object->assignee; + $dueOn = $object->dueOn; - if ($assignee === null) { - goto after_assignee; + if ($dueOn === null) { + goto after_dueOn; } - $assignee = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleUser($assignee); - after_assignee: $result['assignee'] = $assignee; + after_dueOn: $result['due_on'] = $dueOn; - $assignees = $object->assignees; + $htmlUrl = $object->htmlUrl; + after_htmlUrl: $result['html_url'] = $htmlUrl; - if ($assignees === null) { - goto after_assignees; - } + $id = $object->id; + after_id: $result['id'] = $id; - static $assigneesSerializer0; + $labelsUrl = $object->labelsUrl; + after_labelsUrl: $result['labels_url'] = $labelsUrl; - if ($assigneesSerializer0 === null) { - $assigneesSerializer0 = new SerializeArrayItems(...[]); - } + $nodeId = $object->nodeId; + after_nodeId: $result['node_id'] = $nodeId; - $assignees = $assigneesSerializer0->serialize($assignees, $this); - after_assignees: $result['assignees'] = $assignees; + $number = $object->number; + after_number: $result['number'] = $number; - $requestedReviewers = $object->requestedReviewers; + $openIssues = $object->openIssues; + after_openIssues: $result['open_issues'] = $openIssues; - if ($requestedReviewers === null) { - goto after_requestedReviewers; - } + $state = $object->state; + after_state: $result['state'] = $state; - static $requestedReviewersSerializer0; + $title = $object->title; + after_title: $result['title'] = $title; - if ($requestedReviewersSerializer0 === null) { - $requestedReviewersSerializer0 = new SerializeArrayItems(...[]); - } + $updatedAt = $object->updatedAt; + after_updatedAt: $result['updated_at'] = $updatedAt; - $requestedReviewers = $requestedReviewersSerializer0->serialize($requestedReviewers, $this); - after_requestedReviewers: $result['requested_reviewers'] = $requestedReviewers; + $url = $object->url; + after_url: $result['url'] = $url; - $requestedTeams = $object->requestedTeams; + return $result; + } - if ($requestedTeams === null) { - goto after_requestedTeams; - } + private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️WebhookPullRequestAutoMergeEnabled⚡️PullRequest⚡️Milestone⚡️Creator(mixed $object): mixed + { + assert($object instanceof \ApiClients\Client\GitHubEnterpriseCloud\Schema\WebhookPullRequestAutoMergeEnabled\PullRequest\Milestone\Creator); + $result = []; - static $requestedTeamsSerializer0; + $avatarUrl = $object->avatarUrl; - if ($requestedTeamsSerializer0 === null) { - $requestedTeamsSerializer0 = new SerializeArrayItems(...[]); + if ($avatarUrl === null) { + goto after_avatarUrl; } - $requestedTeams = $requestedTeamsSerializer0->serialize($requestedTeams, $this); - after_requestedTeams: $result['requested_teams'] = $requestedTeams; - - $head = $object->head; - $head = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head($head); - after_head: $result['head'] = $head; + after_avatarUrl: $result['avatar_url'] = $avatarUrl; - $base = $object->base; - $base = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base($base); - after_base: $result['base'] = $base; + $deleted = $object->deleted; - $links = $object->links; - $links = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Links($links); - after_links: $result['_links'] = $links; + if ($deleted === null) { + goto after_deleted; + } - $authorAssociation = $object->authorAssociation; - after_authorAssociation: $result['author_association'] = $authorAssociation; + after_deleted: $result['deleted'] = $deleted; - $autoMerge = $object->autoMerge; + $email = $object->email; - if ($autoMerge === null) { - goto after_autoMerge; + if ($email === null) { + goto after_email; } - $autoMerge = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️AutoMerge($autoMerge); - after_autoMerge: $result['auto_merge'] = $autoMerge; + after_email: $result['email'] = $email; - $draft = $object->draft; + $eventsUrl = $object->eventsUrl; - if ($draft === null) { - goto after_draft; + if ($eventsUrl === null) { + goto after_eventsUrl; } - after_draft: $result['draft'] = $draft; - - $merged = $object->merged; - after_merged: $result['merged'] = $merged; + after_eventsUrl: $result['events_url'] = $eventsUrl; - $mergeable = $object->mergeable; + $followersUrl = $object->followersUrl; - if ($mergeable === null) { - goto after_mergeable; + if ($followersUrl === null) { + goto after_followersUrl; } - after_mergeable: $result['mergeable'] = $mergeable; + after_followersUrl: $result['followers_url'] = $followersUrl; - $rebaseable = $object->rebaseable; + $followingUrl = $object->followingUrl; - if ($rebaseable === null) { - goto after_rebaseable; + if ($followingUrl === null) { + goto after_followingUrl; } - after_rebaseable: $result['rebaseable'] = $rebaseable; - - $mergeableState = $object->mergeableState; - after_mergeableState: $result['mergeable_state'] = $mergeableState; + after_followingUrl: $result['following_url'] = $followingUrl; - $mergedBy = $object->mergedBy; + $gistsUrl = $object->gistsUrl; - if ($mergedBy === null) { - goto after_mergedBy; + if ($gistsUrl === null) { + goto after_gistsUrl; } - $mergedBy = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleUser($mergedBy); - after_mergedBy: $result['merged_by'] = $mergedBy; + after_gistsUrl: $result['gists_url'] = $gistsUrl; - $comments = $object->comments; - after_comments: $result['comments'] = $comments; + $gravatarId = $object->gravatarId; - $reviewComments = $object->reviewComments; - after_reviewComments: $result['review_comments'] = $reviewComments; + if ($gravatarId === null) { + goto after_gravatarId; + } - $maintainerCanModify = $object->maintainerCanModify; - after_maintainerCanModify: $result['maintainer_can_modify'] = $maintainerCanModify; + after_gravatarId: $result['gravatar_id'] = $gravatarId; - $commits = $object->commits; - after_commits: $result['commits'] = $commits; + $htmlUrl = $object->htmlUrl; - $additions = $object->additions; - after_additions: $result['additions'] = $additions; + if ($htmlUrl === null) { + goto after_htmlUrl; + } - $deletions = $object->deletions; - after_deletions: $result['deletions'] = $deletions; + after_htmlUrl: $result['html_url'] = $htmlUrl; - $changedFiles = $object->changedFiles; - after_changedFiles: $result['changed_files'] = $changedFiles; + $id = $object->id; + after_id: $result['id'] = $id; - return $result; - } + $login = $object->login; + after_login: $result['login'] = $login; - private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Milestone(mixed $object): mixed - { - assert($object instanceof \ApiClients\Client\GitHubEnterpriseCloud\Schema\Milestone); - $result = []; + $name = $object->name; - $url = $object->url; - after_url: $result['url'] = $url; + if ($name === null) { + goto after_name; + } - $htmlUrl = $object->htmlUrl; - after_htmlUrl: $result['html_url'] = $htmlUrl; + after_name: $result['name'] = $name; - $labelsUrl = $object->labelsUrl; - after_labelsUrl: $result['labels_url'] = $labelsUrl; + $nodeId = $object->nodeId; - $id = $object->id; - after_id: $result['id'] = $id; + if ($nodeId === null) { + goto after_nodeId; + } - $nodeId = $object->nodeId; after_nodeId: $result['node_id'] = $nodeId; - $number = $object->number; - after_number: $result['number'] = $number; + $organizationsUrl = $object->organizationsUrl; - $state = $object->state; - after_state: $result['state'] = $state; + if ($organizationsUrl === null) { + goto after_organizationsUrl; + } - $title = $object->title; - after_title: $result['title'] = $title; + after_organizationsUrl: $result['organizations_url'] = $organizationsUrl; - $description = $object->description; + $receivedEventsUrl = $object->receivedEventsUrl; - if ($description === null) { - goto after_description; + if ($receivedEventsUrl === null) { + goto after_receivedEventsUrl; } - after_description: $result['description'] = $description; + after_receivedEventsUrl: $result['received_events_url'] = $receivedEventsUrl; - $creator = $object->creator; + $reposUrl = $object->reposUrl; - if ($creator === null) { - goto after_creator; + if ($reposUrl === null) { + goto after_reposUrl; } - $creator = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleUser($creator); - after_creator: $result['creator'] = $creator; - - $openIssues = $object->openIssues; - after_openIssues: $result['open_issues'] = $openIssues; + after_reposUrl: $result['repos_url'] = $reposUrl; - $closedIssues = $object->closedIssues; - after_closedIssues: $result['closed_issues'] = $closedIssues; + $siteAdmin = $object->siteAdmin; - $createdAt = $object->createdAt; - after_createdAt: $result['created_at'] = $createdAt; + if ($siteAdmin === null) { + goto after_siteAdmin; + } - $updatedAt = $object->updatedAt; - after_updatedAt: $result['updated_at'] = $updatedAt; + after_siteAdmin: $result['site_admin'] = $siteAdmin; - $closedAt = $object->closedAt; + $starredUrl = $object->starredUrl; - if ($closedAt === null) { - goto after_closedAt; + if ($starredUrl === null) { + goto after_starredUrl; } - after_closedAt: $result['closed_at'] = $closedAt; + after_starredUrl: $result['starred_url'] = $starredUrl; - $dueOn = $object->dueOn; + $subscriptionsUrl = $object->subscriptionsUrl; - if ($dueOn === null) { - goto after_dueOn; + if ($subscriptionsUrl === null) { + goto after_subscriptionsUrl; } - after_dueOn: $result['due_on'] = $dueOn; - - return $result; - } + after_subscriptionsUrl: $result['subscriptions_url'] = $subscriptionsUrl; - private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head(mixed $object): mixed - { - assert($object instanceof \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head); - $result = []; + $type = $object->type; - $label = $object->label; - after_label: $result['label'] = $label; + if ($type === null) { + goto after_type; + } - $ref = $object->ref; - after_ref: $result['ref'] = $ref; + after_type: $result['type'] = $type; - $repo = $object->repo; + $url = $object->url; - if ($repo === null) { - goto after_repo; + if ($url === null) { + goto after_url; } - $repo = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo($repo); - after_repo: $result['repo'] = $repo; + after_url: $result['url'] = $url; - $sha = $object->sha; - after_sha: $result['sha'] = $sha; + $userViewType = $object->userViewType; - $user = $object->user; - $user = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️User($user); - after_user: $result['user'] = $user; + if ($userViewType === null) { + goto after_userViewType; + } + + after_userViewType: $result['user_view_type'] = $userViewType; return $result; } - private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo(mixed $object): mixed + private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️WebhookPullRequestAutoMergeEnabled⚡️PullRequest⚡️User(mixed $object): mixed { - assert($object instanceof \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo); + assert($object instanceof \ApiClients\Client\GitHubEnterpriseCloud\Schema\WebhookPullRequestAutoMergeEnabled\PullRequest\User); $result = []; - $archiveUrl = $object->archiveUrl; - after_archiveUrl: $result['archive_url'] = $archiveUrl; - - $assigneesUrl = $object->assigneesUrl; - after_assigneesUrl: $result['assignees_url'] = $assigneesUrl; - - $blobsUrl = $object->blobsUrl; - after_blobsUrl: $result['blobs_url'] = $blobsUrl; + $avatarUrl = $object->avatarUrl; - $branchesUrl = $object->branchesUrl; - after_branchesUrl: $result['branches_url'] = $branchesUrl; + if ($avatarUrl === null) { + goto after_avatarUrl; + } - $collaboratorsUrl = $object->collaboratorsUrl; - after_collaboratorsUrl: $result['collaborators_url'] = $collaboratorsUrl; + after_avatarUrl: $result['avatar_url'] = $avatarUrl; - $commentsUrl = $object->commentsUrl; - after_commentsUrl: $result['comments_url'] = $commentsUrl; + $deleted = $object->deleted; - $commitsUrl = $object->commitsUrl; - after_commitsUrl: $result['commits_url'] = $commitsUrl; + if ($deleted === null) { + goto after_deleted; + } - $compareUrl = $object->compareUrl; - after_compareUrl: $result['compare_url'] = $compareUrl; + after_deleted: $result['deleted'] = $deleted; - $contentsUrl = $object->contentsUrl; - after_contentsUrl: $result['contents_url'] = $contentsUrl; + $email = $object->email; - $contributorsUrl = $object->contributorsUrl; - after_contributorsUrl: $result['contributors_url'] = $contributorsUrl; + if ($email === null) { + goto after_email; + } - $deploymentsUrl = $object->deploymentsUrl; - after_deploymentsUrl: $result['deployments_url'] = $deploymentsUrl; + after_email: $result['email'] = $email; - $description = $object->description; + $eventsUrl = $object->eventsUrl; - if ($description === null) { - goto after_description; + if ($eventsUrl === null) { + goto after_eventsUrl; } - after_description: $result['description'] = $description; - - $downloadsUrl = $object->downloadsUrl; - after_downloadsUrl: $result['downloads_url'] = $downloadsUrl; - - $eventsUrl = $object->eventsUrl; after_eventsUrl: $result['events_url'] = $eventsUrl; - $fork = $object->fork; - after_fork: $result['fork'] = $fork; + $followersUrl = $object->followersUrl; - $forksUrl = $object->forksUrl; - after_forksUrl: $result['forks_url'] = $forksUrl; + if ($followersUrl === null) { + goto after_followersUrl; + } - $fullName = $object->fullName; - after_fullName: $result['full_name'] = $fullName; + after_followersUrl: $result['followers_url'] = $followersUrl; - $gitCommitsUrl = $object->gitCommitsUrl; - after_gitCommitsUrl: $result['git_commits_url'] = $gitCommitsUrl; + $followingUrl = $object->followingUrl; - $gitRefsUrl = $object->gitRefsUrl; - after_gitRefsUrl: $result['git_refs_url'] = $gitRefsUrl; + if ($followingUrl === null) { + goto after_followingUrl; + } - $gitTagsUrl = $object->gitTagsUrl; - after_gitTagsUrl: $result['git_tags_url'] = $gitTagsUrl; + after_followingUrl: $result['following_url'] = $followingUrl; - $hooksUrl = $object->hooksUrl; - after_hooksUrl: $result['hooks_url'] = $hooksUrl; + $gistsUrl = $object->gistsUrl; - $htmlUrl = $object->htmlUrl; - after_htmlUrl: $result['html_url'] = $htmlUrl; + if ($gistsUrl === null) { + goto after_gistsUrl; + } - $id = $object->id; - after_id: $result['id'] = $id; + after_gistsUrl: $result['gists_url'] = $gistsUrl; - $nodeId = $object->nodeId; - after_nodeId: $result['node_id'] = $nodeId; + $gravatarId = $object->gravatarId; - $issueCommentUrl = $object->issueCommentUrl; - after_issueCommentUrl: $result['issue_comment_url'] = $issueCommentUrl; + if ($gravatarId === null) { + goto after_gravatarId; + } - $issueEventsUrl = $object->issueEventsUrl; - after_issueEventsUrl: $result['issue_events_url'] = $issueEventsUrl; + after_gravatarId: $result['gravatar_id'] = $gravatarId; - $issuesUrl = $object->issuesUrl; - after_issuesUrl: $result['issues_url'] = $issuesUrl; + $htmlUrl = $object->htmlUrl; - $keysUrl = $object->keysUrl; - after_keysUrl: $result['keys_url'] = $keysUrl; + if ($htmlUrl === null) { + goto after_htmlUrl; + } - $labelsUrl = $object->labelsUrl; - after_labelsUrl: $result['labels_url'] = $labelsUrl; + after_htmlUrl: $result['html_url'] = $htmlUrl; - $languagesUrl = $object->languagesUrl; - after_languagesUrl: $result['languages_url'] = $languagesUrl; + $id = $object->id; + after_id: $result['id'] = $id; - $mergesUrl = $object->mergesUrl; - after_mergesUrl: $result['merges_url'] = $mergesUrl; + $login = $object->login; + after_login: $result['login'] = $login; - $milestonesUrl = $object->milestonesUrl; - after_milestonesUrl: $result['milestones_url'] = $milestonesUrl; + $name = $object->name; - $name = $object->name; - after_name: $result['name'] = $name; + if ($name === null) { + goto after_name; + } - $notificationsUrl = $object->notificationsUrl; - after_notificationsUrl: $result['notifications_url'] = $notificationsUrl; + after_name: $result['name'] = $name; - $owner = $object->owner; - $owner = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo⚡️Owner($owner); - after_owner: $result['owner'] = $owner; + $nodeId = $object->nodeId; - $private = $object->private; - after_private: $result['private'] = $private; + if ($nodeId === null) { + goto after_nodeId; + } - $pullsUrl = $object->pullsUrl; - after_pullsUrl: $result['pulls_url'] = $pullsUrl; + after_nodeId: $result['node_id'] = $nodeId; - $releasesUrl = $object->releasesUrl; - after_releasesUrl: $result['releases_url'] = $releasesUrl; + $organizationsUrl = $object->organizationsUrl; - $stargazersUrl = $object->stargazersUrl; - after_stargazersUrl: $result['stargazers_url'] = $stargazersUrl; + if ($organizationsUrl === null) { + goto after_organizationsUrl; + } - $statusesUrl = $object->statusesUrl; - after_statusesUrl: $result['statuses_url'] = $statusesUrl; + after_organizationsUrl: $result['organizations_url'] = $organizationsUrl; - $subscribersUrl = $object->subscribersUrl; - after_subscribersUrl: $result['subscribers_url'] = $subscribersUrl; + $receivedEventsUrl = $object->receivedEventsUrl; - $subscriptionUrl = $object->subscriptionUrl; - after_subscriptionUrl: $result['subscription_url'] = $subscriptionUrl; + if ($receivedEventsUrl === null) { + goto after_receivedEventsUrl; + } - $tagsUrl = $object->tagsUrl; - after_tagsUrl: $result['tags_url'] = $tagsUrl; + after_receivedEventsUrl: $result['received_events_url'] = $receivedEventsUrl; - $teamsUrl = $object->teamsUrl; - after_teamsUrl: $result['teams_url'] = $teamsUrl; + $reposUrl = $object->reposUrl; - $treesUrl = $object->treesUrl; - after_treesUrl: $result['trees_url'] = $treesUrl; + if ($reposUrl === null) { + goto after_reposUrl; + } - $url = $object->url; - after_url: $result['url'] = $url; + after_reposUrl: $result['repos_url'] = $reposUrl; - $cloneUrl = $object->cloneUrl; - after_cloneUrl: $result['clone_url'] = $cloneUrl; + $siteAdmin = $object->siteAdmin; - $defaultBranch = $object->defaultBranch; - after_defaultBranch: $result['default_branch'] = $defaultBranch; + if ($siteAdmin === null) { + goto after_siteAdmin; + } - $forks = $object->forks; - after_forks: $result['forks'] = $forks; + after_siteAdmin: $result['site_admin'] = $siteAdmin; - $forksCount = $object->forksCount; - after_forksCount: $result['forks_count'] = $forksCount; + $starredUrl = $object->starredUrl; - $gitUrl = $object->gitUrl; - after_gitUrl: $result['git_url'] = $gitUrl; + if ($starredUrl === null) { + goto after_starredUrl; + } - $hasDownloads = $object->hasDownloads; - after_hasDownloads: $result['has_downloads'] = $hasDownloads; + after_starredUrl: $result['starred_url'] = $starredUrl; - $hasIssues = $object->hasIssues; - after_hasIssues: $result['has_issues'] = $hasIssues; + $subscriptionsUrl = $object->subscriptionsUrl; - $hasProjects = $object->hasProjects; - after_hasProjects: $result['has_projects'] = $hasProjects; + if ($subscriptionsUrl === null) { + goto after_subscriptionsUrl; + } - $hasWiki = $object->hasWiki; - after_hasWiki: $result['has_wiki'] = $hasWiki; + after_subscriptionsUrl: $result['subscriptions_url'] = $subscriptionsUrl; - $hasPages = $object->hasPages; - after_hasPages: $result['has_pages'] = $hasPages; + $type = $object->type; - $hasDiscussions = $object->hasDiscussions; - after_hasDiscussions: $result['has_discussions'] = $hasDiscussions; + if ($type === null) { + goto after_type; + } - $homepage = $object->homepage; + after_type: $result['type'] = $type; - if ($homepage === null) { - goto after_homepage; + $url = $object->url; + + if ($url === null) { + goto after_url; } - after_homepage: $result['homepage'] = $homepage; + after_url: $result['url'] = $url; - $language = $object->language; + $userViewType = $object->userViewType; - if ($language === null) { - goto after_language; + if ($userViewType === null) { + goto after_userViewType; } - after_language: $result['language'] = $language; + after_userViewType: $result['user_view_type'] = $userViewType; - $masterBranch = $object->masterBranch; + return $result; + } - if ($masterBranch === null) { - goto after_masterBranch; - } + private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️WebhookPullRequestClosed(mixed $object): mixed + { + assert($object instanceof WebhookPullRequestClosed); + $result = []; - after_masterBranch: $result['master_branch'] = $masterBranch; + $action = $object->action; + after_action: $result['action'] = $action; - $archived = $object->archived; - after_archived: $result['archived'] = $archived; + $enterprise = $object->enterprise; - $disabled = $object->disabled; - after_disabled: $result['disabled'] = $disabled; + if ($enterprise === null) { + goto after_enterprise; + } - $visibility = $object->visibility; + $enterprise = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️EnterpriseWebhooks($enterprise); + after_enterprise: $result['enterprise'] = $enterprise; - if ($visibility === null) { - goto after_visibility; + $installation = $object->installation; + + if ($installation === null) { + goto after_installation; } - after_visibility: $result['visibility'] = $visibility; + $installation = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleInstallation($installation); + after_installation: $result['installation'] = $installation; - $mirrorUrl = $object->mirrorUrl; + $number = $object->number; + after_number: $result['number'] = $number; - if ($mirrorUrl === null) { - goto after_mirrorUrl; + $organization = $object->organization; + + if ($organization === null) { + goto after_organization; } - after_mirrorUrl: $result['mirror_url'] = $mirrorUrl; + $organization = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️OrganizationSimpleWebhooks($organization); + after_organization: $result['organization'] = $organization; - $openIssues = $object->openIssues; - after_openIssues: $result['open_issues'] = $openIssues; + $pullRequest = $object->pullRequest; + $pullRequest = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest($pullRequest); + after_pullRequest: $result['pull_request'] = $pullRequest; - $openIssuesCount = $object->openIssuesCount; - after_openIssuesCount: $result['open_issues_count'] = $openIssuesCount; + $repository = $object->repository; + $repository = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️RepositoryWebhooks($repository); + after_repository: $result['repository'] = $repository; - $permissions = $object->permissions; + $sender = $object->sender; + $sender = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleUser($sender); + after_sender: $result['sender'] = $sender; - if ($permissions === null) { - goto after_permissions; - } + return $result; + } - $permissions = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo⚡️Permissions($permissions); - after_permissions: $result['permissions'] = $permissions; + private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest(mixed $object): mixed + { + assert($object instanceof \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest); + $result = []; - $tempCloneToken = $object->tempCloneToken; + $url = $object->url; + after_url: $result['url'] = $url; - if ($tempCloneToken === null) { - goto after_tempCloneToken; - } + $id = $object->id; + after_id: $result['id'] = $id; - after_tempCloneToken: $result['temp_clone_token'] = $tempCloneToken; + $nodeId = $object->nodeId; + after_nodeId: $result['node_id'] = $nodeId; - $allowMergeCommit = $object->allowMergeCommit; + $htmlUrl = $object->htmlUrl; + after_htmlUrl: $result['html_url'] = $htmlUrl; - if ($allowMergeCommit === null) { - goto after_allowMergeCommit; - } + $diffUrl = $object->diffUrl; + after_diffUrl: $result['diff_url'] = $diffUrl; - after_allowMergeCommit: $result['allow_merge_commit'] = $allowMergeCommit; + $patchUrl = $object->patchUrl; + after_patchUrl: $result['patch_url'] = $patchUrl; - $allowSquashMerge = $object->allowSquashMerge; + $issueUrl = $object->issueUrl; + after_issueUrl: $result['issue_url'] = $issueUrl; - if ($allowSquashMerge === null) { - goto after_allowSquashMerge; - } + $commitsUrl = $object->commitsUrl; + after_commitsUrl: $result['commits_url'] = $commitsUrl; - after_allowSquashMerge: $result['allow_squash_merge'] = $allowSquashMerge; + $reviewCommentsUrl = $object->reviewCommentsUrl; + after_reviewCommentsUrl: $result['review_comments_url'] = $reviewCommentsUrl; - $allowRebaseMerge = $object->allowRebaseMerge; + $reviewCommentUrl = $object->reviewCommentUrl; + after_reviewCommentUrl: $result['review_comment_url'] = $reviewCommentUrl; - if ($allowRebaseMerge === null) { - goto after_allowRebaseMerge; - } + $commentsUrl = $object->commentsUrl; + after_commentsUrl: $result['comments_url'] = $commentsUrl; - after_allowRebaseMerge: $result['allow_rebase_merge'] = $allowRebaseMerge; + $statusesUrl = $object->statusesUrl; + after_statusesUrl: $result['statuses_url'] = $statusesUrl; - $license = $object->license; + $number = $object->number; + after_number: $result['number'] = $number; - if ($license === null) { - goto after_license; - } + $state = $object->state; + after_state: $result['state'] = $state; - $license = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo⚡️License($license); - after_license: $result['license'] = $license; + $locked = $object->locked; + after_locked: $result['locked'] = $locked; - $pushedAt = $object->pushedAt; - after_pushedAt: $result['pushed_at'] = $pushedAt; + $title = $object->title; + after_title: $result['title'] = $title; - $size = $object->size; - after_size: $result['size'] = $size; + $user = $object->user; + $user = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleUser($user); + after_user: $result['user'] = $user; - $sshUrl = $object->sshUrl; - after_sshUrl: $result['ssh_url'] = $sshUrl; + $body = $object->body; - $stargazersCount = $object->stargazersCount; - after_stargazersCount: $result['stargazers_count'] = $stargazersCount; + if ($body === null) { + goto after_body; + } - $svnUrl = $object->svnUrl; - after_svnUrl: $result['svn_url'] = $svnUrl; + after_body: $result['body'] = $body; - $topics = $object->topics; + $labels = $object->labels; + static $labelsSerializer0; - if ($topics === null) { - goto after_topics; + if ($labelsSerializer0 === null) { + $labelsSerializer0 = new SerializeArrayItems(...[]); } - static $topicsSerializer0; + $labels = $labelsSerializer0->serialize($labels, $this); + after_labels: $result['labels'] = $labels; - if ($topicsSerializer0 === null) { - $topicsSerializer0 = new SerializeArrayItems(...[]); + $milestone = $object->milestone; + + if ($milestone === null) { + goto after_milestone; } - $topics = $topicsSerializer0->serialize($topics, $this); - after_topics: $result['topics'] = $topics; + $milestone = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Milestone($milestone); + after_milestone: $result['milestone'] = $milestone; - $watchers = $object->watchers; - after_watchers: $result['watchers'] = $watchers; + $activeLockReason = $object->activeLockReason; - $watchersCount = $object->watchersCount; - after_watchersCount: $result['watchers_count'] = $watchersCount; + if ($activeLockReason === null) { + goto after_activeLockReason; + } + + after_activeLockReason: $result['active_lock_reason'] = $activeLockReason; $createdAt = $object->createdAt; after_createdAt: $result['created_at'] = $createdAt; @@ -103315,252 +100773,251 @@ private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseClou $updatedAt = $object->updatedAt; after_updatedAt: $result['updated_at'] = $updatedAt; - $allowForking = $object->allowForking; + $closedAt = $object->closedAt; - if ($allowForking === null) { - goto after_allowForking; + if ($closedAt === null) { + goto after_closedAt; } - after_allowForking: $result['allow_forking'] = $allowForking; + after_closedAt: $result['closed_at'] = $closedAt; - $isTemplate = $object->isTemplate; + $mergedAt = $object->mergedAt; - if ($isTemplate === null) { - goto after_isTemplate; + if ($mergedAt === null) { + goto after_mergedAt; } - after_isTemplate: $result['is_template'] = $isTemplate; + after_mergedAt: $result['merged_at'] = $mergedAt; - $webCommitSignoffRequired = $object->webCommitSignoffRequired; + $mergeCommitSha = $object->mergeCommitSha; - if ($webCommitSignoffRequired === null) { - goto after_webCommitSignoffRequired; + if ($mergeCommitSha === null) { + goto after_mergeCommitSha; } - after_webCommitSignoffRequired: $result['web_commit_signoff_required'] = $webCommitSignoffRequired; + after_mergeCommitSha: $result['merge_commit_sha'] = $mergeCommitSha; - return $result; - } + $assignee = $object->assignee; - private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo⚡️Owner(mixed $object): mixed - { - assert($object instanceof \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo\Owner); - $result = []; + if ($assignee === null) { + goto after_assignee; + } - $avatarUrl = $object->avatarUrl; - after_avatarUrl: $result['avatar_url'] = $avatarUrl; + $assignee = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleUser($assignee); + after_assignee: $result['assignee'] = $assignee; - $eventsUrl = $object->eventsUrl; - after_eventsUrl: $result['events_url'] = $eventsUrl; + $assignees = $object->assignees; - $followersUrl = $object->followersUrl; - after_followersUrl: $result['followers_url'] = $followersUrl; + if ($assignees === null) { + goto after_assignees; + } - $followingUrl = $object->followingUrl; - after_followingUrl: $result['following_url'] = $followingUrl; + static $assigneesSerializer0; - $gistsUrl = $object->gistsUrl; - after_gistsUrl: $result['gists_url'] = $gistsUrl; + if ($assigneesSerializer0 === null) { + $assigneesSerializer0 = new SerializeArrayItems(...[]); + } - $gravatarId = $object->gravatarId; + $assignees = $assigneesSerializer0->serialize($assignees, $this); + after_assignees: $result['assignees'] = $assignees; - if ($gravatarId === null) { - goto after_gravatarId; - } + $requestedReviewers = $object->requestedReviewers; - after_gravatarId: $result['gravatar_id'] = $gravatarId; + if ($requestedReviewers === null) { + goto after_requestedReviewers; + } - $htmlUrl = $object->htmlUrl; - after_htmlUrl: $result['html_url'] = $htmlUrl; + static $requestedReviewersSerializer0; - $id = $object->id; - after_id: $result['id'] = $id; + if ($requestedReviewersSerializer0 === null) { + $requestedReviewersSerializer0 = new SerializeArrayItems(...[]); + } - $nodeId = $object->nodeId; - after_nodeId: $result['node_id'] = $nodeId; + $requestedReviewers = $requestedReviewersSerializer0->serialize($requestedReviewers, $this); + after_requestedReviewers: $result['requested_reviewers'] = $requestedReviewers; - $login = $object->login; - after_login: $result['login'] = $login; + $requestedTeams = $object->requestedTeams; - $organizationsUrl = $object->organizationsUrl; - after_organizationsUrl: $result['organizations_url'] = $organizationsUrl; + if ($requestedTeams === null) { + goto after_requestedTeams; + } - $receivedEventsUrl = $object->receivedEventsUrl; - after_receivedEventsUrl: $result['received_events_url'] = $receivedEventsUrl; + static $requestedTeamsSerializer0; - $reposUrl = $object->reposUrl; - after_reposUrl: $result['repos_url'] = $reposUrl; + if ($requestedTeamsSerializer0 === null) { + $requestedTeamsSerializer0 = new SerializeArrayItems(...[]); + } - $siteAdmin = $object->siteAdmin; - after_siteAdmin: $result['site_admin'] = $siteAdmin; + $requestedTeams = $requestedTeamsSerializer0->serialize($requestedTeams, $this); + after_requestedTeams: $result['requested_teams'] = $requestedTeams; - $starredUrl = $object->starredUrl; - after_starredUrl: $result['starred_url'] = $starredUrl; + $head = $object->head; + $head = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head($head); + after_head: $result['head'] = $head; - $subscriptionsUrl = $object->subscriptionsUrl; - after_subscriptionsUrl: $result['subscriptions_url'] = $subscriptionsUrl; + $base = $object->base; + $base = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base($base); + after_base: $result['base'] = $base; - $type = $object->type; - after_type: $result['type'] = $type; + $links = $object->links; + $links = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Links($links); + after_links: $result['_links'] = $links; - $url = $object->url; - after_url: $result['url'] = $url; + $authorAssociation = $object->authorAssociation; + after_authorAssociation: $result['author_association'] = $authorAssociation; - $userViewType = $object->userViewType; + $autoMerge = $object->autoMerge; - if ($userViewType === null) { - goto after_userViewType; + if ($autoMerge === null) { + goto after_autoMerge; } - after_userViewType: $result['user_view_type'] = $userViewType; + $autoMerge = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️AutoMerge($autoMerge); + after_autoMerge: $result['auto_merge'] = $autoMerge; - return $result; - } + $draft = $object->draft; - private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo⚡️Permissions(mixed $object): mixed - { - assert($object instanceof \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo\Permissions); - $result = []; + if ($draft === null) { + goto after_draft; + } - $admin = $object->admin; - after_admin: $result['admin'] = $admin; + after_draft: $result['draft'] = $draft; - $maintain = $object->maintain; + $merged = $object->merged; + after_merged: $result['merged'] = $merged; - if ($maintain === null) { - goto after_maintain; - } + $mergeable = $object->mergeable; - after_maintain: $result['maintain'] = $maintain; + if ($mergeable === null) { + goto after_mergeable; + } - $push = $object->push; - after_push: $result['push'] = $push; + after_mergeable: $result['mergeable'] = $mergeable; - $triage = $object->triage; + $rebaseable = $object->rebaseable; - if ($triage === null) { - goto after_triage; + if ($rebaseable === null) { + goto after_rebaseable; } - after_triage: $result['triage'] = $triage; - - $pull = $object->pull; - after_pull: $result['pull'] = $pull; + after_rebaseable: $result['rebaseable'] = $rebaseable; - return $result; - } + $mergeableState = $object->mergeableState; + after_mergeableState: $result['mergeable_state'] = $mergeableState; - private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️Repo⚡️License(mixed $object): mixed - { - assert($object instanceof \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\Repo\License); - $result = []; + $mergedBy = $object->mergedBy; - $key = $object->key; - after_key: $result['key'] = $key; + if ($mergedBy === null) { + goto after_mergedBy; + } - $name = $object->name; - after_name: $result['name'] = $name; + $mergedBy = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleUser($mergedBy); + after_mergedBy: $result['merged_by'] = $mergedBy; - $url = $object->url; + $comments = $object->comments; + after_comments: $result['comments'] = $comments; - if ($url === null) { - goto after_url; - } + $reviewComments = $object->reviewComments; + after_reviewComments: $result['review_comments'] = $reviewComments; - after_url: $result['url'] = $url; + $maintainerCanModify = $object->maintainerCanModify; + after_maintainerCanModify: $result['maintainer_can_modify'] = $maintainerCanModify; - $spdxId = $object->spdxId; + $commits = $object->commits; + after_commits: $result['commits'] = $commits; - if ($spdxId === null) { - goto after_spdxId; - } + $additions = $object->additions; + after_additions: $result['additions'] = $additions; - after_spdxId: $result['spdx_id'] = $spdxId; + $deletions = $object->deletions; + after_deletions: $result['deletions'] = $deletions; - $nodeId = $object->nodeId; - after_nodeId: $result['node_id'] = $nodeId; + $changedFiles = $object->changedFiles; + after_changedFiles: $result['changed_files'] = $changedFiles; return $result; } - private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head⚡️User(mixed $object): mixed + private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Milestone(mixed $object): mixed { - assert($object instanceof \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head\User); + assert($object instanceof \ApiClients\Client\GitHubEnterpriseCloud\Schema\Milestone); $result = []; - $avatarUrl = $object->avatarUrl; - after_avatarUrl: $result['avatar_url'] = $avatarUrl; + $url = $object->url; + after_url: $result['url'] = $url; - $eventsUrl = $object->eventsUrl; - after_eventsUrl: $result['events_url'] = $eventsUrl; + $htmlUrl = $object->htmlUrl; + after_htmlUrl: $result['html_url'] = $htmlUrl; - $followersUrl = $object->followersUrl; - after_followersUrl: $result['followers_url'] = $followersUrl; + $labelsUrl = $object->labelsUrl; + after_labelsUrl: $result['labels_url'] = $labelsUrl; - $followingUrl = $object->followingUrl; - after_followingUrl: $result['following_url'] = $followingUrl; + $id = $object->id; + after_id: $result['id'] = $id; - $gistsUrl = $object->gistsUrl; - after_gistsUrl: $result['gists_url'] = $gistsUrl; + $nodeId = $object->nodeId; + after_nodeId: $result['node_id'] = $nodeId; - $gravatarId = $object->gravatarId; + $number = $object->number; + after_number: $result['number'] = $number; - if ($gravatarId === null) { - goto after_gravatarId; - } + $state = $object->state; + after_state: $result['state'] = $state; - after_gravatarId: $result['gravatar_id'] = $gravatarId; + $title = $object->title; + after_title: $result['title'] = $title; - $htmlUrl = $object->htmlUrl; - after_htmlUrl: $result['html_url'] = $htmlUrl; + $description = $object->description; - $id = $object->id; - after_id: $result['id'] = $id; + if ($description === null) { + goto after_description; + } - $nodeId = $object->nodeId; - after_nodeId: $result['node_id'] = $nodeId; + after_description: $result['description'] = $description; - $login = $object->login; - after_login: $result['login'] = $login; + $creator = $object->creator; - $organizationsUrl = $object->organizationsUrl; - after_organizationsUrl: $result['organizations_url'] = $organizationsUrl; + if ($creator === null) { + goto after_creator; + } - $receivedEventsUrl = $object->receivedEventsUrl; - after_receivedEventsUrl: $result['received_events_url'] = $receivedEventsUrl; + $creator = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleUser($creator); + after_creator: $result['creator'] = $creator; - $reposUrl = $object->reposUrl; - after_reposUrl: $result['repos_url'] = $reposUrl; + $openIssues = $object->openIssues; + after_openIssues: $result['open_issues'] = $openIssues; - $siteAdmin = $object->siteAdmin; - after_siteAdmin: $result['site_admin'] = $siteAdmin; + $closedIssues = $object->closedIssues; + after_closedIssues: $result['closed_issues'] = $closedIssues; - $starredUrl = $object->starredUrl; - after_starredUrl: $result['starred_url'] = $starredUrl; + $createdAt = $object->createdAt; + after_createdAt: $result['created_at'] = $createdAt; - $subscriptionsUrl = $object->subscriptionsUrl; - after_subscriptionsUrl: $result['subscriptions_url'] = $subscriptionsUrl; + $updatedAt = $object->updatedAt; + after_updatedAt: $result['updated_at'] = $updatedAt; - $type = $object->type; - after_type: $result['type'] = $type; + $closedAt = $object->closedAt; - $url = $object->url; - after_url: $result['url'] = $url; + if ($closedAt === null) { + goto after_closedAt; + } - $userViewType = $object->userViewType; + after_closedAt: $result['closed_at'] = $closedAt; - if ($userViewType === null) { - goto after_userViewType; + $dueOn = $object->dueOn; + + if ($dueOn === null) { + goto after_dueOn; } - after_userViewType: $result['user_view_type'] = $userViewType; + after_dueOn: $result['due_on'] = $dueOn; return $result; } - private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base(mixed $object): mixed + private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Head(mixed $object): mixed { - assert($object instanceof \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base); + assert($object instanceof \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Head); $result = []; $label = $object->label; @@ -103570,24 +101027,81 @@ private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseClou after_ref: $result['ref'] = $ref; $repo = $object->repo; - $repo = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️Repo($repo); + $repo = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Repository($repo); after_repo: $result['repo'] = $repo; $sha = $object->sha; after_sha: $result['sha'] = $sha; $user = $object->user; - $user = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️User($user); + $user = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleUser($user); after_user: $result['user'] = $user; return $result; } - private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️Repo(mixed $object): mixed + private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Repository(mixed $object): mixed { - assert($object instanceof \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo); + assert($object instanceof Repository); $result = []; + $id = $object->id; + after_id: $result['id'] = $id; + + $nodeId = $object->nodeId; + after_nodeId: $result['node_id'] = $nodeId; + + $name = $object->name; + after_name: $result['name'] = $name; + + $fullName = $object->fullName; + after_fullName: $result['full_name'] = $fullName; + + $license = $object->license; + + if ($license === null) { + goto after_license; + } + + $license = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️LicenseSimple($license); + after_license: $result['license'] = $license; + + $forks = $object->forks; + after_forks: $result['forks'] = $forks; + + $permissions = $object->permissions; + + if ($permissions === null) { + goto after_permissions; + } + + $permissions = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Repository⚡️Permissions($permissions); + after_permissions: $result['permissions'] = $permissions; + + $owner = $object->owner; + $owner = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleUser($owner); + after_owner: $result['owner'] = $owner; + + $private = $object->private; + after_private: $result['private'] = $private; + + $htmlUrl = $object->htmlUrl; + after_htmlUrl: $result['html_url'] = $htmlUrl; + + $description = $object->description; + + if ($description === null) { + goto after_description; + } + + after_description: $result['description'] = $description; + + $fork = $object->fork; + after_fork: $result['fork'] = $fork; + + $url = $object->url; + after_url: $result['url'] = $url; + $archiveUrl = $object->archiveUrl; after_archiveUrl: $result['archive_url'] = $archiveUrl; @@ -103621,29 +101135,15 @@ private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseClou $deploymentsUrl = $object->deploymentsUrl; after_deploymentsUrl: $result['deployments_url'] = $deploymentsUrl; - $description = $object->description; - - if ($description === null) { - goto after_description; - } - - after_description: $result['description'] = $description; - $downloadsUrl = $object->downloadsUrl; after_downloadsUrl: $result['downloads_url'] = $downloadsUrl; $eventsUrl = $object->eventsUrl; after_eventsUrl: $result['events_url'] = $eventsUrl; - $fork = $object->fork; - after_fork: $result['fork'] = $fork; - $forksUrl = $object->forksUrl; after_forksUrl: $result['forks_url'] = $forksUrl; - $fullName = $object->fullName; - after_fullName: $result['full_name'] = $fullName; - $gitCommitsUrl = $object->gitCommitsUrl; after_gitCommitsUrl: $result['git_commits_url'] = $gitCommitsUrl; @@ -103653,25 +101153,8 @@ private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseClou $gitTagsUrl = $object->gitTagsUrl; after_gitTagsUrl: $result['git_tags_url'] = $gitTagsUrl; - $hooksUrl = $object->hooksUrl; - after_hooksUrl: $result['hooks_url'] = $hooksUrl; - - $htmlUrl = $object->htmlUrl; - after_htmlUrl: $result['html_url'] = $htmlUrl; - - $id = $object->id; - after_id: $result['id'] = $id; - - $isTemplate = $object->isTemplate; - - if ($isTemplate === null) { - goto after_isTemplate; - } - - after_isTemplate: $result['is_template'] = $isTemplate; - - $nodeId = $object->nodeId; - after_nodeId: $result['node_id'] = $nodeId; + $gitUrl = $object->gitUrl; + after_gitUrl: $result['git_url'] = $gitUrl; $issueCommentUrl = $object->issueCommentUrl; after_issueCommentUrl: $result['issue_comment_url'] = $issueCommentUrl; @@ -103697,25 +101180,18 @@ private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseClou $milestonesUrl = $object->milestonesUrl; after_milestonesUrl: $result['milestones_url'] = $milestonesUrl; - $name = $object->name; - after_name: $result['name'] = $name; - $notificationsUrl = $object->notificationsUrl; after_notificationsUrl: $result['notifications_url'] = $notificationsUrl; - $owner = $object->owner; - $owner = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️Repo⚡️Owner($owner); - after_owner: $result['owner'] = $owner; - - $private = $object->private; - after_private: $result['private'] = $private; - $pullsUrl = $object->pullsUrl; after_pullsUrl: $result['pulls_url'] = $pullsUrl; $releasesUrl = $object->releasesUrl; after_releasesUrl: $result['releases_url'] = $releasesUrl; + $sshUrl = $object->sshUrl; + after_sshUrl: $result['ssh_url'] = $sshUrl; + $stargazersUrl = $object->stargazersUrl; after_stargazersUrl: $result['stargazers_url'] = $stargazersUrl; @@ -103737,41 +101213,22 @@ private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseClou $treesUrl = $object->treesUrl; after_treesUrl: $result['trees_url'] = $treesUrl; - $url = $object->url; - after_url: $result['url'] = $url; - $cloneUrl = $object->cloneUrl; after_cloneUrl: $result['clone_url'] = $cloneUrl; - $defaultBranch = $object->defaultBranch; - after_defaultBranch: $result['default_branch'] = $defaultBranch; - - $forks = $object->forks; - after_forks: $result['forks'] = $forks; - - $forksCount = $object->forksCount; - after_forksCount: $result['forks_count'] = $forksCount; - - $gitUrl = $object->gitUrl; - after_gitUrl: $result['git_url'] = $gitUrl; - - $hasDownloads = $object->hasDownloads; - after_hasDownloads: $result['has_downloads'] = $hasDownloads; - - $hasIssues = $object->hasIssues; - after_hasIssues: $result['has_issues'] = $hasIssues; + $mirrorUrl = $object->mirrorUrl; - $hasProjects = $object->hasProjects; - after_hasProjects: $result['has_projects'] = $hasProjects; + if ($mirrorUrl === null) { + goto after_mirrorUrl; + } - $hasWiki = $object->hasWiki; - after_hasWiki: $result['has_wiki'] = $hasWiki; + after_mirrorUrl: $result['mirror_url'] = $mirrorUrl; - $hasPages = $object->hasPages; - after_hasPages: $result['has_pages'] = $hasPages; + $hooksUrl = $object->hooksUrl; + after_hooksUrl: $result['hooks_url'] = $hooksUrl; - $hasDiscussions = $object->hasDiscussions; - after_hasDiscussions: $result['has_discussions'] = $hasDiscussions; + $svnUrl = $object->svnUrl; + after_svnUrl: $result['svn_url'] = $svnUrl; $homepage = $object->homepage; @@ -103789,13 +101246,69 @@ private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseClou after_language: $result['language'] = $language; - $masterBranch = $object->masterBranch; + $forksCount = $object->forksCount; + after_forksCount: $result['forks_count'] = $forksCount; - if ($masterBranch === null) { - goto after_masterBranch; + $stargazersCount = $object->stargazersCount; + after_stargazersCount: $result['stargazers_count'] = $stargazersCount; + + $watchersCount = $object->watchersCount; + after_watchersCount: $result['watchers_count'] = $watchersCount; + + $size = $object->size; + after_size: $result['size'] = $size; + + $defaultBranch = $object->defaultBranch; + after_defaultBranch: $result['default_branch'] = $defaultBranch; + + $openIssuesCount = $object->openIssuesCount; + after_openIssuesCount: $result['open_issues_count'] = $openIssuesCount; + + $isTemplate = $object->isTemplate; + + if ($isTemplate === null) { + goto after_isTemplate; } - after_masterBranch: $result['master_branch'] = $masterBranch; + after_isTemplate: $result['is_template'] = $isTemplate; + + $topics = $object->topics; + + if ($topics === null) { + goto after_topics; + } + + static $topicsSerializer0; + + if ($topicsSerializer0 === null) { + $topicsSerializer0 = new SerializeArrayItems(...[]); + } + + $topics = $topicsSerializer0->serialize($topics, $this); + after_topics: $result['topics'] = $topics; + + $hasIssues = $object->hasIssues; + after_hasIssues: $result['has_issues'] = $hasIssues; + + $hasProjects = $object->hasProjects; + after_hasProjects: $result['has_projects'] = $hasProjects; + + $hasWiki = $object->hasWiki; + after_hasWiki: $result['has_wiki'] = $hasWiki; + + $hasPages = $object->hasPages; + after_hasPages: $result['has_pages'] = $hasPages; + + $hasDownloads = $object->hasDownloads; + after_hasDownloads: $result['has_downloads'] = $hasDownloads; + + $hasDiscussions = $object->hasDiscussions; + + if ($hasDiscussions === null) { + goto after_hasDiscussions; + } + + after_hasDiscussions: $result['has_discussions'] = $hasDiscussions; $archived = $object->archived; after_archived: $result['archived'] = $archived; @@ -103811,44 +101324,45 @@ private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseClou after_visibility: $result['visibility'] = $visibility; - $mirrorUrl = $object->mirrorUrl; + $pushedAt = $object->pushedAt; - if ($mirrorUrl === null) { - goto after_mirrorUrl; + if ($pushedAt === null) { + goto after_pushedAt; } - after_mirrorUrl: $result['mirror_url'] = $mirrorUrl; + after_pushedAt: $result['pushed_at'] = $pushedAt; - $openIssues = $object->openIssues; - after_openIssues: $result['open_issues'] = $openIssues; + $createdAt = $object->createdAt; - $openIssuesCount = $object->openIssuesCount; - after_openIssuesCount: $result['open_issues_count'] = $openIssuesCount; + if ($createdAt === null) { + goto after_createdAt; + } - $permissions = $object->permissions; + after_createdAt: $result['created_at'] = $createdAt; - if ($permissions === null) { - goto after_permissions; + $updatedAt = $object->updatedAt; + + if ($updatedAt === null) { + goto after_updatedAt; } - $permissions = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️Repo⚡️Permissions($permissions); - after_permissions: $result['permissions'] = $permissions; + after_updatedAt: $result['updated_at'] = $updatedAt; - $tempCloneToken = $object->tempCloneToken; + $allowRebaseMerge = $object->allowRebaseMerge; - if ($tempCloneToken === null) { - goto after_tempCloneToken; + if ($allowRebaseMerge === null) { + goto after_allowRebaseMerge; } - after_tempCloneToken: $result['temp_clone_token'] = $tempCloneToken; + after_allowRebaseMerge: $result['allow_rebase_merge'] = $allowRebaseMerge; - $allowMergeCommit = $object->allowMergeCommit; + $tempCloneToken = $object->tempCloneToken; - if ($allowMergeCommit === null) { - goto after_allowMergeCommit; + if ($tempCloneToken === null) { + goto after_tempCloneToken; } - after_allowMergeCommit: $result['allow_merge_commit'] = $allowMergeCommit; + after_tempCloneToken: $result['temp_clone_token'] = $tempCloneToken; $allowSquashMerge = $object->allowSquashMerge; @@ -103858,64 +101372,77 @@ private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseClou after_allowSquashMerge: $result['allow_squash_merge'] = $allowSquashMerge; - $allowRebaseMerge = $object->allowRebaseMerge; + $allowAutoMerge = $object->allowAutoMerge; - if ($allowRebaseMerge === null) { - goto after_allowRebaseMerge; + if ($allowAutoMerge === null) { + goto after_allowAutoMerge; } - after_allowRebaseMerge: $result['allow_rebase_merge'] = $allowRebaseMerge; + after_allowAutoMerge: $result['allow_auto_merge'] = $allowAutoMerge; - $license = $object->license; + $deleteBranchOnMerge = $object->deleteBranchOnMerge; - if ($license === null) { - goto after_license; + if ($deleteBranchOnMerge === null) { + goto after_deleteBranchOnMerge; } - $license = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️LicenseSimple($license); - after_license: $result['license'] = $license; + after_deleteBranchOnMerge: $result['delete_branch_on_merge'] = $deleteBranchOnMerge; - $pushedAt = $object->pushedAt; - after_pushedAt: $result['pushed_at'] = $pushedAt; + $allowUpdateBranch = $object->allowUpdateBranch; - $size = $object->size; - after_size: $result['size'] = $size; + if ($allowUpdateBranch === null) { + goto after_allowUpdateBranch; + } - $sshUrl = $object->sshUrl; - after_sshUrl: $result['ssh_url'] = $sshUrl; + after_allowUpdateBranch: $result['allow_update_branch'] = $allowUpdateBranch; - $stargazersCount = $object->stargazersCount; - after_stargazersCount: $result['stargazers_count'] = $stargazersCount; + $useSquashPrTitleAsDefault = $object->useSquashPrTitleAsDefault; - $svnUrl = $object->svnUrl; - after_svnUrl: $result['svn_url'] = $svnUrl; + if ($useSquashPrTitleAsDefault === null) { + goto after_useSquashPrTitleAsDefault; + } - $topics = $object->topics; + after_useSquashPrTitleAsDefault: $result['use_squash_pr_title_as_default'] = $useSquashPrTitleAsDefault; - if ($topics === null) { - goto after_topics; + $squashMergeCommitTitle = $object->squashMergeCommitTitle; + + if ($squashMergeCommitTitle === null) { + goto after_squashMergeCommitTitle; } - static $topicsSerializer0; + after_squashMergeCommitTitle: $result['squash_merge_commit_title'] = $squashMergeCommitTitle; - if ($topicsSerializer0 === null) { - $topicsSerializer0 = new SerializeArrayItems(...[]); + $squashMergeCommitMessage = $object->squashMergeCommitMessage; + + if ($squashMergeCommitMessage === null) { + goto after_squashMergeCommitMessage; } - $topics = $topicsSerializer0->serialize($topics, $this); - after_topics: $result['topics'] = $topics; + after_squashMergeCommitMessage: $result['squash_merge_commit_message'] = $squashMergeCommitMessage; - $watchers = $object->watchers; - after_watchers: $result['watchers'] = $watchers; + $mergeCommitTitle = $object->mergeCommitTitle; - $watchersCount = $object->watchersCount; - after_watchersCount: $result['watchers_count'] = $watchersCount; + if ($mergeCommitTitle === null) { + goto after_mergeCommitTitle; + } - $createdAt = $object->createdAt; - after_createdAt: $result['created_at'] = $createdAt; + after_mergeCommitTitle: $result['merge_commit_title'] = $mergeCommitTitle; - $updatedAt = $object->updatedAt; - after_updatedAt: $result['updated_at'] = $updatedAt; + $mergeCommitMessage = $object->mergeCommitMessage; + + if ($mergeCommitMessage === null) { + goto after_mergeCommitMessage; + } + + after_mergeCommitMessage: $result['merge_commit_message'] = $mergeCommitMessage; + + $allowMergeCommit = $object->allowMergeCommit; + + if ($allowMergeCommit === null) { + goto after_allowMergeCommit; + } + + after_allowMergeCommit: $result['allow_merge_commit'] = $allowMergeCommit; $allowForking = $object->allowForking; @@ -103933,188 +101460,93 @@ private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseClou after_webCommitSignoffRequired: $result['web_commit_signoff_required'] = $webCommitSignoffRequired; - return $result; - } - - private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️Repo⚡️Owner(mixed $object): mixed - { - assert($object instanceof \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo\Owner); - $result = []; - - $avatarUrl = $object->avatarUrl; - after_avatarUrl: $result['avatar_url'] = $avatarUrl; - - $eventsUrl = $object->eventsUrl; - after_eventsUrl: $result['events_url'] = $eventsUrl; - - $followersUrl = $object->followersUrl; - after_followersUrl: $result['followers_url'] = $followersUrl; - - $followingUrl = $object->followingUrl; - after_followingUrl: $result['following_url'] = $followingUrl; + $openIssues = $object->openIssues; + after_openIssues: $result['open_issues'] = $openIssues; - $gistsUrl = $object->gistsUrl; - after_gistsUrl: $result['gists_url'] = $gistsUrl; + $watchers = $object->watchers; + after_watchers: $result['watchers'] = $watchers; - $gravatarId = $object->gravatarId; + $masterBranch = $object->masterBranch; - if ($gravatarId === null) { - goto after_gravatarId; + if ($masterBranch === null) { + goto after_masterBranch; } - after_gravatarId: $result['gravatar_id'] = $gravatarId; - - $htmlUrl = $object->htmlUrl; - after_htmlUrl: $result['html_url'] = $htmlUrl; - - $id = $object->id; - after_id: $result['id'] = $id; - - $nodeId = $object->nodeId; - after_nodeId: $result['node_id'] = $nodeId; - - $login = $object->login; - after_login: $result['login'] = $login; - - $organizationsUrl = $object->organizationsUrl; - after_organizationsUrl: $result['organizations_url'] = $organizationsUrl; - - $receivedEventsUrl = $object->receivedEventsUrl; - after_receivedEventsUrl: $result['received_events_url'] = $receivedEventsUrl; - - $reposUrl = $object->reposUrl; - after_reposUrl: $result['repos_url'] = $reposUrl; - - $siteAdmin = $object->siteAdmin; - after_siteAdmin: $result['site_admin'] = $siteAdmin; - - $starredUrl = $object->starredUrl; - after_starredUrl: $result['starred_url'] = $starredUrl; + after_masterBranch: $result['master_branch'] = $masterBranch; - $subscriptionsUrl = $object->subscriptionsUrl; - after_subscriptionsUrl: $result['subscriptions_url'] = $subscriptionsUrl; + $starredAt = $object->starredAt; - $type = $object->type; - after_type: $result['type'] = $type; + if ($starredAt === null) { + goto after_starredAt; + } - $url = $object->url; - after_url: $result['url'] = $url; + after_starredAt: $result['starred_at'] = $starredAt; - $userViewType = $object->userViewType; + $anonymousAccessEnabled = $object->anonymousAccessEnabled; - if ($userViewType === null) { - goto after_userViewType; + if ($anonymousAccessEnabled === null) { + goto after_anonymousAccessEnabled; } - after_userViewType: $result['user_view_type'] = $userViewType; + after_anonymousAccessEnabled: $result['anonymous_access_enabled'] = $anonymousAccessEnabled; return $result; } - private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️Repo⚡️Permissions(mixed $object): mixed + private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Repository⚡️Permissions(mixed $object): mixed { - assert($object instanceof \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\Repo\Permissions); + assert($object instanceof \ApiClients\Client\GitHubEnterpriseCloud\Schema\Repository\Permissions); $result = []; $admin = $object->admin; after_admin: $result['admin'] = $admin; - $maintain = $object->maintain; + $pull = $object->pull; + after_pull: $result['pull'] = $pull; - if ($maintain === null) { - goto after_maintain; + $triage = $object->triage; + + if ($triage === null) { + goto after_triage; } - after_maintain: $result['maintain'] = $maintain; + after_triage: $result['triage'] = $triage; $push = $object->push; after_push: $result['push'] = $push; - $triage = $object->triage; + $maintain = $object->maintain; - if ($triage === null) { - goto after_triage; + if ($maintain === null) { + goto after_maintain; } - after_triage: $result['triage'] = $triage; - - $pull = $object->pull; - after_pull: $result['pull'] = $pull; + after_maintain: $result['maintain'] = $maintain; return $result; } - private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base⚡️User(mixed $object): mixed + private function serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️PullRequest⚡️Base(mixed $object): mixed { - assert($object instanceof \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base\User); + assert($object instanceof \ApiClients\Client\GitHubEnterpriseCloud\Schema\PullRequest\Base); $result = []; - $avatarUrl = $object->avatarUrl; - after_avatarUrl: $result['avatar_url'] = $avatarUrl; - - $eventsUrl = $object->eventsUrl; - after_eventsUrl: $result['events_url'] = $eventsUrl; - - $followersUrl = $object->followersUrl; - after_followersUrl: $result['followers_url'] = $followersUrl; - - $followingUrl = $object->followingUrl; - after_followingUrl: $result['following_url'] = $followingUrl; - - $gistsUrl = $object->gistsUrl; - after_gistsUrl: $result['gists_url'] = $gistsUrl; - - $gravatarId = $object->gravatarId; - - if ($gravatarId === null) { - goto after_gravatarId; - } - - after_gravatarId: $result['gravatar_id'] = $gravatarId; - - $htmlUrl = $object->htmlUrl; - after_htmlUrl: $result['html_url'] = $htmlUrl; - - $id = $object->id; - after_id: $result['id'] = $id; - - $nodeId = $object->nodeId; - after_nodeId: $result['node_id'] = $nodeId; - - $login = $object->login; - after_login: $result['login'] = $login; - - $organizationsUrl = $object->organizationsUrl; - after_organizationsUrl: $result['organizations_url'] = $organizationsUrl; - - $receivedEventsUrl = $object->receivedEventsUrl; - after_receivedEventsUrl: $result['received_events_url'] = $receivedEventsUrl; - - $reposUrl = $object->reposUrl; - after_reposUrl: $result['repos_url'] = $reposUrl; - - $siteAdmin = $object->siteAdmin; - after_siteAdmin: $result['site_admin'] = $siteAdmin; - - $starredUrl = $object->starredUrl; - after_starredUrl: $result['starred_url'] = $starredUrl; - - $subscriptionsUrl = $object->subscriptionsUrl; - after_subscriptionsUrl: $result['subscriptions_url'] = $subscriptionsUrl; - - $type = $object->type; - after_type: $result['type'] = $type; + $label = $object->label; + after_label: $result['label'] = $label; - $url = $object->url; - after_url: $result['url'] = $url; + $ref = $object->ref; + after_ref: $result['ref'] = $ref; - $userViewType = $object->userViewType; + $repo = $object->repo; + $repo = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️Repository($repo); + after_repo: $result['repo'] = $repo; - if ($userViewType === null) { - goto after_userViewType; - } + $sha = $object->sha; + after_sha: $result['sha'] = $sha; - after_userViewType: $result['user_view_type'] = $userViewType; + $user = $object->user; + $user = $this->serializeObjectApiClients⚡️Client⚡️GitHubEnterpriseCloud⚡️Schema⚡️SimpleUser($user); + after_user: $result['user'] = $user; return $result; } diff --git a/clients/GitHubEnterpriseCloud/src/Internal/Hydrators.php b/clients/GitHubEnterpriseCloud/src/Internal/Hydrators.php index 6849d3a05f5..c43395e6d29 100644 --- a/clients/GitHubEnterpriseCloud/src/Internal/Hydrators.php +++ b/clients/GitHubEnterpriseCloud/src/Internal/Hydrators.php @@ -1021,7 +1021,7 @@ public function hydrateObject(string $className, array $payload): object '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\PagesDeploymentStatus' => $this->getObjectMapperOperation🌀Repos🌀Owner🌀Repo🌀Pages🌀Deployments🌀PagesDeploymentId()->hydrateObject($className, $payload), '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\PagesHealthCheck', '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\PagesHealthCheck\\Domain', '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\PagesHealthCheck\\AltDomain' => $this->getObjectMapperOperation🌀Repos🌀Owner🌀Repo🌀Pages🌀Health()->hydrateObject($className, $payload), '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\Operations\\Repos\\CheckPrivateVulnerabilityReporting\\Response\\ApplicationJson\\Ok' => $this->getObjectMapperOperation🌀Repos🌀Owner🌀Repo🌀PrivateVulnerabilityReporting()->hydrateObject($className, $payload), - '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\PullRequest', '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\PullRequest\\Head', '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\PullRequest\\Head\\Repo', '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\PullRequest\\Head\\Repo\\Owner', '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\PullRequest\\Head\\Repo\\Permissions', '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\PullRequest\\Head\\Repo\\License', '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\PullRequest\\Head\\User', '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\PullRequest\\Base', '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\PullRequest\\Base\\Repo', '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\PullRequest\\Base\\Repo\\Owner', '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\PullRequest\\Base\\Repo\\Permissions', '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\PullRequest\\Base\\User', '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\PullRequest\\Links', '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\Link', '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\AutoMerge' => $this->getObjectMapperOperation🌀Repos🌀Owner🌀Repo🌀Pulls()->hydrateObject($className, $payload), + '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\PullRequest', '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\PullRequest\\Head', '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\PullRequest\\Base', '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\PullRequest\\Links', '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\Link', '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\AutoMerge' => $this->getObjectMapperOperation🌀Repos🌀Owner🌀Repo🌀Pulls()->hydrateObject($className, $payload), '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\PullRequestReviewComment', '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\PullRequestReviewComment\\Links', '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\PullRequestReviewComment\\Links\\Self_', '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\PullRequestReviewComment\\Links\\Html', '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\PullRequestReviewComment\\Links\\PullRequest' => $this->getObjectMapperOperation🌀Repos🌀Owner🌀Repo🌀Pulls🌀Comments🌀CommentId()->hydrateObject($className, $payload), '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\PullRequestMergeResult', '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\Operations\\Pulls\\Merge\\Response\\ApplicationJson\\MethodNotAllowed\\Application\\Json', '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\Operations\\Pulls\\Merge\\Response\\ApplicationJson\\Conflict\\Application\\Json' => $this->getObjectMapperOperation🌀Repos🌀Owner🌀Repo🌀Pulls🌀PullNumber🌀Merge()->hydrateObject($className, $payload), '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\PullRequestReviewRequest', '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\PullRequestSimple', '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\PullRequestSimple\\Head', '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\PullRequestSimple\\Base', '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\PullRequestSimple\\Links' => $this->getObjectMapperOperation🌀Repos🌀Owner🌀Repo🌀Pulls🌀PullNumber🌀RequestedReviewers()->hydrateObject($className, $payload), @@ -1401,7 +1401,7 @@ public function serializeObjectOfType(object $object, string $className): mixed '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\PagesDeploymentStatus' => $this->getObjectMapperOperation🌀Repos🌀Owner🌀Repo🌀Pages🌀Deployments🌀PagesDeploymentId()->serializeObject($object), '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\PagesHealthCheck', '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\PagesHealthCheck\\Domain', '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\PagesHealthCheck\\AltDomain' => $this->getObjectMapperOperation🌀Repos🌀Owner🌀Repo🌀Pages🌀Health()->serializeObject($object), '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\Operations\\Repos\\CheckPrivateVulnerabilityReporting\\Response\\ApplicationJson\\Ok' => $this->getObjectMapperOperation🌀Repos🌀Owner🌀Repo🌀PrivateVulnerabilityReporting()->serializeObject($object), - '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\PullRequest', '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\PullRequest\\Head', '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\PullRequest\\Head\\Repo', '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\PullRequest\\Head\\Repo\\Owner', '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\PullRequest\\Head\\Repo\\Permissions', '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\PullRequest\\Head\\Repo\\License', '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\PullRequest\\Head\\User', '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\PullRequest\\Base', '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\PullRequest\\Base\\Repo', '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\PullRequest\\Base\\Repo\\Owner', '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\PullRequest\\Base\\Repo\\Permissions', '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\PullRequest\\Base\\User', '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\PullRequest\\Links', '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\Link', '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\AutoMerge' => $this->getObjectMapperOperation🌀Repos🌀Owner🌀Repo🌀Pulls()->serializeObject($object), + '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\PullRequest', '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\PullRequest\\Head', '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\PullRequest\\Base', '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\PullRequest\\Links', '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\Link', '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\AutoMerge' => $this->getObjectMapperOperation🌀Repos🌀Owner🌀Repo🌀Pulls()->serializeObject($object), '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\PullRequestReviewComment', '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\PullRequestReviewComment\\Links', '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\PullRequestReviewComment\\Links\\Self_', '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\PullRequestReviewComment\\Links\\Html', '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\PullRequestReviewComment\\Links\\PullRequest' => $this->getObjectMapperOperation🌀Repos🌀Owner🌀Repo🌀Pulls🌀Comments🌀CommentId()->serializeObject($object), '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\PullRequestMergeResult', '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\Operations\\Pulls\\Merge\\Response\\ApplicationJson\\MethodNotAllowed\\Application\\Json', '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\Operations\\Pulls\\Merge\\Response\\ApplicationJson\\Conflict\\Application\\Json' => $this->getObjectMapperOperation🌀Repos🌀Owner🌀Repo🌀Pulls🌀PullNumber🌀Merge()->serializeObject($object), '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\PullRequestReviewRequest', '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\PullRequestSimple', '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\PullRequestSimple\\Head', '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\PullRequestSimple\\Base', '\\ApiClients\\Client\\GitHubEnterpriseCloud\\Schema\\PullRequestSimple\\Links' => $this->getObjectMapperOperation🌀Repos🌀Owner🌀Repo🌀Pulls🌀PullNumber🌀RequestedReviewers()->serializeObject($object), diff --git a/clients/GitHubEnterpriseCloud/src/Schema/AliasAbstract/Tiet51848752/TietF5AFF89A/Tiet1BF2E786/Tiet3454ABD5.php b/clients/GitHubEnterpriseCloud/src/Schema/AliasAbstract/Tiet51848752/TietF5AFF89A/Tiet1BF2E786/Tiet3454ABD5.php deleted file mode 100644 index 3ab66cc1258..00000000000 --- a/clients/GitHubEnterpriseCloud/src/Schema/AliasAbstract/Tiet51848752/TietF5AFF89A/Tiet1BF2E786/Tiet3454ABD5.php +++ /dev/null @@ -1,146 +0,0 @@ -