Version 5.0.0 beta 1

This commit is contained in:
Neo committed 2025-12-19 16:27:35 -08:00
1 parent 25ddeb65d6
commit 15c7beabc5
6736 files changed
+627902 -497943

No files matched your search

+26
View File
@@ -0,0 +1,26 @@
<?php
declare(strict_types=1);
namespace Pdp;
use RuntimeException;
use Throwable;
final class UnableToLoadResource extends RuntimeException implements CannotProcessHost
{
public static function dueToInvalidUri(string $uri): self
{
return new self('`'.$uri.'`: failed to open stream; No such URI, file or directory.');
}
public static function dueToUnavailableService(string $uri, Throwable $exception): self
{
return new self('Could not access the URI: `'.$uri.'`.', 0, $exception);
}
public static function dueToUnexpectedStatusCode(string $uri, int $statusCode): self
{
return new self('Invalid response from URI: `'.$uri.'`.', $statusCode);
}
}