extend/alipay/pay/lotusphp_runtime/Cache/Cache.php

(开头部分) 1KB

这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。

<?php
class LtCache
{
	public $configHandle;

	public $group;
	public $node;

	protected $ch;

	public function __construct()
	{
		if (! $this->configHandle instanceof LtConfig)
		{
			if (class_exists("LtObjectUtil", false))
			{
				$this->configHandle = LtObjectUtil::singleton("LtConfig");
			}
			else
			{
				$this->configHandle = new LtConfig;
			}
		}
	}

	public function init()
	{
		$this->ch = new LtCacheHandle;
		$this->ch->configHandle = $this->configHandle;
		$this->ch->init();
		$this->ch->group = $this->getGroup();
		$this->ch->node = $this->getNode();
	}

	public function getTDG($tableName)
	{
		$tdg = new LtCacheTableDataGateway;
		$tdg->tableName = $tableName;
		$tdg->ch = $this->ch;
		return $tdg;
	}

	public function changeNode($node)
	{
		$this->node = $node;
		$this->dbh->node = $node;
	}

	protected function getGroup()
	{
		if ($this->group)
		{
			return $this->group;
		}
		$servers = $this->configHandle->get("cache.servers");
		if (1 == count($servers))
		{
			return key($servers);
		}
		return false;

24 小时内免费解锁 3 个项目,之后 1 算力/个。 规则说明

AI 解读 AI

登录后可用,每次 10 算力,解读结果公开显示在下面。

还没有人解读过这个文件。