Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F79467935
ConduitQueryConduitAPIMethod.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
Mon, Aug 26, 13:40
Size
944 B
Mime Type
text/x-php
Expires
Wed, Aug 28, 13:40 (2 d)
Engine
blob
Format
Raw Data
Handle
20192695
Attached To
rPH Phabricator
ConduitQueryConduitAPIMethod.php
View Options
<?php
final
class
ConduitQueryConduitAPIMethod
extends
ConduitAPIMethod
{
public
function
getAPIMethodName
()
{
return
'conduit.query'
;
}
public
function
getMethodDescription
()
{
return
pht
(
'Returns the parameters of the Conduit methods.'
);
}
protected
function
defineParamTypes
()
{
return
array
();
}
protected
function
defineReturnType
()
{
return
'dict<dict>'
;
}
public
function
getRequiredScope
()
{
return
self
::
SCOPE_ALWAYS
;
}
protected
function
execute
(
ConduitAPIRequest
$request
)
{
$methods
=
id
(
new
PhabricatorConduitMethodQuery
())
->
setViewer
(
$request
->
getUser
())
->
execute
();
$map
=
array
();
foreach
(
$methods
as
$method
)
{
$map
[
$method
->
getAPIMethodName
()]
=
array
(
'description'
=>
$method
->
getMethodDescription
(),
'params'
=>
$method
->
getParamTypes
(),
'return'
=>
$method
->
getReturnType
(),
);
}
return
$map
;
}
}
Event Timeline
Log In to Comment