/var/www/vhosts/nabawater/vendor/yiisoft/yii2/web
NameSizeModeActions
migrations/-0755rm
Application.php58360644editdlrm
AssetBundle.php86020644editdlrm
AssetConverter.php45990644editdlrm
AssetConverterInterface.php6980644editdlrm
AssetManager.php255860644editdlrm
BadRequestHttpException.php10770644editdlrm
CacheSession.php36730644editdlrm
CompositeUrlRule.php44820644editdlrm
ConflictHttpException.php8140644editdlrm
Controller.php97390644editdlrm
Cookie.php20020644editdlrm
CookieCollection.php80940644editdlrm
DbSession.php76280644editdlrm
ErrorAction.php60920644editdlrm
ErrorHandler.php191410644editdlrm
ForbiddenHttpException.php11260644editdlrm
GoneHttpException.php10730644editdlrm
GroupUrlRule.php46960644editdlrm
HeaderCollection.php72360644editdlrm
HeadersAlreadySentException.php7000644editdlrm
HtmlResponseFormatter.php10920644editdlrm
HttpException.php17600644editdlrm
IdentityInterface.php36610644editdlrm
JqueryAsset.php4590644editdlrm
JsExpression.php12530644editdlrm
JsonParser.php17310644editdlrm
JsonResponseFormatter.php46770644editdlrm
Link.php20780644editdlrm
Linkable.php11090644editdlrm
MethodNotAllowedHttpException.php8330644editdlrm
MultiFieldSession.php46140644editdlrm
MultipartFormDataParser.php122710644editdlrm
NotAcceptableHttpException.php10630644editdlrm
NotFoundHttpException.php8080644editdlrm
RangeNotSatisfiableHttpException.php12120644editdlrm
Request.php656150644editdlrm
RequestParserInterface.php6690644editdlrm
Response.php413540644editdlrm
ResponseFormatterInterface.php5430644editdlrm
ServerErrorHttpException.php8270644editdlrm
Session.php345780644editdlrm
SessionIterator.php19780644editdlrm
TooManyRequestsHttpException.php10190644editdlrm
UnauthorizedHttpException.php11530644editdlrm
UnprocessableEntityHttpException.php11200644editdlrm
UnsupportedMediaTypeHttpException.php10940644editdlrm
UploadedFile.php88360644editdlrm
UrlManager.php258720644editdlrm
UrlNormalizer.php51030644editdlrm
UrlNormalizerRedirectException.php17580644editdlrm
UrlRule.php217070644editdlrm
UrlRuleInterface.php12230644editdlrm
User.php331100644editdlrm
UserEvent.php12290644editdlrm
View.php237450644editdlrm
ViewAction.php47180644editdlrm
XmlResponseFormatter.php56670644editdlrm
YiiAsset.php5040644editdlrm
Edit: /var/www/vhosts/nabawater/vendor/yiisoft/yii2/web/CacheSession.php (3673B)
[ * 'class' => 'yii\web\CacheSession', * // 'cache' => 'mycache', * ] * ``` * * @property bool $useCustomStorage Whether to use custom storage. This property is read-only. * * @author Qiang Xue * @since 2.0 */ class CacheSession extends Session { /** * @var CacheInterface|array|string the cache object or the application component ID of the cache object. * The session data will be stored using this cache object. * * After the CacheSession object is created, if you want to change this property, * you should only assign it with a cache object. * * Starting from version 2.0.2, this can also be a configuration array for creating the object. */ public $cache = 'cache'; /** * Initializes the application component. */ public function init() { parent::init(); $this->cache = Instance::ensure($this->cache, 'yii\caching\CacheInterface'); } /** * Returns a value indicating whether to use custom session storage. * This method overrides the parent implementation and always returns true. * @return bool whether to use custom storage. */ public function getUseCustomStorage() { return true; } /** * Session read handler. * @internal Do not call this method directly. * @param string $id session ID * @return string the session data */ public function readSession($id) { $data = $this->cache->get($this->calculateKey($id)); return $data === false ? '' : $data; } /** * Session write handler. * @internal Do not call this method directly. * @param string $id session ID * @param string $data session data * @return bool whether session write is successful */ public function writeSession($id, $data) { return $this->cache->set($this->calculateKey($id), $data, $this->getTimeout()); } /** * Session destroy handler. * @internal Do not call this method directly. * @param string $id session ID * @return bool whether session is destroyed successfully */ public function destroySession($id) { $cacheId = $this->calculateKey($id); if ($this->cache->exists($cacheId) === false) { return true; } return $this->cache->delete($cacheId); } /** * Generates a unique key used for storing session data in cache. * @param string $id session variable name * @return mixed a safe cache key associated with the session variable name */ protected function calculateKey($id) { return [__CLASS__, $id]; } }