当前位置: 首页>>代码示例>>PHP>>正文


PHP ResourceStorage::getConfiguration方法代码示例

本文整理汇总了PHP中TYPO3\CMS\Core\Resource\ResourceStorage::getConfiguration方法的典型用法代码示例。如果您正苦于以下问题:PHP ResourceStorage::getConfiguration方法的具体用法?PHP ResourceStorage::getConfiguration怎么用?PHP ResourceStorage::getConfiguration使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在TYPO3\CMS\Core\Resource\ResourceStorage的用法示例。


在下文中一共展示了ResourceStorage::getConfiguration方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: initializeObject

 /**
  * initializes this object
  *
  * @return void
  */
 public function initializeObject()
 {
     $this->database = $GLOBALS['TYPO3_DB'];
     $fileFactory = ResourceFactory::getInstance();
     $this->storageObject = $fileFactory->getStorageObject($this->storageUid);
     $storageConfiguration = $this->storageObject->getConfiguration();
     $this->storageBasePath = $storageConfiguration['basePath'];
 }
开发者ID:svenhartmann,项目名称:t3ext-dam_falmigration,代码行数:13,代码来源:AbstractService.php

示例2: isEquivalentObjectStorage

 /**
  * Determines whether the passed storage object and record (sys_file_storage) can be
  * seen as equivalent during import.
  *
  * @param ResourceStorage $storageObject The storage object which should get compared
  * @param array $storageRecord The storage record which should get compared
  * @return bool Returns TRUE when both object storages can be seen as equivalent
  */
 protected function isEquivalentObjectStorage(ResourceStorage $storageObject, array $storageRecord)
 {
     // compare the properties: driver, writable and online
     if ($storageObject->getDriverType() === $storageRecord['driver'] && (bool) $storageObject->isWritable() === (bool) $storageRecord['is_writable'] && (bool) $storageObject->isOnline() === (bool) $storageRecord['is_online']) {
         $storageRecordConfiguration = ResourceFactory::getInstance()->convertFlexFormDataToConfigurationArray($storageRecord['configuration']);
         $storageObjectConfiguration = $storageObject->getConfiguration();
         // compare the properties: pathType and basePath
         if ($storageRecordConfiguration['pathType'] === $storageObjectConfiguration['pathType'] && $storageRecordConfiguration['basePath'] === $storageObjectConfiguration['basePath']) {
             return true;
         }
     }
     return false;
 }
开发者ID:amazingh,项目名称:TYPO3.CMS,代码行数:21,代码来源:Import.php

示例3: getResourcesSourcePathByResourceStorage

 /**
  * @param ResourceStorage $storage
  * @return string
  */
 protected function getResourcesSourcePathByResourceStorage(ResourceStorage $storage)
 {
     $storageConfiguration = $storage->getConfiguration();
     if ($storageConfiguration['pathType'] === 'absolute') {
         $sourcePath = PathUtility::getCanonicalPath($storageConfiguration['basePath']) . '/';
     } else {
         $sourcePath = PathUtility::getCanonicalPath(PATH_site . $storageConfiguration['basePath']) . '/';
     }
     return $sourcePath;
 }
开发者ID:IngoMueller,项目名称:naw_securedl,代码行数:14,代码来源:AbstractResourcePublishingTarget.php


注:本文中的TYPO3\CMS\Core\Resource\ResourceStorage::getConfiguration方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。