Relay12Trait.php 3.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107
  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\Traits\Relay;
  11. if (version_compare(phpversion('relay'), '0.12.0', '>=')) {
  12. /**
  13. * @internal
  14. */
  15. trait Relay12Trait
  16. {
  17. public function delifeq($key, $value): \Relay\Relay|false|int
  18. {
  19. return $this->initializeLazyObject()->delifeq(...\func_get_args());
  20. }
  21. public function vadd($key, $values, $element, $options = null): \Relay\Relay|false|int
  22. {
  23. return $this->initializeLazyObject()->vadd(...\func_get_args());
  24. }
  25. public function vcard($key): \Relay\Relay|false|int
  26. {
  27. return $this->initializeLazyObject()->vcard(...\func_get_args());
  28. }
  29. public function vdim($key): \Relay\Relay|false|int
  30. {
  31. return $this->initializeLazyObject()->vdim(...\func_get_args());
  32. }
  33. public function vemb($key, $element, $raw = false): \Relay\Relay|array|false
  34. {
  35. return $this->initializeLazyObject()->vemb(...\func_get_args());
  36. }
  37. public function vgetattr($key, $element, $raw = false): \Relay\Relay|array|false|string
  38. {
  39. return $this->initializeLazyObject()->vgetattr(...\func_get_args());
  40. }
  41. public function vinfo($key): \Relay\Relay|array|false
  42. {
  43. return $this->initializeLazyObject()->vinfo(...\func_get_args());
  44. }
  45. public function vismember($key, $element): \Relay\Relay|bool
  46. {
  47. return $this->initializeLazyObject()->vismember(...\func_get_args());
  48. }
  49. public function vlinks($key, $element, $withscores): \Relay\Relay|array|false
  50. {
  51. return $this->initializeLazyObject()->vlinks(...\func_get_args());
  52. }
  53. public function vrandmember($key, $count = 0): \Relay\Relay|array|false|string
  54. {
  55. return $this->initializeLazyObject()->vrandmember(...\func_get_args());
  56. }
  57. public function vrange($key, $min, $max, $count = -1): \Relay\Relay|array|false
  58. {
  59. return $this->initializeLazyObject()->vrange(...\func_get_args());
  60. }
  61. public function vrem($key, $element): \Relay\Relay|false|int
  62. {
  63. return $this->initializeLazyObject()->vrem(...\func_get_args());
  64. }
  65. public function vsetattr($key, $element, $attributes): \Relay\Relay|false|int
  66. {
  67. return $this->initializeLazyObject()->vsetattr(...\func_get_args());
  68. }
  69. public function vsim($key, $member, $options = null): \Relay\Relay|array|false
  70. {
  71. return $this->initializeLazyObject()->vsim(...\func_get_args());
  72. }
  73. public function xdelex($key, $ids, $mode = null): \Relay\Relay|array|false
  74. {
  75. return $this->initializeLazyObject()->xdelex(...\func_get_args());
  76. }
  77. public function xackdel($key, $group, $ids, $mode = null): \Relay\Relay|array|false
  78. {
  79. return $this->initializeLazyObject()->xackdel(...\func_get_args());
  80. }
  81. }
  82. } else {
  83. /**
  84. * @internal
  85. */
  86. trait Relay12Trait
  87. {
  88. }
  89. }