Mercurial > hg > cmmr2012-drupal-site
annotate vendor/consolidation/annotated-command/src/Hooks/StatusDeterminerInterface.php @ 5:12f9dff5fda9 tip
Update to Drupal core 8.7.1
author | Chris Cannam |
---|---|
date | Thu, 09 May 2019 15:34:47 +0100 |
parents | a9cd425dd02b |
children |
rev | line source |
---|---|
Chris@0 | 1 <?php |
Chris@0 | 2 namespace Consolidation\AnnotatedCommand\Hooks; |
Chris@0 | 3 |
Chris@0 | 4 /** |
Chris@0 | 5 * A StatusDeterminer maps from a result to a status exit code. |
Chris@0 | 6 * |
Chris@4 | 7 * @deprecated. Instead of using a Status Determiner hook, commands |
Chris@4 | 8 * should simply return their exit code and result data separately |
Chris@4 | 9 * using a CommandResult object. |
Chris@4 | 10 * |
Chris@0 | 11 * @see HookManager::addStatusDeterminer() |
Chris@0 | 12 */ |
Chris@0 | 13 interface StatusDeterminerInterface |
Chris@0 | 14 { |
Chris@0 | 15 /** |
Chris@0 | 16 * Convert a result object into a status code, if |
Chris@0 | 17 * possible. Return null if the result object is unknown. |
Chris@0 | 18 * |
Chris@0 | 19 * @return null|integer |
Chris@0 | 20 */ |
Chris@0 | 21 public function determineStatusCode($result); |
Chris@0 | 22 } |