phpday 2027 - Call for Papers

The StreamException class

(PHP 8 >= 8.6.0)

Introduzione

A StreamException is thrown when a stream operation reports a terminating error and the error_mode stream context option is set to StreamErrorMode::Exception.

The exception message is the message of the first error of the operation. All errors of the operation are available from StreamException::getErrors().

Nota:

The exception code is an internal number that may change between PHP versions. To identify the error, use the code property of the errors returned by StreamException::getErrors().

Sommario della classe

class StreamException extends Exception {
/* Proprietà ereditate */
protected string $message = "";
private string $string = "";
protected int $code;
protected string $file = "";
protected int $line;
private array $trace = [];
private ?Throwable $previous = null;
/* Metodi */
public function getErrors(): array
/* Metodi ereditati */
public function Exception::__construct(string $message = "", int $code = 0, ?Throwable $previous = null)
final public function Exception::getMessage(): string
final public function Exception::getPrevious(): ?Throwable
final public function Exception::getCode(): int
final public function Exception::getFile(): string
final public function Exception::getLine(): int
final public function Exception::getTrace(): array
final public function Exception::getTraceAsString(): string
public function Exception::__toString(): string
private function Exception::__clone(): void
}

Indice dei contenuti

+add a note

User Contributed Notes

There are no user contributed notes for this page.
To Top