Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F112047261
DivinerController.php
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Subscribers
None
File Metadata
Details
File Info
Storage
Attached
Created
Wed, May 7, 07:15
Size
1 KB
Mime Type
text/x-php
Expires
Fri, May 9, 07:15 (1 d, 23 h)
Engine
blob
Format
Raw Data
Handle
25992258
Attached To
rPH Phabricator
DivinerController.php
View Options
<?php
abstract
class
DivinerController
extends
PhabricatorController
{
protected
function
buildSideNavView
()
{
$menu
=
$this
->
buildApplicationMenu
();
return
AphrontSideNavFilterView
::
newFromMenu
(
$menu
);
}
public
function
buildApplicationMenu
()
{
$menu
=
new
PHUIListView
();
id
(
new
DivinerAtomSearchEngine
())
->
setViewer
(
$this
->
getRequest
()->
getViewer
())
->
addNavigationItems
(
$menu
);
return
$menu
;
}
protected
function
renderAtomList
(
array
$symbols
)
{
assert_instances_of
(
$symbols
,
'DivinerLiveSymbol'
);
$list
=
array
();
foreach
(
$symbols
as
$symbol
)
{
switch
(
$symbol
->
getType
())
{
case
DivinerAtom
::
TYPE_FUNCTION
:
$title
=
$symbol
->
getTitle
().
'()'
;
break
;
default
:
$title
=
$symbol
->
getTitle
();
break
;
}
$item
=
id
(
new
DivinerBookItemView
())
->
setTitle
(
$title
)
->
setHref
(
$symbol
->
getURI
())
->
setSubtitle
(
$symbol
->
getSummary
())
->
setType
(
DivinerAtom
::
getAtomTypeNameString
(
$symbol
->
getType
()));
$list
[]
=
$item
;
}
return
$list
;
}
}
Event Timeline
Log In to Comment