class DatabaseUpdateStatus in Automatic Updates 8
Database update status command.
Hierarchy
- class \Drupal\automatic_updates\Command\BaseCommand extends \Symfony\Component\Console\Command\Command
- class \Drupal\automatic_updates\Command\DatabaseUpdateStatus
Expanded class hierarchy of DatabaseUpdateStatus
File
- src/
Command/ DatabaseUpdateStatus.php, line 11
Namespace
Drupal\automatic_updates\CommandView source
class DatabaseUpdateStatus extends BaseCommand {
/**
* {@inheritdoc}
*/
protected function configure() {
parent::configure();
$this
->setName('updatedb-status')
->setDescription('List any pending database updates.')
->setAliases([
'updbst',
'updatedb:status',
]);
}
/**
* {@inheritdoc}
*/
protected function execute(InputInterface $input, OutputInterface $output) {
parent::execute($input, $output);
$pending_updates = \Drupal::service('automatic_updates.pending_db_updates')
->run();
$output
->writeln($pending_updates);
return 0;
}
}
Members
Name | Modifiers | Type | Description | Overrides |
---|---|---|---|---|
BaseCommand:: |
protected | property | The class loader. | |
BaseCommand:: |
protected | function | Bootstrap Drupal. | |
BaseCommand:: |
public | function | Constructs a new InstallCommand command. | |
DatabaseUpdateStatus:: |
protected | function |
Configures the current command. Overrides BaseCommand:: |
|
DatabaseUpdateStatus:: |
protected | function |
Executes the current command. Overrides BaseCommand:: |