Differential D14970 Diff 36173 src/applications/diffusion/query/filecontent/DiffusionGitFileContentQuery.php
Changeset View
Changeset View
Standalone View
Standalone View
src/applications/diffusion/query/filecontent/DiffusionGitFileContentQuery.php
| <?php | <?php | ||||
| final class DiffusionGitFileContentQuery extends DiffusionFileContentQuery { | final class DiffusionGitFileContentQuery extends DiffusionFileContentQuery { | ||||
| public function getFileContentFuture() { | protected function getFileContentFuture() { | ||||
| $drequest = $this->getRequest(); | $drequest = $this->getRequest(); | ||||
| $repository = $drequest->getRepository(); | $repository = $drequest->getRepository(); | ||||
| $path = $drequest->getPath(); | $path = $drequest->getPath(); | ||||
| $commit = $drequest->getCommit(); | $commit = $drequest->getCommit(); | ||||
| return $repository->getLocalCommandFuture( | return $repository->getLocalCommandFuture( | ||||
| 'cat-file blob %s:%s', | 'cat-file blob %s:%s', | ||||
| $commit, | $commit, | ||||
| $path); | $path); | ||||
| } | } | ||||
| protected function executeQueryFromFuture(Future $future) { | protected function resolveFileContentFuture(Future $future) { | ||||
| list($corpus) = $future->resolvex(); | list($corpus) = $future->resolvex(); | ||||
| return $corpus; | |||||
| $file_content = new DiffusionFileContent(); | |||||
| $file_content->setCorpus($corpus); | |||||
| return $file_content; | |||||
| } | } | ||||
| } | } | ||||