示例#1
0
文件: loadTasks.php 项目: zondor/Robo
 /**
  * @param $prefix
  * @param $base
  * @param $includeRandomPart
  * @return TmpDir
  */
 protected function taskTmpDir($prefix = 'tmp', $base = '', $includeRandomPart = true)
 {
     return Temporary::wrap(new TmpDir($prefix, $base, $includeRandomPart));
 }
示例#2
0
文件: loadTasks.php 项目: zondor/Robo
 /**
  * @param $prefix
  * @param $base
  * @param $includeRandomPart
  * @return TmpFile
  */
 protected function taskTmpFile($filename = 'tmp', $extension = '', $baseDir = '', $includeRandomPart = true)
 {
     return Temporary::wrap(new TmpFile($filename, $extension, $baseDir, $includeRandomPart));
 }
示例#3
0
 /**
  * @param $dir
  * @return string|empty
  */
 protected function _tmpDir($prefix = 'tmp', $base = '', $includeRandomPart = true)
 {
     $result = Temporary::wrap(new TmpDir($prefix, $base, $includeRandomPart))->run();
     $data = $result->getData() + ['path' => ''];
     return $data['path'];
 }