-
-
Notifications
You must be signed in to change notification settings - Fork 9.8k
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,36 @@ | ||
| <?php | ||
|
|
||
| /* | ||
| * This file is part of the Symfony package. | ||
| * | ||
| * (c) Fabien Potencier <fabien@symfony.com> | ||
| * | ||
| * For the full copyright and license information, please view the LICENSE | ||
| * file that was distributed with this source code. | ||
| */ | ||
|
|
||
| namespace Symfony\Component\Cache\Traits\Relay; | ||
|
|
||
| if (version_compare(phpversion('relay'), '0.8.1', '>=')) { | ||
| /** | ||
| * @internal | ||
| */ | ||
| trait CopyTrait | ||
| { | ||
| public function copy($src, $dst, $options = null): \Relay\Relay|bool | ||
| { | ||
| return ($this->lazyObjectState->realInstance ??= ($this->lazyObjectState->initializer)())->copy(...\func_get_args()); | ||
| } | ||
| } | ||
| } else { | ||
| /** | ||
| * @internal | ||
| */ | ||
| trait CopyTrait | ||
|
Check failure on line 29 in src/Symfony/Component/Cache/Traits/Relay/CopyTrait.php
|
||
| { | ||
| public function copy($src, $dst, $options = null): \Relay\Relay|false|int | ||
| { | ||
| return ($this->lazyObjectState->realInstance ??= ($this->lazyObjectState->initializer)())->copy(...\func_get_args()); | ||
| } | ||
| } | ||
| } | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,36 @@ | ||
| <?php | ||
|
|
||
| /* | ||
| * This file is part of the Symfony package. | ||
| * | ||
| * (c) Fabien Potencier <fabien@symfony.com> | ||
| * | ||
| * For the full copyright and license information, please view the LICENSE | ||
| * file that was distributed with this source code. | ||
| */ | ||
|
|
||
| namespace Symfony\Component\Cache\Traits\Relay; | ||
|
|
||
| if (version_compare(phpversion('relay'), '0.9.0', '>=')) { | ||
| /** | ||
| * @internal | ||
| */ | ||
| trait GeosearchTrait | ||
| { | ||
| public function geosearch($key, $position, $shape, $unit, $options = []): \Relay\Relay|array|false | ||
| { | ||
| return ($this->lazyObjectState->realInstance ??= ($this->lazyObjectState->initializer)())->geosearch(...\func_get_args()); | ||
| } | ||
| } | ||
| } else { | ||
| /** | ||
| * @internal | ||
| */ | ||
| trait GeosearchTrait | ||
|
Check failure on line 29 in src/Symfony/Component/Cache/Traits/Relay/GeosearchTrait.php
|
||
| { | ||
| public function geosearch($key, $position, $shape, $unit, $options = []): \Relay\Relay|array | ||
| { | ||
| return ($this->lazyObjectState->realInstance ??= ($this->lazyObjectState->initializer)())->geosearch(...\func_get_args()); | ||
| } | ||
| } | ||
| } | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,36 @@ | ||
| <?php | ||
|
|
||
| /* | ||
| * This file is part of the Symfony package. | ||
| * | ||
| * (c) Fabien Potencier <fabien@symfony.com> | ||
| * | ||
| * For the full copyright and license information, please view the LICENSE | ||
| * file that was distributed with this source code. | ||
| */ | ||
|
|
||
| namespace Symfony\Component\Cache\Traits\Relay; | ||
|
|
||
| if (version_compare(phpversion('relay'), '0.9.0', '>=')) { | ||
| /** | ||
| * @internal | ||
| */ | ||
| trait GetrangeTrait | ||
| { | ||
| public function getrange($key, $start, $end): mixed | ||
| { | ||
| return ($this->lazyObjectState->realInstance ??= ($this->lazyObjectState->initializer)())->getrange(...\func_get_args()); | ||
| } | ||
| } | ||
| } else { | ||
| /** | ||
| * @internal | ||
| */ | ||
| trait GetrangeTrait | ||
|
Check failure on line 29 in src/Symfony/Component/Cache/Traits/Relay/GetrangeTrait.php
|
||
| { | ||
| public function getrange($key, $start, $end): \Relay\Relay|false|string | ||
| { | ||
| return ($this->lazyObjectState->realInstance ??= ($this->lazyObjectState->initializer)())->getrange(...\func_get_args()); | ||
| } | ||
| } | ||
| } | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,36 @@ | ||
| <?php | ||
|
|
||
| /* | ||
| * This file is part of the Symfony package. | ||
| * | ||
| * (c) Fabien Potencier <fabien@symfony.com> | ||
| * | ||
| * For the full copyright and license information, please view the LICENSE | ||
| * file that was distributed with this source code. | ||
| */ | ||
|
|
||
| namespace Symfony\Component\Cache\Traits\Relay; | ||
|
|
||
| if (version_compare(phpversion('relay'), '0.9.0', '>=')) { | ||
| /** | ||
| * @internal | ||
| */ | ||
| trait HsetTrait | ||
| { | ||
| public function hset($key, ...$keys_and_vals): \Relay\Relay|false|int | ||
| { | ||
| return ($this->lazyObjectState->realInstance ??= ($this->lazyObjectState->initializer)())->hset(...\func_get_args()); | ||
| } | ||
| } | ||
| } else { | ||
| /** | ||
| * @internal | ||
| */ | ||
| trait HsetTrait | ||
|
Check failure on line 29 in src/Symfony/Component/Cache/Traits/Relay/HsetTrait.php
|
||
| { | ||
| public function hset($key, $mem, $val, ...$kvals): \Relay\Relay|false|int | ||
| { | ||
| return ($this->lazyObjectState->realInstance ??= ($this->lazyObjectState->initializer)())->hset(...\func_get_args()); | ||
| } | ||
| } | ||
| } | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,46 @@ | ||
| <?php | ||
|
|
||
| /* | ||
| * This file is part of the Symfony package. | ||
| * | ||
| * (c) Fabien Potencier <fabien@symfony.com> | ||
| * | ||
| * For the full copyright and license information, please view the LICENSE | ||
| * file that was distributed with this source code. | ||
| */ | ||
|
|
||
| namespace Symfony\Component\Cache\Traits\Relay; | ||
|
|
||
| if (version_compare(phpversion('relay'), '0.9.0', '>=')) { | ||
| /** | ||
| * @internal | ||
| */ | ||
| trait MoveTrait | ||
| { | ||
| public function blmove($srckey, $dstkey, $srcpos, $dstpos, $timeout): mixed | ||
| { | ||
| return ($this->lazyObjectState->realInstance ??= ($this->lazyObjectState->initializer)())->blmove(...\func_get_args()); | ||
| } | ||
|
|
||
| public function lmove($srckey, $dstkey, $srcpos, $dstpos): mixed | ||
| { | ||
| return ($this->lazyObjectState->realInstance ??= ($this->lazyObjectState->initializer)())->lmove(...\func_get_args()); | ||
| } | ||
| } | ||
| } else { | ||
| /** | ||
| * @internal | ||
| */ | ||
| trait MoveTrait | ||
|
Check failure on line 34 in src/Symfony/Component/Cache/Traits/Relay/MoveTrait.php
|
||
| { | ||
| public function blmove($srckey, $dstkey, $srcpos, $dstpos, $timeout): \Relay\Relay|false|null|string | ||
| { | ||
| return ($this->lazyObjectState->realInstance ??= ($this->lazyObjectState->initializer)())->blmove(...\func_get_args()); | ||
| } | ||
|
|
||
| public function lmove($srckey, $dstkey, $srcpos, $dstpos): \Relay\Relay|false|null|string | ||
| { | ||
| return ($this->lazyObjectState->realInstance ??= ($this->lazyObjectState->initializer)())->lmove(...\func_get_args()); | ||
| } | ||
| } | ||
| } | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,96 @@ | ||
| <?php | ||
|
|
||
| /* | ||
| * This file is part of the Symfony package. | ||
| * | ||
| * (c) Fabien Potencier <fabien@symfony.com> | ||
| * | ||
| * For the full copyright and license information, please view the LICENSE | ||
| * file that was distributed with this source code. | ||
| */ | ||
|
|
||
| namespace Symfony\Component\Cache\Traits\Relay; | ||
|
|
||
| if (version_compare(phpversion('relay'), '0.9.0', '>=')) { | ||
| /** | ||
| * @internal | ||
| */ | ||
| trait NullableReturnTrait | ||
| { | ||
| public function dump($key): \Relay\Relay|false|string|null | ||
| { | ||
| return ($this->lazyObjectState->realInstance ??= ($this->lazyObjectState->initializer)())->dump(...\func_get_args()); | ||
| } | ||
|
|
||
| public function geodist($key, $src, $dst, $unit = null): \Relay\Relay|false|float|null | ||
| { | ||
| return ($this->lazyObjectState->realInstance ??= ($this->lazyObjectState->initializer)())->geodist(...\func_get_args()); | ||
| } | ||
|
|
||
| public function hrandfield($hash, $options = null): \Relay\Relay|array|false|string|null | ||
| { | ||
| return ($this->lazyObjectState->realInstance ??= ($this->lazyObjectState->initializer)())->hrandfield(...\func_get_args()); | ||
| } | ||
|
|
||
| public function xadd($key, $id, $values, $maxlen = 0, $approx = false, $nomkstream = false): \Relay\Relay|false|string|null | ||
| { | ||
| return ($this->lazyObjectState->realInstance ??= ($this->lazyObjectState->initializer)())->xadd(...\func_get_args()); | ||
| } | ||
|
|
||
| public function zrank($key, $rank, $withscore = false): \Relay\Relay|array|false|int|null | ||
| { | ||
| return ($this->lazyObjectState->realInstance ??= ($this->lazyObjectState->initializer)())->zrank(...\func_get_args()); | ||
| } | ||
|
|
||
| public function zrevrank($key, $rank, $withscore = false): \Relay\Relay|array|false|int|null | ||
| { | ||
| return ($this->lazyObjectState->realInstance ??= ($this->lazyObjectState->initializer)())->zrevrank(...\func_get_args()); | ||
| } | ||
|
|
||
| public function zscore($key, $member): \Relay\Relay|false|float|null | ||
| { | ||
| return ($this->lazyObjectState->realInstance ??= ($this->lazyObjectState->initializer)())->zscore(...\func_get_args()); | ||
| } | ||
| } | ||
| } else { | ||
| /** | ||
| * @internal | ||
| */ | ||
| trait NullableReturnTrait | ||
|
Check failure on line 59 in src/Symfony/Component/Cache/Traits/Relay/NullableReturnTrait.php
|
||
| { | ||
| public function dump($key): \Relay\Relay|false|string | ||
| { | ||
| return ($this->lazyObjectState->realInstance ??= ($this->lazyObjectState->initializer)())->dump(...\func_get_args()); | ||
| } | ||
|
|
||
| public function geodist($key, $src, $dst, $unit = null): \Relay\Relay|false|float | ||
| { | ||
| return ($this->lazyObjectState->realInstance ??= ($this->lazyObjectState->initializer)())->geodist(...\func_get_args()); | ||
| } | ||
|
|
||
| public function hrandfield($hash, $options = null): \Relay\Relay|array|false|string | ||
| { | ||
| return ($this->lazyObjectState->realInstance ??= ($this->lazyObjectState->initializer)())->hrandfield(...\func_get_args()); | ||
| } | ||
|
|
||
| public function xadd($key, $id, $values, $maxlen = 0, $approx = false, $nomkstream = false): \Relay\Relay|false|string | ||
| { | ||
| return ($this->lazyObjectState->realInstance ??= ($this->lazyObjectState->initializer)())->xadd(...\func_get_args()); | ||
| } | ||
|
|
||
| public function zrank($key, $rank, $withscore = false): \Relay\Relay|array|false|int | ||
| { | ||
| return ($this->lazyObjectState->realInstance ??= ($this->lazyObjectState->initializer)())->zrank(...\func_get_args()); | ||
| } | ||
|
|
||
| public function zrevrank($key, $rank, $withscore = false): \Relay\Relay|array|false|int | ||
| { | ||
| return ($this->lazyObjectState->realInstance ??= ($this->lazyObjectState->initializer)())->zrevrank(...\func_get_args()); | ||
| } | ||
|
|
||
| public function zscore($key, $member): \Relay\Relay|false|float | ||
| { | ||
| return ($this->lazyObjectState->realInstance ??= ($this->lazyObjectState->initializer)())->zscore(...\func_get_args()); | ||
| } | ||
| } | ||
| } | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,36 @@ | ||
| <?php | ||
|
|
||
| /* | ||
| * This file is part of the Symfony package. | ||
| * | ||
| * (c) Fabien Potencier <fabien@symfony.com> | ||
| * | ||
| * For the full copyright and license information, please view the LICENSE | ||
| * file that was distributed with this source code. | ||
| */ | ||
|
|
||
| namespace Symfony\Component\Cache\Traits\Relay; | ||
|
|
||
| if (version_compare(phpversion('relay'), '0.9.0', '>=')) { | ||
| /** | ||
| * @internal | ||
| */ | ||
| trait PfcountTrait | ||
| { | ||
| public function pfcount($key_or_keys): \Relay\Relay|false|int | ||
| { | ||
| return ($this->lazyObjectState->realInstance ??= ($this->lazyObjectState->initializer)())->pfcount(...\func_get_args()); | ||
| } | ||
| } | ||
| } else { | ||
| /** | ||
| * @internal | ||
| */ | ||
| trait PfcountTrait | ||
|
Check failure on line 29 in src/Symfony/Component/Cache/Traits/Relay/PfcountTrait.php
|
||
| { | ||
| public function pfcount($key): \Relay\Relay|false|int | ||
| { | ||
| return ($this->lazyObjectState->realInstance ??= ($this->lazyObjectState->initializer)())->pfcount(...\func_get_args()); | ||
| } | ||
| } | ||
| } | ||
[Cache] make RelayProxyTrait compatible with relay extension 0.9.0 #58938
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Uh oh!
There was an error while loading. Please reload this page.
[Cache] make RelayProxyTrait compatible with relay extension 0.9.0 #58938
Changes from all commits
d80a2feFile filter
Filter by extension
Conversations
Uh oh!
There was an error while loading. Please reload this page.
Jump to
Uh oh!
There was an error while loading. Please reload this page.