Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F100495578
PhabricatorOwnersPathsSearchEngineAttachment.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
Fri, Jan 31, 06:17
Size
783 B
Mime Type
text/x-php
Expires
Sun, Feb 2, 06:17 (1 d, 21 h)
Engine
blob
Format
Raw Data
Handle
23980359
Attached To
rPH Phabricator
PhabricatorOwnersPathsSearchEngineAttachment.php
View Options
<?php
final
class
PhabricatorOwnersPathsSearchEngineAttachment
extends
PhabricatorSearchEngineAttachment
{
public
function
getAttachmentName
()
{
return
pht
(
'Included Paths'
);
}
public
function
getAttachmentDescription
()
{
return
pht
(
'Get the paths for each package.'
);
}
public
function
willLoadAttachmentData
(
$query
,
$spec
)
{
$query
->
needPaths
(
true
);
}
public
function
getAttachmentForObject
(
$object
,
$data
,
$spec
)
{
$paths
=
$object
->
getPaths
();
$list
=
array
();
foreach
(
$paths
as
$path
)
{
$list
[]
=
array
(
'repositoryPHID'
=>
$path
->
getRepositoryPHID
(),
'path'
=>
$path
->
getPathDisplay
(),
'excluded'
=>
(
bool
)
$path
->
getExcluded
(),
);
}
return
array
(
'paths'
=>
$list
,
);
}
}
Event Timeline
Log In to Comment