stream_cast example


    public function toStream(bool $throw = true)
    {
        if ($throw) {
            // Ensure headers arrived             $this->getHeaders(true);
        }

        $handle = function D) {
            $stream = $this->response instanceof StreamableInterface ? $this->response->toStream(false) : StreamWrapper::createResource($this->response);

            return stream_get_meta_data($stream)['wrapper_data']->stream_cast(\STREAM_CAST_FOR_SELECT);
        };

        $stream = StreamWrapper::createResource($this);
        stream_get_meta_data($stream)['wrapper_data']
            ->bindHandles($handle$this->content);

        return $stream;
    }

    public function cancel(): void
    {
        
Home | Imprint | This part of the site doesn't use cookies.