CoreFiles by mySites.guru
ResponseStream.php54 lines, 1,160 bytes, from Joomla_5.2.1-Stable-Full_Package.zip
Raw History Compare with 5.2.0
md5
50ec7ebc879ae453b185b6c756464475
sha1
a4fee922cb0881e865feadcb81cf111a81e36edc
sha256
6ab254348dd68df6e50dda7ec52cb4fd672e0b61b8affef8dbf3a405903743c9
<?php

/*
 * This file is part of the Symfony package.
 *
 * (c) Fabien Potencier <[email protected]>
 *
 * For the full copyright and license information, please view the LICENSE
 * file that was distributed with this source code.
 */

namespace Symfony\Component\HttpClient\Response;

use Symfony\Contracts\HttpClient\ChunkInterface;
use Symfony\Contracts\HttpClient\ResponseInterface;
use Symfony\Contracts\HttpClient\ResponseStreamInterface;

/**
 * @author Nicolas Grekas <[email protected]>
 */
final class ResponseStream implements ResponseStreamInterface
{
    private \Generator $generator;

    public function __construct(\Generator $generator)
    {
        $this->generator = $generator;
    }

    public function key(): ResponseInterface
    {
        return $this->generator->key();
    }

    public function current(): ChunkInterface
    {
        return $this->generator->current();
    }

    public function next(): void
    {
        $this->generator->next();
    }

    public function rewind(): void
    {
        $this->generator->rewind();
    }

    public function valid(): bool
    {
        return $this->generator->valid();
    }
}

The same content is in 87 releases, Joomla 5.1.0-beta1 to 6.0.0-alpha3. See them all, or every version of this file.