Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F72145014
PhabricatorTokenTokenPHIDType.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
Sun, Jul 14, 23:28
Size
799 B
Mime Type
text/x-php
Expires
Tue, Jul 16, 23:28 (1 d, 20 h)
Engine
blob
Format
Raw Data
Handle
19038777
Attached To
rPH Phabricator
PhabricatorTokenTokenPHIDType.php
View Options
<?php
final
class
PhabricatorTokenTokenPHIDType
extends
PhabricatorPHIDType
{
const
TYPECONST
=
'TOKN'
;
public
function
getTypeName
()
{
return
pht
(
'Token'
);
}
public
function
newObject
()
{
return
new
PhabricatorToken
();
}
public
function
getPHIDTypeApplicationClass
()
{
return
'PhabricatorTokensApplication'
;
}
protected
function
buildQueryForObjects
(
PhabricatorObjectQuery
$query
,
array
$phids
)
{
return
id
(
new
PhabricatorTokenQuery
())
->
withPHIDs
(
$phids
);
}
public
function
loadHandles
(
PhabricatorHandleQuery
$query
,
array
$handles
,
array
$objects
)
{
foreach
(
$handles
as
$phid
=>
$handle
)
{
$token
=
$objects
[
$phid
];
$name
=
$token
->
getName
();
$handle
->
setName
(
pht
(
'%s Token'
,
$name
));
}
}
}
Event Timeline
Log In to Comment