[ Index ]

PHP Cross Reference of Phabricator

title

Body

[close]

/src/applications/tokens/conduit/ -> TokenQueryConduitAPIMethod.php (source)

   1  <?php
   2  
   3  final class TokenQueryConduitAPIMethod extends TokenConduitAPIMethod {
   4  
   5    public function getAPIMethodName() {
   6      return 'token.query';
   7    }
   8  
   9    public function getMethodDescription() {
  10      return pht('Query tokens.');
  11    }
  12  
  13    public function defineParamTypes() {
  14      return array();
  15    }
  16  
  17    public function defineReturnType() {
  18      return 'list<dict>';
  19    }
  20  
  21    public function defineErrorTypes() {
  22      return array();
  23    }
  24  
  25    public function execute(ConduitAPIRequest $request) {
  26      $query = id(new PhabricatorTokenQuery())
  27        ->setViewer($request->getUser());
  28  
  29      $tokens = $query->execute();
  30  
  31      return $this->buildTokenDicts($tokens);
  32    }
  33  
  34  }


Generated: Sun Nov 30 09:20:46 2014 Cross-referenced by PHPXref 0.7.1