CurlClientState.php 873 B

1234567891011121314151617181920212223242526272829303132333435363738
  1. <?php
  2. /*
  3. * This file is part of the Symfony package.
  4. *
  5. * (c) Fabien Potencier <fabien@symfony.com>
  6. *
  7. * For the full copyright and license information, please view the LICENSE
  8. * file that was distributed with this source code.
  9. */
  10. namespace Symfony\Component\HttpClient\Internal;
  11. /**
  12. * Internal representation of the cURL client's state.
  13. *
  14. * @author Alexander M. Turek <me@derrabus.de>
  15. *
  16. * @internal
  17. */
  18. final class CurlClientState extends ClientState
  19. {
  20. /** @var \CurlMultiHandle|resource */
  21. public $handle;
  22. /** @var PushedResponse[] */
  23. public $pushedResponses = [];
  24. /** @var DnsCache */
  25. public $dnsCache;
  26. /** @var float[] */
  27. public $pauseExpiries = [];
  28. public $execCounter = \PHP_INT_MIN;
  29. public function __construct()
  30. {
  31. $this->handle = curl_multi_init();
  32. $this->dnsCache = new DnsCache();
  33. }
  34. }