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


PHP Storage::getPropertiesStorage方法代码示例

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


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

示例1: __get_properties_storage

 static function __get_properties_storage($nome_categoria, $nome_modulo)
 {
     return Storage::getPropertiesStorage(self::INSTALLED_MODULES_STORAGE_DIR, $nome_categoria . "__" . $nome_modulo);
 }
开发者ID:mbcraft,项目名称:frozen,代码行数:4,代码来源:InstalledModules.class.php

示例2: testCreateStorageOnWrite

 function testCreateStorageOnWrite()
 {
     Storage::set_storage_root(DS . FRAMEWORK_CORE_PATH . "tests/io/storage_dir/");
     $d = new Dir(DS . FRAMEWORK_CORE_PATH . "tests/io/storage_dir/");
     foreach ($d->listFiles() as $f) {
         $f->delete(true);
     }
     $this->assertFalse($d->hasSingleSubdir(), "Lo storage e' gia' presente!!");
     $storage = Storage::getPropertiesStorage("boh", "ciccia");
     $this->assertFalse($storage->exists(), "Lo storage esiste gia'!!");
     $test_props = array("test" => "value", "hello" => "world");
     $storage->add("category", $test_props);
     $this->assertTrue($storage->exists(), "Lo storage non e' stato creato!!");
     $storage->delete();
     $this->assertFalse($storage->exists(), "Lo storage non e' stato eliminato!!");
     $properties = $storage->readAll();
     //readAll
     $this->assertTrue($storage->exists(), "Lo storage non e' stato creato per una lettura!!");
     $this->assertFalse($properties === null, "Il risultato ritornato e' ===null !!");
     $this->assertTrue(is_array($properties), "Il metodo non ha ritornato un array con uno storage inesistente!!");
     $this->assertTrue(count($properties) == 0, "L'array ritornato da una lettura di storage vuoto non e' vuoto!!");
     $storage->delete();
     $storage->remove("blah");
     //remove
     $this->assertTrue($storage->exists(), "Lo storage non e' stato creato per una cancellazione!!");
     $storage->delete();
     $storage->saveAll(array());
     //saveAll
     $this->assertTrue($storage->exists(), "Lo storage non e' stato creato per una cancellazione!!");
     $storage->delete();
     $this->assertFalse($storage->exists(), "Lo storage non e' stato eliminato!!");
     foreach ($d->listFiles() as $f) {
         $f->delete(true);
     }
     Storage::set_storage_root(Storage::get_default_storage_root());
 }
开发者ID:mbcraft,项目名称:frozen,代码行数:36,代码来源:storage_test.php

示例3: getStoredProps

 function getStoredProps()
 {
     $path = $this->__path;
     $path = str_replace("//", "/", $path);
     $path_md5 = md5($path);
     $folder = "_" . substr($path_md5, 0, 1);
     return Storage::getPropertiesStorage($folder, $path_md5);
 }
开发者ID:mbcraft,项目名称:frozen,代码行数:8,代码来源:__FileSystemElement.class.php


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