Busker.Data.Commands.Invoker.ExecuteCommand C# (CSharp) Метод

ExecuteCommand() публичный Метод

public ExecuteCommand ( ) : void
Результат void
            public virtual void ExecuteCommand()
            {
                if (command == null)
                    throw new Exception("You forgot to set the command!!");
    
                try
                {
                    log(this.command.GetType().Name + " starting execution ");
                    command.Execute();
                    if (!command.Success)
                    {
                        log(this.command.GetType().Name + " completed execution but failed. Message: " + command.Message + " " + command.StatusCode.ToString());
                    }
                    else
                        log(this.command.GetType().Name + " completed execution. Success!");
    
                }
                catch (Exception ex)
                {
                    command.StatusCode = CommandStatusCode.Error;
                    Loggy.AddError("An unhandled error was caught in " + this.command.GetType().Name + ": " + ex.Message, ex);
                    command.Message = ex.ToString();
                    //throw;
                }
            }