Path: blob/master/src/applications/conduit/method/ConduitQueryConduitAPIMethod.php
12256 views
<?php12final class ConduitQueryConduitAPIMethod extends ConduitAPIMethod {34public function getAPIMethodName() {5return 'conduit.query';6}78public function getMethodDescription() {9return pht('Returns the parameters of the Conduit methods.');10}1112protected function defineParamTypes() {13return array();14}1516protected function defineReturnType() {17return 'dict<dict>';18}1920public function getRequiredScope() {21return self::SCOPE_ALWAYS;22}2324protected function execute(ConduitAPIRequest $request) {25$methods = id(new PhabricatorConduitMethodQuery())26->setViewer($request->getUser())27->execute();2829$map = array();30foreach ($methods as $method) {31$map[$method->getAPIMethodName()] = array(32'description' => $method->getMethodDescription(),33'params' => $method->getParamTypes(),34'return' => $method->getReturnType(),35);36}3738return $map;39}4041}424344