Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F72682896
PonderAnswerPHIDType.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
Tue, Jul 16, 13:27
Size
944 B
Mime Type
text/x-php
Expires
Thu, Jul 18, 13:27 (1 d, 23 h)
Engine
blob
Format
Raw Data
Handle
19061162
Attached To
rPH Phabricator
PonderAnswerPHIDType.php
View Options
<?php
final
class
PonderAnswerPHIDType
extends
PhabricatorPHIDType
{
const
TYPECONST
=
'ANSW'
;
public
function
getTypeName
()
{
return
pht
(
'Ponder Answer'
);
}
public
function
getPHIDTypeApplicationClass
()
{
return
'PhabricatorPonderApplication'
;
}
public
function
newObject
()
{
return
new
PonderAnswer
();
}
protected
function
buildQueryForObjects
(
PhabricatorObjectQuery
$query
,
array
$phids
)
{
return
id
(
new
PonderAnswerQuery
())
->
withPHIDs
(
$phids
);
}
public
function
loadHandles
(
PhabricatorHandleQuery
$query
,
array
$handles
,
array
$objects
)
{
foreach
(
$handles
as
$phid
=>
$handle
)
{
$answer
=
$objects
[
$phid
];
$id
=
$answer
->
getID
();
$question
=
$answer
->
getQuestion
();
$question_title
=
$question
->
getFullTitle
();
$handle
->
setName
(
pht
(
'%s (Answer %s)'
,
$question_title
,
$id
));
$handle
->
setURI
(
$answer
->
getURI
());
}
}
}
Event Timeline
Log In to Comment