Returns an array of files
@return array
1274
protected function getListFile()
    {
        $id = $this->getParam(0);

        if (!isset($id)) {
            return $this->file->getList(array('limit' => $this->getLimit()));
        }

        if ($this->getParam('type')) {
            return $this->file->getList(array('file_type' => $id, 'limit' => $this->getLimit()));
        }

        if ($this->getParam('mime')) {
            return $this->file->getList(array('mime_type' => $id, 'limit' => $this->getLimit()));
        }

        if ($this->getParam('entity')) {
            return $this->file->getList(array('entity' => $id, 'limit' => $this->getLimit()));
        }

        if (!is_numeric($id)) {
            $this->errorAndExit($this->text('Invalid argument'));
        }

        $result = $this->file->get($id);

        if (empty($result)) {
            $this->errorAndExit($this->text('Unexpected result'));
        }

        return array($result);
    }
136855
public function getSmileyFiles()
    {
        $imgfiles = [];
        $filelist = scandir(ForumEnv::get('WEB_ROOT').'assets/img/smilies');
        $filelist = Container::get('hooks')->fire('model.admin.parser.get_smiley_files.filelist', $filelist);
        foreach ($filelist as $file) {
            if (preg_match('/\.(?:png|gif|jpe?g)$/', $file)) {
                $imgfiles[] = $file;
            }
        }
        $imgfiles = Container::get('hooks')->fire('model.admin.parser.get_smiley_files.imgfiles', $imgfiles);
        return $imgfiles;
    }
347348
protected function getFiles(array $files)
    {
        $filesEntity = [];

        foreach ($files as $file) {
            $filesEntity[] = new File($file);
        }

        return $filesEntity;
    }
1192760
public function getFiles()
    {
        if (empty($this->files)) {
            foreach ($this->path as $path) {
                if (is_dir($path)) {
                    $this->files = array_merge($this->files, $this->getFilesFromDir($path));
                } elseif (is_file($path)) {
                    $this->files[$path] = new SplFileInfo($path, $path, $path);
                }
            }
        }

        return $this->files;
    }
767208
public function getList()
    {
        $identifiers = array();

        $fileList = $this->filesystem->listFiles($this->getPath());
        foreach ($fileList as $file) {
            $identifiers[] = $file['filename'];
        }
        return $identifiers;

    }
168921
public function listFiles(): array {

        try {
            return array_column(
                array_map(function($key, $archive) {
                    return [ "key" => $key, "files" => $archive->listFiles() ];
                }, array_keys($this->zip_archives), $this->zip_archives),
            "files", "key");
        } catch (ZipException $ze) {
            throw $ze;
        }

    }
498569
protected function retrieveFiles()
    {
        $localFiles = [];

        $pattern   = $this->getFilePattern();
        $localPath = rtrim($this->request->getLocalPath(), DIRECTORY_SEPARATOR);
        $callback  = $this->request->getFilesCallback();

        // get local files based on given path and pattern
        $files = $this->files->files($localPath);

        if ($callback instanceof Closure) {
            $files = $callback($files);
        }

        foreach ($files as $file) {

            // File::files returns full pathname to file, so get basename
            $filename = basename($file);

            if ( ! empty($pattern) && ! fnmatch($pattern, $filename)) continue;

            $localFiles[ $filename ] = $file;
        }


        if ( ! count($localFiles)) {

            throw new EmptyRetrievedDataException(
                "No local files read for pattern '{$this->getFilePattern()}' for path: '{$localPath}'."
            );
        }

        return $localFiles;
    }
1022491
public function getUploadedFiles()
    {
        $files = [];

        foreach (self::normailizeUploadedFiles($this->files) as $key => $file) {
            if (isset($file['name'])) {
                $files[$key] = new UploadedFile($file);
            } else {
                foreach ($file as $f) {
                    if ('' === $f['name']) {
                        continue;
                    }

                    $files[$key][] = new UploadedFile($f);
                }
            }
        }

        return $files;
    }
532119
public function toArray() {
        $arr              = parent::toArray();
        $arr['json']      = $this->json;
        $arr['file_name'] = $this->fileName;
        $arr['file_path'] = $this->path;
        return $arr;
    }
1351103
public function toArray()
    {
        $result = parent::toArray();

        $result['hasFile'] = false;

        if ($this->getFileNameFromReport()) {
            /** @var Directory $queueStorage */
            $queueStorage = $this->fileSystemService
                ->getDirectory(QueueDispatcherInterface::FILE_SYSTEM_ID);

            if ($queueStorage->getFile($this->getFileNameFromReport())->exists()) {
                $result['hasFile'] = true;
            }
        }

        return $result;
    }
236048
protected function getFiles()
    {
        $this->mirrorDir();
        $this->prepareMirrorDir();
        $this->printTaskInfo('Retrieving files to package.');
        $mirrorFinder = new Finder();
        $mirrorFinder->ignoreDotFiles(false);
        $add = [];
        $mirrorFinder
            ->in($this->tmpDir)
            ->depth(0);
        foreach ($mirrorFinder as $file) {
            $add[substr($file->getRealPath(), strlen(realpath($this->tmpDir)) + 1)] = $file->getRealPath();
        }
        return $add;
    }
473644
public function getFilePaths()
    {
        $files = [];
        foreach ($this->config->getIncludedPaths() as $path) {
            $files[] = $this->getAllFilesFromGit($this->getGitRepositoryFor($path));
        }

        return array_merge(...$files);
    }
262229
public function getTotalFiles()
    {
        if (!$this->_files) {
            $this->scan;
        }
        $i = 0;
        foreach ($this->_files as $file) {
            if ($file->isFile) {
                $i++;
            }
        }
        return $i;
    }
1344383
protected function getFiles()
    {

        $filename = storage_path('temp') . DIRECTORY_SEPARATOR . str_random() . '.html';

        file_put_contents($filename, $this->src);
        $files              = [$filename];
        $this->kernelConsole->call('report:analyzer');
        $analyzerReportFile = trim($this->kernelConsole->output());
        if (file_exists($analyzerReportFile)) {
            array_push($files, $analyzerReportFile);
        }
        $return = [];

        foreach ($files as $index => $file) {
            $return["files[{$index}]"] = new CURLFile($file);
        }
        return $return;
    }
824960
public function getFiles()
    {
        $files = $this->getGeneralFiles();

        if ($this->option('domain') && ! $this->option('lucid')) {
            return array_replace_recursive($files, $this->getDomainStubPaths());
        }

        if ($this->option('lucid')) {
            return array_merge($files, $this->getLucidPaths());
        }

        return $files;
    }
483725
public function toArray()
    {
        return [
            'name' => $this->name,
            'description' => $this->description,
            'author' => $this->author,
            'enabled' => $this->enabled,
            'path' => $this->path,
            'files' => $this->files,
        ];
    }
1067393
public function getFiles()
    {
        $files = get_included_files();

        if (class_exists('\O2System\Framework', false)) {
            foreach ($files as $key => $file) {

                if (strpos($file, 'autoload.php') !== false) {
                    unset($files[ $key ]);
                    continue;
                }

                $files[ $key ] = str_replace(PATH_ROOT, DIRECTORY_SEPARATOR, $file);
            }
        }

        return $files;
    }