/** * @param $prefix * @param $base * @param $includeRandomPart * @return TmpDir */ protected function taskTmpDir($prefix = 'tmp', $base = '', $includeRandomPart = true) { return Temporary::wrap(new TmpDir($prefix, $base, $includeRandomPart)); }
/** * @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)); }
/** * @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']; }