<?php
/**
 * ------------------------ 
 *  版权所有  www.tecmz.com
 *  商业版本请购买正版授权使用
 * ------------------------
*/ namespace ModStart\Data; use ModStart\Core\Util\PathUtil; abstract class AbstractRemoteDataStorage extends AbstractDataStorage { protected $remoteType = ''; public function driverName() { return $this->remoteType; } public function domain() { return modstart_config()->getWithEnv($this->remoteType . '_Domain'); } public function domainInternal() { return modstart_config()->getWithEnv($this->remoteType . '_DomainInternal', modstart_config()->getWithEnv($this->remoteType . '_Domain')); } public function updateDriverDomain($dTnlu) { goto MmB4G; MmB4G: $E3ui1 = array('driver' => $this->remoteType, 'domain' => $this->domain()); goto PSyGV; PSyGV: $this->repository->updateData($dTnlu['id'], $E3ui1); goto lWzNM; lWzNM: return array_merge($dTnlu, $E3ui1); goto rNeLV; rNeLV: } public function getDriverFullPath($QTKvb) { goto sS4ry; kwa32: return $this->domain() . $QTKvb; goto vfJAx; y6Zmz: if (PathUtil::isPublicNetPath($QTKvb)) { return $QTKvb; } goto kwa32; sS4ry: $QTKvb = parent::getDriverFullPath($QTKvb); goto y6Zmz; vfJAx: } public function getDriverFullPathInternal($QTKvb) { goto BinHj; lttG_: return $this->domainInternal() . $QTKvb; goto Q2vzw; SVg3M: if (PathUtil::isPublicNetPath($QTKvb)) { return $QTKvb; } goto lttG_; BinHj: $QTKvb = parent::getDriverFullPath($QTKvb); goto SVg3M; Q2vzw: } }