-
-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
17 changed files
with
438 additions
and
0 deletions.
There are no files selected for viewing
29 changes: 29 additions & 0 deletions
29
tests/Generator/Client/resource/php_test/BinaryException.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
<?php | ||
/** | ||
* BinaryException automatically generated by SDKgen please do not edit this file manually | ||
* @see https://sdkgen.app | ||
*/ | ||
|
||
namespace Sdkgen\Client\Tests\Generated; | ||
|
||
use Sdkgen\Client\Exception\KnownStatusCodeException; | ||
|
||
class BinaryException extends KnownStatusCodeException | ||
{ | ||
private \Psr\Http\Message\StreamInterface $payload; | ||
|
||
public function __construct(\Psr\Http\Message\StreamInterface $payload) | ||
{ | ||
parent::__construct('The server returned an error'); | ||
|
||
$this->payload = $payload; | ||
} | ||
|
||
/** | ||
* @return \Psr\Http\Message\StreamInterface | ||
*/ | ||
public function getPayload(): \Psr\Http\Message\StreamInterface | ||
{ | ||
return $this->payload; | ||
} | ||
} |
29 changes: 29 additions & 0 deletions
29
tests/Generator/Client/resource/php_test/FormException.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
<?php | ||
/** | ||
* FormException automatically generated by SDKgen please do not edit this file manually | ||
* @see https://sdkgen.app | ||
*/ | ||
|
||
namespace Sdkgen\Client\Tests\Generated; | ||
|
||
use Sdkgen\Client\Exception\KnownStatusCodeException; | ||
|
||
class FormException extends KnownStatusCodeException | ||
{ | ||
private array $payload; | ||
|
||
public function __construct(array $payload) | ||
{ | ||
parent::__construct('The server returned an error'); | ||
|
||
$this->payload = $payload; | ||
} | ||
|
||
/** | ||
* @return array | ||
*/ | ||
public function getPayload(): array | ||
{ | ||
return $this->payload; | ||
} | ||
} |
29 changes: 29 additions & 0 deletions
29
tests/Generator/Client/resource/php_test/JsonException.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
<?php | ||
/** | ||
* JsonException automatically generated by SDKgen please do not edit this file manually | ||
* @see https://sdkgen.app | ||
*/ | ||
|
||
namespace Sdkgen\Client\Tests\Generated; | ||
|
||
use Sdkgen\Client\Exception\KnownStatusCodeException; | ||
|
||
class JsonException extends KnownStatusCodeException | ||
{ | ||
private \stdClass $payload; | ||
|
||
public function __construct(\stdClass $payload) | ||
{ | ||
parent::__construct('The server returned an error'); | ||
|
||
$this->payload = $payload; | ||
} | ||
|
||
/** | ||
* @return \stdClass | ||
*/ | ||
public function getPayload(): \stdClass | ||
{ | ||
return $this->payload; | ||
} | ||
} |
29 changes: 29 additions & 0 deletions
29
tests/Generator/Client/resource/php_test/MultipartException.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
<?php | ||
/** | ||
* MultipartException automatically generated by SDKgen please do not edit this file manually | ||
* @see https://sdkgen.app | ||
*/ | ||
|
||
namespace Sdkgen\Client\Tests\Generated; | ||
|
||
use Sdkgen\Client\Exception\KnownStatusCodeException; | ||
|
||
class MultipartException extends KnownStatusCodeException | ||
{ | ||
private array $payload; | ||
|
||
public function __construct(array $payload) | ||
{ | ||
parent::__construct('The server returned an error'); | ||
|
||
$this->payload = $payload; | ||
} | ||
|
||
/** | ||
* @return array | ||
*/ | ||
public function getPayload(): array | ||
{ | ||
return $this->payload; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
29 changes: 29 additions & 0 deletions
29
tests/Generator/Client/resource/php_test/TestResponseException.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
<?php | ||
/** | ||
* TestResponseException automatically generated by SDKgen please do not edit this file manually | ||
* @see https://sdkgen.app | ||
*/ | ||
|
||
namespace Sdkgen\Client\Tests\Generated; | ||
|
||
use Sdkgen\Client\Exception\KnownStatusCodeException; | ||
|
||
class TestResponseException extends KnownStatusCodeException | ||
{ | ||
private TestResponse $payload; | ||
|
||
public function __construct(TestResponse $payload) | ||
{ | ||
parent::__construct('The server returned an error'); | ||
|
||
$this->payload = $payload; | ||
} | ||
|
||
/** | ||
* @return TestResponse | ||
*/ | ||
public function getPayload(): TestResponse | ||
{ | ||
return $this->payload; | ||
} | ||
} |
29 changes: 29 additions & 0 deletions
29
tests/Generator/Client/resource/php_test/TextException.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
<?php | ||
/** | ||
* TextException automatically generated by SDKgen please do not edit this file manually | ||
* @see https://sdkgen.app | ||
*/ | ||
|
||
namespace Sdkgen\Client\Tests\Generated; | ||
|
||
use Sdkgen\Client\Exception\KnownStatusCodeException; | ||
|
||
class TextException extends KnownStatusCodeException | ||
{ | ||
private string $payload; | ||
|
||
public function __construct(string $payload) | ||
{ | ||
parent::__construct('The server returned an error'); | ||
|
||
$this->payload = $payload; | ||
} | ||
|
||
/** | ||
* @return string | ||
*/ | ||
public function getPayload(): string | ||
{ | ||
return $this->payload; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
<?php | ||
/** | ||
* XmlException automatically generated by SDKgen please do not edit this file manually | ||
* @see https://sdkgen.app | ||
*/ | ||
|
||
namespace Sdkgen\Client\Tests\Generated; | ||
|
||
use Sdkgen\Client\Exception\KnownStatusCodeException; | ||
|
||
class XmlException extends KnownStatusCodeException | ||
{ | ||
private string $payload; | ||
|
||
public function __construct(string $payload) | ||
{ | ||
parent::__construct('The server returned an error'); | ||
|
||
$this->payload = $payload; | ||
} | ||
|
||
/** | ||
* @return string | ||
*/ | ||
public function getPayload(): string | ||
{ | ||
return $this->payload; | ||
} | ||
} |
19 changes: 19 additions & 0 deletions
19
tests/Generator/Client/resource/typescript_test/BinaryException.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
/** | ||
* BinaryException automatically generated by SDKgen please do not edit this file manually | ||
* {@link https://sdkgen.app} | ||
*/ | ||
|
||
import {KnownStatusCodeException} from "sdkgen-client" | ||
|
||
|
||
export class BinaryException extends KnownStatusCodeException { | ||
|
||
public constructor(private payload: ArrayBuffer) { | ||
super('The server returned an error'); | ||
} | ||
|
||
public getPayload(): ArrayBuffer { | ||
return this.payload; | ||
} | ||
|
||
} |
19 changes: 19 additions & 0 deletions
19
tests/Generator/Client/resource/typescript_test/FormException.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
/** | ||
* FormException automatically generated by SDKgen please do not edit this file manually | ||
* {@link https://sdkgen.app} | ||
*/ | ||
|
||
import {KnownStatusCodeException} from "sdkgen-client" | ||
|
||
|
||
export class FormException extends KnownStatusCodeException { | ||
|
||
public constructor(private payload: URLSearchParams) { | ||
super('The server returned an error'); | ||
} | ||
|
||
public getPayload(): URLSearchParams { | ||
return this.payload; | ||
} | ||
|
||
} |
Oops, something went wrong.