class delete extends command

Properties

protected user $user from  command
protected config $config
protected driver_interface $db
protected string $phpbb_root_path

phpBB root path

Methods

__construct(config $config, user $user, driver_interface $db, string $phpbb_root_path)

Constructor

ProgressBar
create_progress_bar(int $max, SymfonyStyle $io, OutputInterface $output, bool $message = false)

Create a styled progress bar

from  command
null
configure()

Sets the command name and description

int
execute(InputInterface $input, OutputInterface $output)

Executes the command thumbnail:delete.

commit_changes(array $thumbnail_deleted)

Commits the changes to the database

Details

at line 45
__construct(config $config, user $user, driver_interface $db, string $phpbb_root_path)

Constructor

Parameters

config $config

The config

user $user

User instance (mostly for translation)

driver_interface $db

Database connection

string $phpbb_root_path

Root path

in command at line 45
ProgressBar create_progress_bar(int $max, SymfonyStyle $io, OutputInterface $output, bool $message = false)

Create a styled progress bar

Parameters

int $max

Max value for the progress bar

SymfonyStyle $io

Symfony style output decorator

OutputInterface $output

The output stream, used to print messages

bool $message

Should we display message output under the progress bar?

Return Value

ProgressBar

at line 59
protected null configure()

Sets the command name and description

Return Value

null

at line 77
protected int execute(InputInterface $input, OutputInterface $output)

Executes the command thumbnail:delete.

Deletes all existing thumbnails and updates the database accordingly.

Parameters

InputInterface $input

The input stream used to get the argument and verbose option.

OutputInterface $output

The output stream, used for printing verbose-mode and error information.

Return Value

int

0 if all is ok, 1 if a thumbnail couldn't be deleted.

at line 153
protected commit_changes(array $thumbnail_deleted)

Commits the changes to the database

Parameters

array $thumbnail_deleted