56 abstract protected function command();
64 final protected function login() {
65 if (!$this->getDefinition()->hasOption(
'as')) {
101 if (!$this->getDefinition()->hasOption(
'language')) {
elgg_is_logged_in()
Returns whether or not the user is currently logged in.
execute(InputInterface $input, OutputInterface $output)
{}
Exception thrown if an error which can only be found on runtime occurs.
Adds interaction to a console command.
login()
Login a user defined by –as option.
error($message)
Print an error.
elgg_logout()
Log the current user out.
elgg_echo($message_key, array $args=[], $language="")
Elgg language module Functions to manage language and translations.
get_user_by_username($username)
Get user by username.
dumpRegisters()
Dump and output system and error messages.
elgg_log($message, $level=\Psr\Log\LogLevel::NOTICE)
Log a message.
Abstract command with some utility methods.
elgg_login(\ElggUser $user, bool $persistent=false)
Log in a user.
_elgg_services()
Get the global service provider.
command()
Command to be executed.
option($name)
Returns option value.
setLanguage()
Set the language for this cli command.