1C-Bitrix 25.700.0
Загрузка...
Поиск...
Не найдено
memcachedconnection.php
См. документацию.
1<?php
8
9namespace Bitrix\Main\Data;
10
18{
20
22 {
23 parent::__construct($configuration);
24 $this->configurator = new Configurator\MemcachedConnectionConfigurator($this->getConfiguration());
25 }
26
27 protected function connectInternal()
28 {
29 $this->resource = $this->configurator->createConnection();
30 $this->isConnected = (bool)$this->resource;
31 }
32
33 protected function disconnectInternal()
34 {
35 if ($this->isConnected())
36 {
37 $this->resource->quit();
38 $this->resource = null;
39 $this->isConnected = false;
40 }
41 }
42
43 public function get($key)
44 {
45 if (!$this->isConnected())
46 {
47 $this->connect();
48 }
49
50 return $this->resource->get($key);
51 }
52
53 public function set($key, $value)
54 {
55 if (!$this->isConnected())
56 {
57 $this->connect();
58 }
59
60 return $this->resource->set($key, $value);
61 }
62}
getConfiguration()
Определения connection.php:75
Configurator MemcachedConnectionConfigurator $configurator
Определения memcachedconnection.php:19
__construct(array $configuration)
Определения memcachedconnection.php:21
</td ></tr ></table ></td ></tr >< tr >< td class="bx-popup-label bx-width30"><?=GetMessage("PAGE_NEW_TAGS")?> array( $site)
Определения file_new.php:804
if(empty($signedUserToken)) $key
Определения quickway.php:257