Path: blob/master/src/applications/files/document/render/PhabricatorFileDocumentRenderingEngine.php
12242 views
<?php12final class PhabricatorFileDocumentRenderingEngine3extends PhabricatorDocumentRenderingEngine {45protected function newRefViewURI(6PhabricatorDocumentRef $ref,7PhabricatorDocumentEngine $engine) {89$file = $ref->getFile();10$engine_key = $engine->getDocumentEngineKey();1112return urisprintf(13'/file/view/%d/%s/',14$file->getID(),15$engine_key);16}1718protected function newRefRenderURI(19PhabricatorDocumentRef $ref,20PhabricatorDocumentEngine $engine) {21$file = $ref->getFile();22if (!$file) {23throw new PhutilMethodNotImplementedException();24}2526$engine_key = $engine->getDocumentEngineKey();27$file_phid = $file->getPHID();2829return urisprintf(30'/file/document/%s/%s/',31$engine_key,32$file_phid);33}3435protected function addApplicationCrumbs(36PHUICrumbsView $crumbs,37PhabricatorDocumentRef $ref = null) {3839if ($ref) {40$file = $ref->getFile();41if ($file) {42$crumbs->addTextCrumb($file->getMonogram(), $file->getInfoURI());43}44}4546}4748}495051