Back to SessionGcCommand class

Method configure

protected void
configure
()
Configure the command.
Returns
  • void
Since
  • 4.0.0

Method configure - Source code

/**
 * Configure the command.
 *
 * @return  void
 *
 * @since   4.0.0
 */
protected function configure() : void
{
    $help = "<info>%command.name%</info> runs PHP's garbage collection operation for session data\n\t\t\nUsage: <info>php %command.full_name%</info>\n\t\t\nThis command defaults to performing garbage collection for the frontend (site) application.\n\t\t\nTo run garbage collection for another application, you can specify it with the <info>--application</info> option.\n\t\t\nUsage: <info>php %command.full_name% --application=[APPLICATION]</info>";
    $this->setDescription('Perform session garbage collection');
    $this->addOption('application', 'app', InputOption::VALUE_OPTIONAL, 'The application to perform garbage collection for.', 'site');
    $this->setHelp($help);
}