Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F19470195
DiffusionResolveRefsConduitAPIMethod.php
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
954 B
Referenced Files
None
Subscribers
None
DiffusionResolveRefsConduitAPIMethod.php
View Options
<?php
final
class
DiffusionResolveRefsConduitAPIMethod
extends
DiffusionQueryConduitAPIMethod
{
public
function
getAPIMethodName
()
{
return
'diffusion.resolverefs'
;
}
public
function
getMethodDescription
()
{
return
pht
(
'Resolve references into stable, canonical identifiers.'
);
}
protected
function
defineReturnType
()
{
return
'dict<string, list<dict<string, wild>>>'
;
}
protected
function
defineCustomParamTypes
()
{
return
array
(
'refs'
=>
'required list<string>'
,
'types'
=>
'optional list<string>'
,
);
}
protected
function
getResult
(
ConduitAPIRequest
$request
)
{
$refs
=
$request
->
getValue
(
'refs'
);
$types
=
$request
->
getValue
(
'types'
);
$query
=
id
(
new
DiffusionLowLevelResolveRefsQuery
())
->
setRepository
(
$this
->
getDiffusionRequest
()->
getRepository
())
->
withRefs
(
$refs
);
if
(
$types
)
{
$query
->
withTypes
(
$types
);
}
return
$query
->
execute
();
}
}
File Metadata
Details
Attached
Mime Type
text/x-php
Expires
Wed, Jan 7, 11:05 AM (18 h, 54 m ago)
Storage Engine
blob
Storage Format
Encrypted (AES-256-CBC)
Storage Handle
8244762
Default Alt Text
DiffusionResolveRefsConduitAPIMethod.php (954 B)
Attached To
Mode
rP Phabricator
Attached
Detach File
Event Timeline
Log In to Comment