RedisAdapter.php 859 B

123456789101112131415161718192021222324252627
  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\Cache\Adapter;
  11. use Symfony\Component\Cache\Marshaller\MarshallerInterface;
  12. use Symfony\Component\Cache\Traits\RedisClusterProxy;
  13. use Symfony\Component\Cache\Traits\RedisProxy;
  14. use Symfony\Component\Cache\Traits\RedisTrait;
  15. class RedisAdapter extends AbstractAdapter
  16. {
  17. use RedisTrait;
  18. public function __construct(\Redis|\RedisArray|\RedisCluster|\Predis\ClientInterface|RedisProxy|RedisClusterProxy $redis, string $namespace = '', int $defaultLifetime = 0, MarshallerInterface $marshaller = null)
  19. {
  20. $this->init($redis, $namespace, $defaultLifetime, $marshaller);
  21. }
  22. }