@recaptime-dev's working patches + fork for Phorge, a community fork of Phabricator. (Upstream dev and stable branches are at upstream/main and upstream/stable respectively.) hq.recaptime.dev/wiki/Phorge
phorge phabricator
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Replace __CLASS__ constant with self::class keyword

Summary:
`::class` is available since PHP 5.5.

* https://www.php.net/manual/en/language.constants.magic.php
* https://www.php.net/manual/en/language.oop5.basic.php#language.oop5.basic.class.class
* https://wiki.php.net/rfc/class_name_scalars#considerations

`::class` returns the fully qualified classname including namespace, however we do not use PHP namespaces except in imported external libraries untouched here.

(Also, I ideally like to grep for 1 term when trying to find the same stuff.)

Refs T15158

Test Plan: Browse random Phorge pages?

Reviewers: O1 Blessed Committers, mainframe98

Reviewed By: O1 Blessed Committers, mainframe98

Subscribers: mainframe98, tobiaswiese, valerio.bozzolan, Matthew, Cigaryno

Maniphest Tasks: T15158

Differential Revision: https://we.phorge.it/D26324

+160 -160
+1 -1
src/aphront/handler/AphrontRequestExceptionHandler.php
··· 22 22 23 23 final public static function getAllHandlers() { 24 24 return id(new PhutilClassMapQuery()) 25 - ->setAncestorClass(__CLASS__) 25 + ->setAncestorClass(self::class) 26 26 ->setSortMethod('getRequestExceptionHandlerPriority') 27 27 ->execute(); 28 28 }
+1 -1
src/aphront/httpparametertype/AphrontHTTPParameterType.php
··· 214 214 */ 215 215 final public static function getAllTypes() { 216 216 return id(new PhutilClassMapQuery()) 217 - ->setAncestorClass(__CLASS__) 217 + ->setAncestorClass(self::class) 218 218 ->setUniqueMethod('getTypeName') 219 219 ->setSortMethod('getTypeName') 220 220 ->execute();
+1 -1
src/aphront/response/AphrontProxyResponse.php
··· 74 74 throw new Exception( 75 75 pht( 76 76 '%s must implement %s.', 77 - __CLASS__, 77 + self::class, 78 78 'reduceProxyResponse()')); 79 79 } 80 80
+1 -1
src/aphront/response/AphrontResponse.php
··· 339 339 340 340 array_walk_recursive( 341 341 $object, 342 - array(__CLASS__, 'processValueForJSONEncoding')); 342 + array(self::class, 'processValueForJSONEncoding')); 343 343 344 344 $response = phutil_json_encode($object); 345 345
+1 -1
src/aphront/site/AphrontSite.php
··· 36 36 37 37 final public static function getAllSites() { 38 38 return id(new PhutilClassMapQuery()) 39 - ->setAncestorClass(__CLASS__) 39 + ->setAncestorClass(self::class) 40 40 ->setSortMethod('getPriority') 41 41 ->execute(); 42 42 }
+6 -6
src/aphront/writeguard/AphrontWriteGuard.php
··· 67 67 pht( 68 68 'An %s already exists. Dispose of the previous guard '. 69 69 'before creating a new one.', 70 - __CLASS__)); 70 + self::class)); 71 71 } 72 72 if (self::$allowUnguardedWrites) { 73 73 throw new Exception( ··· 75 75 'An %s is being created in a context which permits '. 76 76 'unguarded writes unconditionally. This is not allowed and '. 77 77 'indicates a serious error.', 78 - __CLASS__)); 78 + self::class)); 79 79 } 80 80 $this->callback = $callback; 81 81 self::$instance = $this; ··· 99 99 throw new Exception( 100 100 pht( 101 101 'Imbalanced %s: more %s calls than %s calls.', 102 - __CLASS__, 102 + self::class, 103 103 'beginUnguardedWrites()', 104 104 'endUnguardedWrites()')); 105 105 } ··· 155 155 throw new Exception( 156 156 pht( 157 157 'Unguarded write! There must be an active %s to perform writes.', 158 - __CLASS__)); 158 + self::class)); 159 159 } else { 160 160 // Unguarded writes are being allowed unconditionally. 161 161 return; ··· 231 231 throw new Exception( 232 232 pht( 233 233 'Imbalanced %s: more %s calls than %s calls.', 234 - __CLASS__, 234 + self::class, 235 235 'endUnguardedWrites()', 236 236 'beginUnguardedWrites()')); 237 237 } ··· 257 257 pht( 258 258 'You can not unconditionally disable %s by calling %s while a write '. 259 259 'guard is active. Use %s to temporarily allow unguarded writes.', 260 - __CLASS__, 260 + self::class, 261 261 __FUNCTION__.'()', 262 262 'beginUnguardedWrites()')); 263 263 }
+1 -1
src/applications/almanac/servicetype/AlmanacServiceType.php
··· 71 71 */ 72 72 public static function getAllServiceTypes() { 73 73 return id(new PhutilClassMapQuery()) 74 - ->setAncestorClass(__CLASS__) 74 + ->setAncestorClass(self::class) 75 75 ->setUniqueMethod('getServiceTypeConstant') 76 76 ->setSortMethod('getServiceTypeName') 77 77 ->execute();
+1 -1
src/applications/auth/engine/PhabricatorAuthSessionEngineExtension.php
··· 9 9 10 10 final public static function getAllExtensions() { 11 11 return id(new PhutilClassMapQuery()) 12 - ->setAncestorClass(__CLASS__) 12 + ->setAncestorClass(self::class) 13 13 ->setUniqueMethod('getExtensionKey') 14 14 ->execute(); 15 15 }
+1 -1
src/applications/auth/factor/PhabricatorAuthFactor.php
··· 27 27 28 28 public static function getAllFactors() { 29 29 return id(new PhutilClassMapQuery()) 30 - ->setAncestorClass(__CLASS__) 30 + ->setAncestorClass(self::class) 31 31 ->setUniqueMethod('getFactorKey') 32 32 ->execute(); 33 33 }
+1 -1
src/applications/auth/message/PhabricatorAuthMessageType.php
··· 9 9 10 10 final public static function getAllMessageTypes() { 11 11 return id(new PhutilClassMapQuery()) 12 - ->setAncestorClass(__CLASS__) 12 + ->setAncestorClass(self::class) 13 13 ->setUniqueMethod('getMessageTypeKey') 14 14 ->execute(); 15 15 }
+1 -1
src/applications/auth/provider/PhabricatorAuthProvider.php
··· 60 60 61 61 public static function getAllBaseProviders() { 62 62 return id(new PhutilClassMapQuery()) 63 - ->setAncestorClass(__CLASS__) 63 + ->setAncestorClass(self::class) 64 64 ->execute(); 65 65 } 66 66
+1 -1
src/applications/auth/revoker/PhabricatorAuthRevoker.php
··· 30 30 31 31 final public static function getAllRevokers() { 32 32 return id(new PhutilClassMapQuery()) 33 - ->setAncestorClass(__CLASS__) 33 + ->setAncestorClass(self::class) 34 34 ->setUniqueMethod('getRevokerKey') 35 35 ->execute(); 36 36 }
+2 -2
src/applications/auth/storage/PhabricatorAuthChallenge.php
··· 27 27 } 28 28 29 29 public static function newHTTPParametersFromChallenges(array $challenges) { 30 - assert_instances_of($challenges, __CLASS__); 30 + assert_instances_of($challenges, self::class); 31 31 32 32 $token_list = array(); 33 33 foreach ($challenges as $challenge) { ··· 54 54 public static function newChallengeResponsesFromRequest( 55 55 array $challenges, 56 56 AphrontRequest $request) { 57 - assert_instances_of($challenges, __CLASS__); 57 + assert_instances_of($challenges, self::class); 58 58 59 59 $token_list = $request->getStr(self::HTTPKEY, ''); 60 60 $token_list = explode(' ', $token_list);
+1 -1
src/applications/auth/tokentype/PhabricatorAuthTemporaryTokenType.php
··· 17 17 18 18 final public static function getAllTypes() { 19 19 return id(new PhutilClassMapQuery()) 20 - ->setAncestorClass(__CLASS__) 20 + ->setAncestorClass(self::class) 21 21 ->setUniqueMethod('getTokenTypeConstant') 22 22 ->execute(); 23 23 }
+1 -1
src/applications/base/PhabricatorApplication.php
··· 371 371 372 372 if ($applications === null) { 373 373 $apps = id(new PhutilClassMapQuery()) 374 - ->setAncestorClass(__CLASS__) 374 + ->setAncestorClass(self::class) 375 375 ->setSortMethod('getApplicationOrder') 376 376 ->execute(); 377 377
+1 -1
src/applications/cache/purger/PhabricatorCachePurger.php
··· 22 22 23 23 final public static function getAllPurgers() { 24 24 return id(new PhutilClassMapQuery()) 25 - ->setAncestorClass(__CLASS__) 25 + ->setAncestorClass(self::class) 26 26 ->setUniqueMethod('getPurgerKey') 27 27 ->execute(); 28 28 }
+1 -1
src/applications/calendar/import/PhabricatorCalendarImportEngine.php
··· 46 46 47 47 final public static function getAllImportEngines() { 48 48 return id(new PhutilClassMapQuery()) 49 - ->setAncestorClass(__CLASS__) 49 + ->setAncestorClass(self::class) 50 50 ->setUniqueMethod('getImportEngineType') 51 51 ->setSortMethod('getImportEngineName') 52 52 ->execute();
+1 -1
src/applications/calendar/importlog/PhabricatorCalendarImportLogType.php
··· 9 9 10 10 final public static function getAllLogTypes() { 11 11 return id(new PhutilClassMapQuery()) 12 - ->setAncestorClass(__CLASS__) 12 + ->setAncestorClass(self::class) 13 13 ->setUniqueMethod('getLogTypeConstant') 14 14 ->execute(); 15 15 }
+1 -1
src/applications/celerity/postprocessor/CelerityPostprocessor.php
··· 37 37 38 38 final public static function getAllPostprocessors() { 39 39 return id(new PhutilClassMapQuery()) 40 - ->setAncestorClass(__CLASS__) 40 + ->setAncestorClass(self::class) 41 41 ->setUniqueMethod('getPostprocessorKey') 42 42 ->execute(); 43 43 }
+1 -1
src/applications/celerity/resources/CelerityPhysicalResources.php
··· 24 24 25 25 if ($resources_map === null) { 26 26 $resources_list = id(new PhutilClassMapQuery()) 27 - ->setAncestorClass(__CLASS__) 27 + ->setAncestorClass(self::class) 28 28 ->setUniqueMethod('getName') 29 29 ->execute(); 30 30
+1 -1
src/applications/conduit/method/ConduitAPIMethod.php
··· 219 219 220 220 private static function newClassMapQuery() { 221 221 return id(new PhutilClassMapQuery()) 222 - ->setAncestorClass(__CLASS__) 222 + ->setAncestorClass(self::class) 223 223 ->setUniqueMethod('getAPIMethodName'); 224 224 } 225 225
+1 -1
src/applications/conduit/parametertype/ConduitParameterType.php
··· 74 74 75 75 final public static function getAllTypes() { 76 76 return id(new PhutilClassMapQuery()) 77 - ->setAncestorClass(__CLASS__) 77 + ->setAncestorClass(self::class) 78 78 ->setUniqueMethod('getTypeName') 79 79 ->setSortMethod('getTypeName') 80 80 ->execute();
+1 -1
src/applications/config/check/PhabricatorSetupCheck.php
··· 239 239 240 240 final public static function loadAllChecks() { 241 241 return id(new PhutilClassMapQuery()) 242 - ->setAncestorClass(__CLASS__) 242 + ->setAncestorClass(self::class) 243 243 ->setSortMethod('getExecutionOrder') 244 244 ->execute(); 245 245 }
+1 -1
src/applications/config/module/PhabricatorConfigModule.php
··· 8 8 9 9 final public static function getAllModules() { 10 10 return id(new PhutilClassMapQuery()) 11 - ->setAncestorClass(__CLASS__) 11 + ->setAncestorClass(self::class) 12 12 ->setUniqueMethod('getModuleKey') 13 13 ->setSortMethod('getModuleName') 14 14 ->execute();
+3 -3
src/applications/config/option/PhabricatorApplicationConfigOptions.php
··· 98 98 99 99 final public static function loadAll($external_only = false) { 100 100 $symbols = id(new PhutilSymbolLoader()) 101 - ->setAncestorClass(__CLASS__) 101 + ->setAncestorClass(self::class) 102 102 ->setConcreteOnly(true) 103 103 ->selectAndLoadSymbols(); 104 104 ··· 117 117 throw new Exception( 118 118 pht( 119 119 "Multiple %s subclasses have the same key ('%s'): %s, %s.", 120 - __CLASS__, 120 + self::class, 121 121 $key, 122 122 $pclass, 123 123 $nclass)); ··· 139 139 throw new Exception( 140 140 pht( 141 141 "Multiple %s subclasses contain an option named '%s'!", 142 - __CLASS__, 142 + self::class, 143 143 $key)); 144 144 } 145 145 $options[$key] = $option;
+1 -1
src/applications/config/type/PhabricatorConfigType.php
··· 8 8 9 9 final public static function getAllTypes() { 10 10 return id(new PhutilClassMapQuery()) 11 - ->setAncestorClass(__CLASS__) 11 + ->setAncestorClass(self::class) 12 12 ->setUniqueMethod('getTypeKey') 13 13 ->execute(); 14 14 }
+1 -1
src/applications/conpherence/storage/ConpherenceThread.php
··· 278 278 PhabricatorUser $viewer, 279 279 array $conpherences) { 280 280 281 - assert_instances_of($conpherences, __CLASS__); 281 + assert_instances_of($conpherences, self::class); 282 282 283 283 $policies = array(); 284 284 foreach ($conpherences as $room) {
+1 -1
src/applications/console/plugin/errorlog/DarkConsoleErrorLogPluginAPI.php
··· 12 12 // reenter autoloaders). 13 13 PhutilReadableSerializer::printableValue(null); 14 14 PhutilErrorHandler::setErrorListener( 15 - array(__CLASS__, 'handleErrors')); 15 + array(self::class, 'handleErrors')); 16 16 } 17 17 18 18 public static function enableDiscardMode() {
+1 -1
src/applications/daemon/management/PhabricatorDaemonManagementWorkflow.php
··· 152 152 // subprocess which will terminate normally. 153 153 pcntl_signal( 154 154 SIGINT, 155 - array(__CLASS__, 'ignoreSignal')); 155 + array(self::class, 'ignoreSignal')); 156 156 157 157 echo "\n scripts/daemon/ \$ {$command}\n\n"; 158 158
+1 -1
src/applications/dashboard/install/PhabricatorDashboardInstallWorkflow.php
··· 50 50 51 51 final public static function getAllWorkflows() { 52 52 return id(new PhutilClassMapQuery()) 53 - ->setAncestorClass(__CLASS__) 53 + ->setAncestorClass(self::class) 54 54 ->setUniqueMethod('getWorkflowKey') 55 55 ->setSortMethod('getOrder') 56 56 ->execute();
+1 -1
src/applications/dashboard/layoutconfig/PhabricatorDashboardLayoutMode.php
··· 20 20 21 21 final public static function getAllLayoutModes() { 22 22 return id(new PhutilClassMapQuery()) 23 - ->setAncestorClass(__CLASS__) 23 + ->setAncestorClass(self::class) 24 24 ->setUniqueMethod('getLayoutModeKey') 25 25 ->setSortMethod('getLayoutModeOrder') 26 26 ->execute();
+1 -1
src/applications/dashboard/paneltype/PhabricatorDashboardPanelType.php
··· 40 40 41 41 public static function getAllPanelTypes() { 42 42 return id(new PhutilClassMapQuery()) 43 - ->setAncestorClass(__CLASS__) 43 + ->setAncestorClass(self::class) 44 44 ->setUniqueMethod('getPanelTypeKey') 45 45 ->execute(); 46 46 }
+1 -1
src/applications/differential/field/DifferentialCommitMessageField.php
··· 95 95 96 96 final public static function getAllFields() { 97 97 return id(new PhutilClassMapQuery()) 98 - ->setAncestorClass(__CLASS__) 98 + ->setAncestorClass(self::class) 99 99 ->setUniqueMethod('getCommitMessageFieldKey') 100 100 ->setSortMethod('getFieldOrder') 101 101 ->execute();
+1 -1
src/applications/differential/query/DifferentialRevisionResultBucket.php
··· 5 5 6 6 public static function getAllResultBuckets() { 7 7 return id(new PhutilClassMapQuery()) 8 - ->setAncestorClass(__CLASS__) 8 + ->setAncestorClass(self::class) 9 9 ->setUniqueMethod('getResultBucketKey') 10 10 ->execute(); 11 11 }
+1 -1
src/applications/differential/xaction/DifferentialRevisionActionTransaction.php
··· 74 74 75 75 public static function loadAllActions() { 76 76 return id(new PhutilClassMapQuery()) 77 - ->setAncestorClass(__CLASS__) 77 + ->setAncestorClass(self::class) 78 78 ->setUniqueMethod('getRevisionActionKey') 79 79 ->execute(); 80 80 }
+2 -2
src/applications/diffusion/data/DiffusionPathChange.php
··· 117 117 } 118 118 119 119 public static function convertToArcanistChanges(array $changes) { 120 - assert_instances_of($changes, __CLASS__); 120 + assert_instances_of($changes, self::class); 121 121 $direct = array(); 122 122 $result = array(); 123 123 foreach ($changes as $path) { ··· 143 143 public static function convertToDifferentialChangesets( 144 144 PhabricatorUser $user, 145 145 array $changes) { 146 - assert_instances_of($changes, __CLASS__); 146 + assert_instances_of($changes, self::class); 147 147 $arcanist_changes = self::convertToArcanistChanges($changes); 148 148 $diff = DifferentialDiff::newEphemeralFromRawChanges( 149 149 $arcanist_changes);
+1 -1
src/applications/diffusion/management/DiffusionRepositoryManagementPanel.php
··· 58 58 59 59 public static function getAllPanels() { 60 60 return id(new PhutilClassMapQuery()) 61 - ->setAncestorClass(__CLASS__) 61 + ->setAncestorClass(self::class) 62 62 ->setUniqueMethod('getManagementPanelKey') 63 63 ->setSortMethod('getManagementPanelOrder') 64 64 ->execute();
+1 -1
src/applications/diffusion/management/DiffusionRepositoryManagementPanelGroup.php
··· 12 12 13 13 public static function getAllPanelGroups() { 14 14 return id(new PhutilClassMapQuery()) 15 - ->setAncestorClass(__CLASS__) 15 + ->setAncestorClass(self::class) 16 16 ->setUniqueMethod('getManagementPanelGroupKey') 17 17 ->setSortMethod('getManagementPanelGroupOrder') 18 18 ->execute();
+1 -1
src/applications/diffusion/protocol/DiffusionCommandEngine.php
··· 30 30 31 31 private static function newCommandEngines() { 32 32 return id(new PhutilClassMapQuery()) 33 - ->setAncestorClass(__CLASS__) 33 + ->setAncestorClass(self::class) 34 34 ->execute(); 35 35 } 36 36
+1 -1
src/applications/diffusion/query/DiffusionCommitResultBucket.php
··· 5 5 6 6 public static function getAllResultBuckets() { 7 7 return id(new PhutilClassMapQuery()) 8 - ->setAncestorClass(__CLASS__) 8 + ->setAncestorClass(self::class) 9 9 ->setUniqueMethod('getResultBucketKey') 10 10 ->execute(); 11 11 }
+1 -1
src/applications/diffusion/query/blame/DiffusionBlameQuery.php
··· 29 29 30 30 final public static function newFromDiffusionRequest( 31 31 DiffusionRequest $request) { 32 - return parent::newQueryObject(__CLASS__, $request); 32 + return parent::newQueryObject(self::class, $request); 33 33 } 34 34 35 35 final protected function executeQuery() {
+1 -1
src/applications/diffusion/query/filecontent/DiffusionFileContentQuery.php
··· 5 5 6 6 final public static function newFromDiffusionRequest( 7 7 DiffusionRequest $request) { 8 - return parent::newQueryObject(__CLASS__, $request); 8 + return parent::newQueryObject(self::class, $request); 9 9 } 10 10 11 11 }
+1 -1
src/applications/diffusion/query/rawdiff/DiffusionRawDiffQuery.php
··· 9 9 10 10 final public static function newFromDiffusionRequest( 11 11 DiffusionRequest $request) { 12 - return parent::newQueryObject(__CLASS__, $request); 12 + return parent::newQueryObject(self::class, $request); 13 13 } 14 14 15 15 final public function setLinesOfContext($lines_of_context) {
+1 -1
src/applications/diffusion/xaction/DiffusionCommitActionTransaction.php
··· 53 53 54 54 public static function loadAllActions() { 55 55 return id(new PhutilClassMapQuery()) 56 - ->setAncestorClass(__CLASS__) 56 + ->setAncestorClass(self::class) 57 57 ->setUniqueMethod('getCommitActionKey') 58 58 ->execute(); 59 59 }
+2 -2
src/applications/diviner/storage/DivinerLiveSymbol.php
··· 194 194 } 195 195 196 196 public function attachExtends(array $extends) { 197 - assert_instances_of($extends, __CLASS__); 197 + assert_instances_of($extends, self::class); 198 198 $this->extends = $extends; 199 199 return $this; 200 200 } ··· 204 204 } 205 205 206 206 public function attachChildren(array $children) { 207 - assert_instances_of($children, __CLASS__); 207 + assert_instances_of($children, self::class); 208 208 $this->children = $children; 209 209 return $this; 210 210 }
+1 -1
src/applications/drydock/blueprint/DrydockBlueprintImplementation.php
··· 327 327 328 328 public static function getAllBlueprintImplementations() { 329 329 return id(new PhutilClassMapQuery()) 330 - ->setAncestorClass(__CLASS__) 330 + ->setAncestorClass(self::class) 331 331 ->execute(); 332 332 } 333 333
+1 -1
src/applications/drydock/logtype/DrydockLogType.php
··· 34 34 35 35 final public static function getAllLogTypes() { 36 36 return id(new PhutilClassMapQuery()) 37 - ->setAncestorClass(__CLASS__) 37 + ->setAncestorClass(self::class) 38 38 ->setUniqueMethod('getLogTypeConstant') 39 39 ->execute(); 40 40 }
+1 -1
src/applications/drydock/operation/DrydockRepositoryOperationType.php
··· 58 58 59 59 final public static function getAllOperationTypes() { 60 60 return id(new PhutilClassMapQuery()) 61 - ->setAncestorClass(__CLASS__) 61 + ->setAncestorClass(self::class) 62 62 ->setUniqueMethod('getOperationConstant') 63 63 ->execute(); 64 64 }
+2 -2
src/applications/drydock/worker/DrydockLeaseUpdateWorker.php
··· 919 919 // activate it. 920 920 if ($lease->getStatus() == DrydockLeaseStatus::STATUS_ACQUIRED) { 921 921 $this->queueTask( 922 - __CLASS__, 922 + self::class, 923 923 array( 924 924 'leasePHID' => $lease->getPHID(), 925 925 ), ··· 1088 1088 $lease->awakenTasks(); 1089 1089 1090 1090 $this->queueTask( 1091 - __CLASS__, 1091 + self::class, 1092 1092 array( 1093 1093 'leasePHID' => $lease->getPHID(), 1094 1094 ),
+1 -1
src/applications/fact/chart/PhabricatorChartDataset.php
··· 26 26 27 27 final public static function getAllDatasetTypes() { 28 28 return id(new PhutilClassMapQuery()) 29 - ->setAncestorClass(__CLASS__) 29 + ->setAncestorClass(self::class) 30 30 ->setUniqueMethod('getDatasetTypeKey') 31 31 ->execute(); 32 32 }
+1 -1
src/applications/fact/chart/PhabricatorChartFunction.php
··· 18 18 */ 19 19 final public static function getAllFunctions() { 20 20 return id(new PhutilClassMapQuery()) 21 - ->setAncestorClass(__CLASS__) 21 + ->setAncestorClass(self::class) 22 22 ->setUniqueMethod('getFunctionKey') 23 23 ->execute(); 24 24 }
+1 -1
src/applications/fact/engine/PhabricatorChartEngine.php
··· 51 51 */ 52 52 final public static function getAllChartEngines() { 53 53 return id(new PhutilClassMapQuery()) 54 - ->setAncestorClass(__CLASS__) 54 + ->setAncestorClass(self::class) 55 55 ->setUniqueMethod('getChartEngineKey') 56 56 ->execute(); 57 57 }
+1 -1
src/applications/fact/engine/PhabricatorFactEngine.php
··· 7 7 8 8 final public static function loadAllEngines() { 9 9 return id(new PhutilClassMapQuery()) 10 - ->setAncestorClass(__CLASS__) 10 + ->setAncestorClass(self::class) 11 11 ->execute(); 12 12 } 13 13
+1 -1
src/applications/feed/story/PhabricatorFeedStory.php
··· 49 49 try { 50 50 $ok = 51 51 class_exists($class) && 52 - is_subclass_of($class, __CLASS__); 52 + is_subclass_of($class, self::class); 53 53 } catch (PhutilMissingSymbolException $ex) { 54 54 $ok = false; 55 55 }
+1 -1
src/applications/files/document/PhabricatorDocumentEngine.php
··· 160 160 161 161 final public static function getAllEngines() { 162 162 return id(new PhutilClassMapQuery()) 163 - ->setAncestorClass(__CLASS__) 163 + ->setAncestorClass(self::class) 164 164 ->setUniqueMethod('getDocumentEngineKey') 165 165 ->execute(); 166 166 }
+1 -1
src/applications/files/engine/PhabricatorFileStorageEngine.php
··· 227 227 */ 228 228 public static function loadAllEngines() { 229 229 return id(new PhutilClassMapQuery()) 230 - ->setAncestorClass(__CLASS__) 230 + ->setAncestorClass(self::class) 231 231 ->setUniqueMethod('getEngineIdentifier') 232 232 ->setSortMethod('getEnginePriority') 233 233 ->execute();
+1 -1
src/applications/files/format/PhabricatorFileStorageFormat.php
··· 59 59 60 60 final public static function getAllFormats() { 61 61 return id(new PhutilClassMapQuery()) 62 - ->setAncestorClass(__CLASS__) 62 + ->setAncestorClass(self::class) 63 63 ->setUniqueMethod('getStorageFormatKey') 64 64 ->execute(); 65 65 }
+1 -1
src/applications/files/iconset/PhabricatorIconSet.php
··· 64 64 65 65 final public static function getAllIconSets() { 66 66 return id(new PhutilClassMapQuery()) 67 - ->setAncestorClass(__CLASS__) 67 + ->setAncestorClass(self::class) 68 68 ->setUniqueMethod('getIconSetKey') 69 69 ->execute(); 70 70 }
+1 -1
src/applications/files/transform/PhabricatorFileTransform.php
··· 53 53 54 54 public static function getAllTransforms() { 55 55 return id(new PhutilClassMapQuery()) 56 - ->setAncestorClass(__CLASS__) 56 + ->setAncestorClass(self::class) 57 57 ->setExpandMethod('generateTransforms') 58 58 ->setUniqueMethod('getTransformKey') 59 59 ->execute();
+1 -1
src/applications/guides/guidance/PhabricatorGuidanceEngineExtension.php
··· 31 31 32 32 final public static function getAllExtensions() { 33 33 return id(new PhutilClassMapQuery()) 34 - ->setAncestorClass(__CLASS__) 34 + ->setAncestorClass(self::class) 35 35 ->setUniqueMethod('getExtensionKey') 36 36 ->execute(); 37 37 }
+2 -2
src/applications/guides/module/PhabricatorGuideModule.php
··· 10 10 11 11 final public static function getAllModules() { 12 12 return id(new PhutilClassMapQuery()) 13 - ->setAncestorClass(__CLASS__) 13 + ->setAncestorClass(self::class) 14 14 ->setUniqueMethod('getModuleKey') 15 15 ->setSortMethod('getModulePosition') 16 16 ->execute(); ··· 18 18 19 19 final public static function getEnabledModules() { 20 20 return id(new PhutilClassMapQuery()) 21 - ->setAncestorClass(__CLASS__) 21 + ->setAncestorClass(self::class) 22 22 ->setUniqueMethod('getModuleKey') 23 23 ->setSortMethod('getModulePosition') 24 24 ->setFilterMethod('getIsModuleEnabled')
+1 -1
src/applications/harbormaster/artifact/HarbormasterArtifact.php
··· 52 52 53 53 final public static function getAllArtifactTypes() { 54 54 return id(new PhutilClassMapQuery()) 55 - ->setAncestorClass(__CLASS__) 55 + ->setAncestorClass(self::class) 56 56 ->setUniqueMethod('getArtifactConstant') 57 57 ->execute(); 58 58 }
+1 -1
src/applications/harbormaster/autoplan/HarbormasterBuildAutoplan.php
··· 11 11 12 12 public static function getAllAutoplans() { 13 13 return id(new PhutilClassMapQuery()) 14 - ->setAncestorClass(__CLASS__) 14 + ->setAncestorClass(self::class) 15 15 ->setUniqueMethod('getAutoplanPlanKey') 16 16 ->execute(); 17 17 }
+1 -1
src/applications/harbormaster/integration/HarbormasterHookHandler.php
··· 5 5 6 6 public static function getHandlers() { 7 7 return id(new PhutilClassMapQuery()) 8 - ->setAncestorClass(__CLASS__) 8 + ->setAncestorClass(self::class) 9 9 ->setUniqueMethod('getName') 10 10 ->execute(); 11 11 }
+1 -1
src/applications/harbormaster/step/HarbormasterBuildStepImplementation.php
··· 19 19 20 20 public static function getImplementations() { 21 21 return id(new PhutilClassMapQuery()) 22 - ->setAncestorClass(__CLASS__) 22 + ->setAncestorClass(self::class) 23 23 ->execute(); 24 24 } 25 25
+1 -1
src/applications/harbormaster/stepgroup/HarbormasterBuildStepGroup.php
··· 19 19 20 20 final public static function getAllGroups() { 21 21 return id(new PhutilClassMapQuery()) 22 - ->setAncestorClass(__CLASS__) 22 + ->setAncestorClass(self::class) 23 23 ->setUniqueMethod('getGroupKey') 24 24 ->setSortMethod('getGroupOrder') 25 25 ->execute();
+1 -1
src/applications/harbormaster/xaction/build/HarbormasterBuildMessageTransaction.php
··· 45 45 46 46 final public static function getAllMessages() { 47 47 $message_xactions = id(new PhutilClassMapQuery()) 48 - ->setAncestorClass(__CLASS__) 48 + ->setAncestorClass(self::class) 49 49 ->execute(); 50 50 51 51 return $message_xactions;
+1 -1
src/applications/herald/action/HeraldAction.php
··· 151 151 152 152 final public static function getAllActions() { 153 153 return id(new PhutilClassMapQuery()) 154 - ->setAncestorClass(__CLASS__) 154 + ->setAncestorClass(self::class) 155 155 ->setUniqueMethod('getActionConstant') 156 156 ->execute(); 157 157 }
+1 -1
src/applications/herald/action/HeraldActionGroup.php
··· 8 8 9 9 final public static function getAllActionGroups() { 10 10 return id(new PhutilClassMapQuery()) 11 - ->setAncestorClass(__CLASS__) 11 + ->setAncestorClass(self::class) 12 12 ->setUniqueMethod('getGroupKey') 13 13 ->setSortMethod('getSortKey') 14 14 ->execute();
+1 -1
src/applications/herald/adapter/HeraldAdapter.php
··· 883 883 884 884 public static function getAllAdapters() { 885 885 return id(new PhutilClassMapQuery()) 886 - ->setAncestorClass(__CLASS__) 886 + ->setAncestorClass(self::class) 887 887 ->setUniqueMethod('getAdapterContentType') 888 888 ->setSortMethod('getAdapterSortKey') 889 889 ->execute();
+1 -1
src/applications/herald/field/HeraldField.php
··· 243 243 244 244 final public static function getAllFields() { 245 245 return id(new PhutilClassMapQuery()) 246 - ->setAncestorClass(__CLASS__) 246 + ->setAncestorClass(self::class) 247 247 ->setUniqueMethod('getFieldConstant') 248 248 ->execute(); 249 249 }
+1 -1
src/applications/herald/field/HeraldFieldGroup.php
··· 8 8 9 9 final public static function getAllFieldGroups() { 10 10 return id(new PhutilClassMapQuery()) 11 - ->setAncestorClass(__CLASS__) 11 + ->setAncestorClass(self::class) 12 12 ->setUniqueMethod('getGroupKey') 13 13 ->setSortMethod('getSortKey') 14 14 ->execute();
+1 -1
src/applications/herald/state/HeraldStateReasons.php
··· 6 6 7 7 final public static function getAllReasons() { 8 8 return id(new PhutilClassMapQuery()) 9 - ->setAncestorClass(__CLASS__) 9 + ->setAncestorClass(self::class) 10 10 ->execute(); 11 11 } 12 12
+1 -1
src/applications/meta/panel/PhabricatorApplicationConfigurationPanel.php
··· 54 54 55 55 public static function loadAllPanels() { 56 56 return id(new PhutilClassMapQuery()) 57 - ->setAncestorClass(__CLASS__) 57 + ->setAncestorClass(self::class) 58 58 ->setUniqueMethod('getPanelKey') 59 59 ->execute(); 60 60 }
+1 -1
src/applications/metamta/adapter/PhabricatorMailAdapter.php
··· 18 18 19 19 final public static function getAllAdapters() { 20 20 return id(new PhutilClassMapQuery()) 21 - ->setAncestorClass(__CLASS__) 21 + ->setAncestorClass(self::class) 22 22 ->setUniqueMethod('getAdapterType') 23 23 ->execute(); 24 24 }
+2 -2
src/applications/metamta/command/MetaMTAEmailTransactionCommand.php
··· 61 61 62 62 public static function getAllCommands() { 63 63 return id(new PhutilClassMapQuery()) 64 - ->setAncestorClass(__CLASS__) 64 + ->setAncestorClass(self::class) 65 65 ->setExpandMethod('getCommandObjects') 66 66 ->setUniqueMethod('getCommand') 67 67 ->execute(); ··· 81 81 } 82 82 83 83 public static function getCommandMap(array $commands) { 84 - assert_instances_of($commands, __CLASS__); 84 + assert_instances_of($commands, self::class); 85 85 86 86 $map = array(); 87 87 foreach ($commands as $command) {
+1 -1
src/applications/metamta/engine/PhabricatorMailEngineExtension.php
··· 35 35 36 36 final public static function getAllExtensions() { 37 37 return id(new PhutilClassMapQuery()) 38 - ->setAncestorClass(__CLASS__) 38 + ->setAncestorClass(self::class) 39 39 ->setUniqueMethod('getExtensionKey') 40 40 ->execute(); 41 41 }
+1 -1
src/applications/metamta/message/PhabricatorMailExternalMessage.php
··· 9 9 10 10 final public static function getAllMessageTypes() { 11 11 return id(new PhutilClassMapQuery()) 12 - ->setAncestorClass(__CLASS__) 12 + ->setAncestorClass(self::class) 13 13 ->setUniqueMethod('getMessageType') 14 14 ->execute(); 15 15 }
+1 -1
src/applications/metamta/stamp/PhabricatorMailStamp.php
··· 62 62 63 63 final public static function getAllStamps() { 64 64 return id(new PhutilClassMapQuery()) 65 - ->setAncestorClass(__CLASS__) 65 + ->setAncestorClass(self::class) 66 66 ->setUniqueMethod('getStampType') 67 67 ->execute(); 68 68 }
+1 -1
src/applications/nuance/command/NuanceCommandImplementation.php
··· 91 91 92 92 final public static function getAllCommands() { 93 93 return id(new PhutilClassMapQuery()) 94 - ->setAncestorClass(__CLASS__) 94 + ->setAncestorClass(self::class) 95 95 ->setUniqueMethod('getCommandKey') 96 96 ->execute(); 97 97 }
+1 -1
src/applications/nuance/item/NuanceItemType.php
··· 79 79 80 80 final public static function getAllItemTypes() { 81 81 return id(new PhutilClassMapQuery()) 82 - ->setAncestorClass(__CLASS__) 82 + ->setAncestorClass(self::class) 83 83 ->setUniqueMethod('getItemTypeConstant') 84 84 ->execute(); 85 85 }
+1 -1
src/applications/nuance/source/NuanceSourceDefinition.php
··· 38 38 39 39 public static function getAllDefinitions() { 40 40 return id(new PhutilClassMapQuery()) 41 - ->setAncestorClass(__CLASS__) 41 + ->setAncestorClass(self::class) 42 42 ->setUniqueMethod('getSourceTypeConstant') 43 43 ->execute(); 44 44 }
+1 -1
src/applications/passphrase/credentialtype/PassphraseCredentialType.php
··· 17 17 18 18 public static function getAllTypes() { 19 19 return id(new PhutilClassMapQuery()) 20 - ->setAncestorClass(__CLASS__) 20 + ->setAncestorClass(self::class) 21 21 ->setUniqueMethod('getCredentialType') 22 22 ->execute(); 23 23 }
+1 -1
src/applications/people/cache/PhabricatorUserCacheType.php
··· 40 40 41 41 public static function getAllCacheTypes() { 42 42 return id(new PhutilClassMapQuery()) 43 - ->setAncestorClass(__CLASS__) 43 + ->setAncestorClass(self::class) 44 44 ->setUniqueMethod('getUserCacheType') 45 45 ->execute(); 46 46 }
+1 -1
src/applications/people/userlog/PhabricatorUserLogType.php
··· 11 11 12 12 final public static function getAllLogTypes() { 13 13 return id(new PhutilClassMapQuery()) 14 - ->setAncestorClass(__CLASS__) 14 + ->setAncestorClass(self::class) 15 15 ->setUniqueMethod('getLogTypeKey') 16 16 ->execute(); 17 17 }
+1 -1
src/applications/phid/handle/pool/PhabricatorHandleList.php
··· 191 191 pht( 192 192 'Trying to mutate a %s, but this is not permitted; '. 193 193 'handle lists are immutable.', 194 - __CLASS__)); 194 + self::class)); 195 195 } 196 196 197 197
+2 -2
src/applications/phid/type/PhabricatorPHIDType.php
··· 10 10 pht( 11 11 '%s class "%s" has an invalid %s property. PHID '. 12 12 'constants must be a four character uppercase string.', 13 - __CLASS__, 13 + self::class, 14 14 get_class($this), 15 15 'TYPECONST')); 16 16 } ··· 163 163 164 164 private static function newClassMapQuery() { 165 165 return id(new PhutilClassMapQuery()) 166 - ->setAncestorClass(__CLASS__) 166 + ->setAncestorClass(self::class) 167 167 ->setUniqueMethod('getTypeConstant'); 168 168 } 169 169
+1 -1
src/applications/phrequent/storage/PhrequentTimeBlock.php
··· 72 72 // Now, figure out how much time was actually spent working on the 73 73 // object. 74 74 75 - usort($timeline, array(__CLASS__, 'sortTimeline')); 75 + usort($timeline, array(self::class, 'sortTimeline')); 76 76 77 77 $stack = array(); 78 78 $depth = null;
+1 -1
src/applications/policy/capability/PhabricatorPolicyCapability.php
··· 59 59 60 60 final public static function getCapabilityMap() { 61 61 return id(new PhutilClassMapQuery()) 62 - ->setAncestorClass(__CLASS__) 62 + ->setAncestorClass(self::class) 63 63 ->setUniqueMethod('getCapabilityKey') 64 64 ->execute(); 65 65 }
+1 -1
src/applications/policy/codex/PhabricatorPolicyCodex.php
··· 104 104 get_class($object), 105 105 'PhabricatorPolicyCodexInterface', 106 106 'newPolicyCodex()', 107 - __CLASS__)); 107 + self::class)); 108 108 } 109 109 110 110 $codex
+1 -1
src/applications/project/order/PhabricatorProjectColumnOrder.php
··· 20 20 21 21 final public static function getAllOrders() { 22 22 return id(new PhutilClassMapQuery()) 23 - ->setAncestorClass(__CLASS__) 23 + ->setAncestorClass(self::class) 24 24 ->setUniqueMethod('getColumnOrderKey') 25 25 ->setSortMethod('getMenuOrder') 26 26 ->execute();
+1 -1
src/applications/project/trigger/PhabricatorProjectTriggerRule.php
··· 15 15 16 16 final public static function getAllTriggerRules() { 17 17 return id(new PhutilClassMapQuery()) 18 - ->setAncestorClass(__CLASS__) 18 + ->setAncestorClass(self::class) 19 19 ->setUniqueMethod('getTriggerType') 20 20 ->execute(); 21 21 }
+1 -1
src/applications/repository/daemon/PhabricatorRepositoryPullLocalDaemon.php
··· 37 37 */ 38 38 protected function run() { 39 39 $argv = $this->getArgv(); 40 - array_unshift($argv, __CLASS__); 40 + array_unshift($argv, self::class); 41 41 $args = new PhutilArgumentParser($argv); 42 42 $args->parse( 43 43 array(
+1 -1
src/applications/repository/graphcache/PhabricatorRepositoryGraphCache.php
··· 110 110 111 111 // Sanity check so we can survive and recover from bad data. 112 112 if (isset($seen[$commit_id])) { 113 - phlog(pht('Unexpected infinite loop in %s!', __CLASS__)); 113 + phlog(pht('Unexpected infinite loop in %s!', self::class)); 114 114 return false; 115 115 } else { 116 116 $seen[$commit_id] = true;
+1 -1
src/applications/search/engine/PhabricatorApplicationSearchEngine.php
··· 685 685 */ 686 686 public static function getAllEngines() { 687 687 return id(new PhutilClassMapQuery()) 688 - ->setAncestorClass(__CLASS__) 688 + ->setAncestorClass(self::class) 689 689 ->execute(); 690 690 } 691 691
+1 -1
src/applications/search/engineextension/PhabricatorDatasourceEngineExtension.php
··· 28 28 29 29 final public static function getAllExtensions() { 30 30 return id(new PhutilClassMapQuery()) 31 - ->setAncestorClass(__CLASS__) 31 + ->setAncestorClass(self::class) 32 32 ->execute(); 33 33 } 34 34
+1 -1
src/applications/search/engineextension/PhabricatorHovercardEngineExtension.php
··· 39 39 40 40 final public static function getAllExtensions() { 41 41 return id(new PhutilClassMapQuery()) 42 - ->setAncestorClass(__CLASS__) 42 + ->setAncestorClass(self::class) 43 43 ->setUniqueMethod('getExtensionKey') 44 44 ->setSortMethod('getExtensionOrder') 45 45 ->execute();
+1 -1
src/applications/search/engineextension/PhabricatorSearchEngineExtension.php
··· 110 110 */ 111 111 final public static function getAllExtensions() { 112 112 return id(new PhutilClassMapQuery()) 113 - ->setAncestorClass(__CLASS__) 113 + ->setAncestorClass(self::class) 114 114 ->setUniqueMethod('getExtensionKey') 115 115 ->setSortMethod('getExtensionOrder') 116 116 ->execute();
+1 -1
src/applications/search/index/PhabricatorFulltextEngineExtension.php
··· 34 34 35 35 final public static function getAllExtensions() { 36 36 return id(new PhutilClassMapQuery()) 37 - ->setAncestorClass(__CLASS__) 37 + ->setAncestorClass(self::class) 38 38 ->setUniqueMethod('getExtensionKey') 39 39 ->execute(); 40 40 }
+1 -1
src/applications/search/index/PhabricatorIndexEngineExtension.php
··· 36 36 37 37 final public static function getAllExtensions() { 38 38 return id(new PhutilClassMapQuery()) 39 - ->setAncestorClass(__CLASS__) 39 + ->setAncestorClass(self::class) 40 40 ->setUniqueMethod('getExtensionKey') 41 41 ->execute(); 42 42 }
+1 -1
src/applications/search/menuitem/PhabricatorProfileMenuItem.php
··· 61 61 62 62 final public static function getAllMenuItems() { 63 63 return id(new PhutilClassMapQuery()) 64 - ->setAncestorClass(__CLASS__) 64 + ->setAncestorClass(self::class) 65 65 ->setUniqueMethod('getMenuItemKey') 66 66 ->execute(); 67 67 }
+1 -1
src/applications/search/relationship/PhabricatorObjectRelationship.php
··· 93 93 94 94 final public static function getAllRelationships() { 95 95 return id(new PhutilClassMapQuery()) 96 - ->setAncestorClass(__CLASS__) 96 + ->setAncestorClass(self::class) 97 97 ->setUniqueMethod('getRelationshipConstant') 98 98 ->execute(); 99 99 }
+1 -1
src/applications/search/worker/PhabricatorRebuildIndexesWorker.php
··· 4 4 5 5 public static function rebuildObjectsWithQuery($query_class) { 6 6 parent::scheduleTask( 7 - __CLASS__, 7 + self::class, 8 8 array( 9 9 'queryClass' => $query_class, 10 10 ),
+1 -1
src/applications/search/worker/PhabricatorSearchWorker.php
··· 12 12 } 13 13 14 14 parent::scheduleTask( 15 - __CLASS__, 15 + self::class, 16 16 array( 17 17 'documentPHID' => $phid, 18 18 'parameters' => $parameters,
+1 -1
src/applications/settings/panel/PhabricatorSettingsPanel.php
··· 87 87 88 88 final public static function getAllPanels() { 89 89 $panels = id(new PhutilClassMapQuery()) 90 - ->setAncestorClass(__CLASS__) 90 + ->setAncestorClass(self::class) 91 91 ->setUniqueMethod('getPanelKey') 92 92 ->execute(); 93 93 return msortv($panels, 'getPanelOrderVector');
+1 -1
src/applications/settings/panelgroup/PhabricatorSettingsPanelGroup.php
··· 22 22 23 23 final public static function getAllPanelGroups() { 24 24 $groups = id(new PhutilClassMapQuery()) 25 - ->setAncestorClass(__CLASS__) 25 + ->setAncestorClass(self::class) 26 26 ->setUniqueMethod('getPanelGroupKey') 27 27 ->execute(); 28 28
+1 -1
src/applications/settings/setting/PhabricatorSetting.php
··· 50 50 51 51 public static function getAllSettings() { 52 52 return id(new PhutilClassMapQuery()) 53 - ->setAncestorClass(__CLASS__) 53 + ->setAncestorClass(self::class) 54 54 ->setUniqueMethod('getSettingKey') 55 55 ->execute(); 56 56 }
+1 -1
src/applications/system/codex/PhabricatorDestructibleCodex.php
··· 53 53 get_class($object), 54 54 'PhabricatorDestructibleCodexInterface', 55 55 'newDestructibleCodex()', 56 - __CLASS__)); 56 + self::class)); 57 57 } 58 58 59 59 $codex
+1 -1
src/applications/system/engine/PhabricatorBeforeDestructionEngineExtension.php
··· 75 75 final public static function getAllExtensions(): array { 76 76 $map = new PhutilClassMapQuery(); 77 77 return $map 78 - ->setAncestorClass(__CLASS__) 78 + ->setAncestorClass(self::class) 79 79 ->setUniqueMethod('getExtensionKey') 80 80 ->execute(); 81 81 }
+1 -1
src/applications/system/engine/PhabricatorCacheEngineExtension.php
··· 22 22 23 23 final public static function getAllExtensions() { 24 24 return id(new PhutilClassMapQuery()) 25 - ->setAncestorClass(__CLASS__) 25 + ->setAncestorClass(self::class) 26 26 ->setUniqueMethod('getExtensionKey') 27 27 ->execute(); 28 28 }
+1 -1
src/applications/system/engine/PhabricatorDestructionEngineExtension.php
··· 28 28 29 29 final public static function getAllExtensions() { 30 30 return id(new PhutilClassMapQuery()) 31 - ->setAncestorClass(__CLASS__) 31 + ->setAncestorClass(self::class) 32 32 ->setUniqueMethod('getExtensionKey') 33 33 ->execute(); 34 34 }
+1 -1
src/applications/transactions/editengine/PhabricatorEditEngine.php
··· 2369 2369 2370 2370 final public static function getAllEditEngines() { 2371 2371 return id(new PhutilClassMapQuery()) 2372 - ->setAncestorClass(__CLASS__) 2372 + ->setAncestorClass(self::class) 2373 2373 ->setUniqueMethod('getEngineKey') 2374 2374 ->execute(); 2375 2375 }
+1 -1
src/applications/transactions/engineextension/PhabricatorEditEngineExtension.php
··· 38 38 39 39 final public static function getAllExtensions() { 40 40 return id(new PhutilClassMapQuery()) 41 - ->setAncestorClass(__CLASS__) 41 + ->setAncestorClass(self::class) 42 42 ->setUniqueMethod('getExtensionKey') 43 43 ->setSortMethod('getExtensionPriority') 44 44 ->execute();
+1 -1
src/applications/transactions/engineextension/PhabricatorEditorExtension.php
··· 38 38 39 39 final public static function getAllExtensions() { 40 40 return id(new PhutilClassMapQuery()) 41 - ->setAncestorClass(__CLASS__) 41 + ->setAncestorClass(self::class) 42 42 ->setUniqueMethod('getExtensionKey') 43 43 ->execute(); 44 44 }
+1 -1
src/applications/transactions/query/PhabricatorApplicationTransactionQuery.php
··· 23 23 $target_class = get_class($xaction); 24 24 25 25 $queries = id(new PhutilClassMapQuery()) 26 - ->setAncestorClass(__CLASS__) 26 + ->setAncestorClass(self::class) 27 27 ->execute(); 28 28 foreach ($queries as $query) { 29 29 $query_xaction = $query->getTemplateApplicationTransaction();
+1 -1
src/applications/transactions/storage/PhabricatorApplicationTransaction.php
··· 1675 1675 } 1676 1676 1677 1677 public function attachTransactionGroup(array $group) { 1678 - assert_instances_of($group, __CLASS__); 1678 + assert_instances_of($group, self::class); 1679 1679 $this->transactionGroup = $group; 1680 1680 return $this; 1681 1681 }
+1 -1
src/infrastructure/contentsource/PhabricatorContentSource.php
··· 14 14 15 15 final public static function getAllContentSources() { 16 16 return id(new PhutilClassMapQuery()) 17 - ->setAncestorClass(__CLASS__) 17 + ->setAncestorClass(self::class) 18 18 ->setUniqueMethod('getSourceTypeConstant') 19 19 ->execute(); 20 20 }
+1 -1
src/infrastructure/customfield/field/PhabricatorCustomField.php
··· 1651 1651 PhabricatorCustomFieldInterface $object, 1652 1652 $role, 1653 1653 array $fields) { 1654 - assert_instances_of($fields, __CLASS__); 1654 + assert_instances_of($fields, self::class); 1655 1655 1656 1656 // We only apply subtype adjustment for some roles. For example, when 1657 1657 // writing Herald rules or building a Search interface, we always want to
+1 -1
src/infrastructure/customfield/standard/PhabricatorStandardCustomField.php
··· 28 28 $builtin = false) { 29 29 30 30 $types = id(new PhutilClassMapQuery()) 31 - ->setAncestorClass(__CLASS__) 31 + ->setAncestorClass(self::class) 32 32 ->setUniqueMethod('getFieldType') 33 33 ->execute(); 34 34
+1 -1
src/infrastructure/daemon/PhutilDaemon.php
··· 85 85 if (!$router->getHandler($handler_key)) { 86 86 $handler = new PhutilCallbackSignalHandler( 87 87 SIGTERM, 88 - __CLASS__.'::onTermSignal'); 88 + self::class.'::onTermSignal'); 89 89 $router->installHandler($handler_key, $handler); 90 90 } 91 91
+1 -1
src/infrastructure/daemon/PhutilDaemonOverseerModule.php
··· 32 32 33 33 public static function getAllModules() { 34 34 return id(new PhutilClassMapQuery()) 35 - ->setAncestorClass(__CLASS__) 35 + ->setAncestorClass(self::class) 36 36 ->execute(); 37 37 } 38 38
+1 -1
src/infrastructure/daemon/garbagecollector/PhabricatorGarbageCollector.php
··· 169 169 */ 170 170 final public static function getAllCollectors() { 171 171 return id(new PhutilClassMapQuery()) 172 - ->setAncestorClass(__CLASS__) 172 + ->setAncestorClass(self::class) 173 173 ->setUniqueMethod('getCollectorConstant') 174 174 ->execute(); 175 175 }
+1 -1
src/infrastructure/daemon/workers/bulk/PhabricatorWorkerBulkJobType.php
··· 20 20 21 21 final public static function getAllJobTypes() { 22 22 return id(new PhutilClassMapQuery()) 23 - ->setAncestorClass(__CLASS__) 23 + ->setAncestorClass(self::class) 24 24 ->setUniqueMethod('getBulkJobTypeKey') 25 25 ->execute(); 26 26 }
+2 -2
src/infrastructure/edges/type/PhabricatorEdgeType.php
··· 19 19 pht( 20 20 '%s class "%s" has an invalid %s property. '. 21 21 'Edge constants must be positive integers.', 22 - __CLASS__, 22 + self::class, 23 23 get_class($this), 24 24 'EDGECONST')); 25 25 } ··· 159 159 160 160 if ($type_map === null) { 161 161 $types = id(new PhutilClassMapQuery()) 162 - ->setAncestorClass(__CLASS__) 162 + ->setAncestorClass(self::class) 163 163 ->setUniqueMethod('getEdgeConstant') 164 164 ->execute(); 165 165
+1 -1
src/infrastructure/env/PhabricatorConfigStackSource.php
··· 19 19 20 20 public function popSource() { 21 21 if (empty($this->stack)) { 22 - throw new Exception(pht('Popping an empty %s!', __CLASS__)); 22 + throw new Exception(pht('Popping an empty %s!', self::class)); 23 23 } 24 24 return array_shift($this->stack); 25 25 }
+1 -1
src/infrastructure/events/PhabricatorExampleEventListener.php
··· 24 24 "%s\n", 25 25 pht( 26 26 '%s got test event at %d', 27 - __CLASS__, 27 + self::class, 28 28 $event->getValue('time'))); 29 29 } 30 30
+1 -1
src/infrastructure/export/engine/PhabricatorExportEngineExtension.php
··· 23 23 24 24 final public static function getAllExtensions() { 25 25 return id(new PhutilClassMapQuery()) 26 - ->setAncestorClass(__CLASS__) 26 + ->setAncestorClass(self::class) 27 27 ->setUniqueMethod('getExtensionKey') 28 28 ->execute(); 29 29 }
+1 -1
src/infrastructure/export/format/PhabricatorExportFormat.php
··· 45 45 46 46 final public static function getAllExportFormats() { 47 47 return id(new PhutilClassMapQuery()) 48 - ->setAncestorClass(__CLASS__) 48 + ->setAncestorClass(self::class) 49 49 ->setUniqueMethod('getExportFormatKey') 50 50 ->execute(); 51 51 }
+1 -1
src/infrastructure/markup/markuprule/PhutilRemarkupHyperlinkEngineExtension.php
··· 11 11 12 12 final public static function getAllLinkEngines() { 13 13 return id(new PhutilClassMapQuery()) 14 - ->setAncestorClass(__CLASS__) 14 + ->setAncestorClass(self::class) 15 15 ->setUniqueMethod('getHyperlinkEngineKey') 16 16 ->execute(); 17 17 }
+1 -1
src/infrastructure/storage/connection/mysql/AphrontMySQLiDatabaseConnection.php
··· 250 250 } 251 251 252 252 public static function resolveAsyncQueries(array $conns, array $asyncs) { 253 - assert_instances_of($conns, __CLASS__); 253 + assert_instances_of($conns, self::class); 254 254 assert_instances_of($asyncs, 'mysqli'); 255 255 256 256 $read = $error = $reject = array();
+6 -6
src/infrastructure/storage/patch/PhabricatorSQLPatchList.php
··· 48 48 49 49 final public static function buildAllPatches() { 50 50 $patch_lists = id(new PhutilClassMapQuery()) 51 - ->setAncestorClass(__CLASS__) 51 + ->setAncestorClass(self::class) 52 52 ->setUniqueMethod('getNamespace') 53 53 ->execute(); 54 54 ··· 70 70 throw new Exception( 71 71 pht( 72 72 "%s '%s' has a patch '%s' which is not an array.", 73 - __CLASS__, 73 + self::class, 74 74 get_class($patch_list), 75 75 $key)); 76 76 } ··· 90 90 pht( 91 91 "%s '%s' has a patch, '%s', with an unknown property, '%s'.". 92 92 "Patches must have only valid keys: %s.", 93 - __CLASS__, 93 + self::class, 94 94 get_class($patch_list), 95 95 $key, 96 96 $pkey, ··· 103 103 pht( 104 104 "%s '%s' has a patch with a numeric key, '%s'. ". 105 105 "Patches must use string keys.", 106 - __CLASS__, 106 + self::class, 107 107 get_class($patch_list), 108 108 $key)); 109 109 } ··· 113 113 pht( 114 114 "%s '%s' has a patch with a colon in the key name, '%s'. ". 115 115 "Patch keys may not contain colons.", 116 - __CLASS__, 116 + self::class, 117 117 get_class($patch_list), 118 118 $key)); 119 119 } ··· 126 126 pht( 127 127 "%s '%s' has a patch '%s' which duplicates an ". 128 128 "existing patch key.", 129 - __CLASS__, 129 + self::class, 130 130 get_class($patch_list), 131 131 $key)); 132 132 }
+1 -1
src/infrastructure/syntax/PhabricatorSyntaxStyle.php
··· 21 21 22 22 public static function getAllStyles() { 23 23 return id(new PhutilClassMapQuery()) 24 - ->setAncestorClass(__CLASS__) 24 + ->setAncestorClass(self::class) 25 25 ->setUniqueMethod('getSyntaxStyleKey') 26 26 ->setSortMethod('getStyleName') 27 27 ->execute();
+1 -1
src/infrastructure/util/password/PhabricatorPasswordHasher.php
··· 213 213 */ 214 214 public static function getAllHashers() { 215 215 $objects = id(new PhutilClassMapQuery()) 216 - ->setAncestorClass(__CLASS__) 216 + ->setAncestorClass(self::class) 217 217 ->setUniqueMethod('getHashName') 218 218 ->execute(); 219 219
+1 -1
src/view/AphrontDialogView.php
··· 322 322 pht( 323 323 'You must call %s when rendering an %s.', 324 324 'setViewer()', 325 - __CLASS__)); 325 + self::class)); 326 326 } 327 327 328 328 $classes = array();
+1 -1
src/view/extension/PHUICurtainExtension.php
··· 36 36 37 37 final public static function getAllExtensions() { 38 38 return id(new PhutilClassMapQuery()) 39 - ->setAncestorClass(__CLASS__) 39 + ->setAncestorClass(self::class) 40 40 ->setUniqueMethod('getExtensionKey') 41 41 ->execute(); 42 42 }
+1 -1
src/view/form/AphrontFormView.php
··· 138 138 throw new Exception( 139 139 pht( 140 140 'You must pass the user to %s.', 141 - __CLASS__)); 141 + self::class)); 142 142 } 143 143 144 144 $sigils = $this->sigils;
+1 -1
src/view/page/PhabricatorStandardPageView.php
··· 221 221 pht( 222 222 'You must set the %s to render a %s.', 223 223 'Request', 224 - __CLASS__)); 224 + self::class)); 225 225 } 226 226 227 227 $console = $this->getConsole();
+1 -1
src/view/page/menu/PhabricatorMainMenuBarExtension.php
··· 86 86 87 87 final public static function getAllExtensions() { 88 88 return id(new PhutilClassMapQuery()) 89 - ->setAncestorClass(__CLASS__) 89 + ->setAncestorClass(self::class) 90 90 ->setUniqueMethod('getExtensionKey') 91 91 ->setSortMethod('getExtensionOrder') 92 92 ->execute();
+2 -2
support/startup/PhabricatorStartup.php
··· 128 128 // NOTE: This protects us against multiple calls to didStartup() in the 129 129 // same request, but also against repeated requests to the same 130 130 // interpreter state, which we may implement in the future. 131 - register_shutdown_function(array(__CLASS__, 'didShutdown')); 131 + register_shutdown_function(array(self::class, 'didShutdown')); 132 132 $registered = true; 133 133 } 134 134 ··· 264 264 static $initialized = false; 265 265 if (!$initialized) { 266 266 declare(ticks=1); 267 - register_tick_function(array(__CLASS__, 'onDebugTick')); 267 + register_tick_function(array(self::class, 'onDebugTick')); 268 268 $initialized = true; 269 269 } 270 270 }