~ancarda/psr7-string-stream

ref: 613485cfa5ed04fe26f6b60807209e098a97ca87 psr7-string-stream/src/StreamUnusableException.php -rw-r--r-- 522 bytes
613485cfMark Dain Throw StreamUnusableException after close/detach 1 year, 11 months ago
                                                                                
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
<?php

declare(strict_types=1);

namespace Ancarda\Psr7\StringStream;

use Throwable;

/**
 * StreamUnusableException is thrown when a user attempts to read, seek, or write to a closed or detached stream
 */
final class StreamUnusableException extends IllegalOperationException
{
    /**
     * @param string $operation
     * @param Throwable|null $previous
     */
    public function __construct(string $operation, Throwable $previous = null)
    {
        parent::__construct($operation, 'closed', $previous);
    }
}