Esempio n. 1
0
        public void Initialize()
        {
            int cleanerror = 0;

            if (_server)
            {
                if (true)
                {
                    Log.Debug("CleanManager", sLConsole.GetString("CleanConfig is starting..."));
                    var config = new CleanConfig();
                    if (!config.IsClean())
                    {
                        cleanerror++;
                    }
                }
            }
            else
            {
                if (true)
                {
                    Log.Debug("CleanManager", sLConsole.GetString("CleanConfig is starting..."));
                    var config = new CleanConfig();
                    if (!config.IsClean())
                    {
                        cleanerror++;
                    }
                }

                if (true)
                {
                    Log.Debug("CleanManager", sLConsole.GetString("CleanDatabase is starting..."));
                    CDatabase = new CleanDatabase();
                    if (!CDatabase.IsClean())
                    {
                        cleanerror++;
                    }
                }
            }

            if (cleanerror > 0)
            {
                Log.Warning("CleanManager", sLConsole.GetString("Some problems occured during cleanup in some place!"));
            }

            if ((Schumix.Framework.Config.CleanConfig.Config || Schumix.Framework.Config.CleanConfig.Database) && cleanerror == 0)
            {
                Log.Notice("CleanManager", sLConsole.GetString("Cleanups have been finished."));
            }
            else if (cleanerror == 0)
            {
                Log.Warning("CleanManager", sLConsole.GetString("Cleanup is not turned on!"));
            }
        }
Esempio n. 2
0
        public void Initialize()
        {
            int cleanerror = 0;

            if(_server)
            {
                if(true)
                {
                    Log.Debug("CleanManager", sLConsole.GetString("CleanConfig is starting..."));
                    var config = new CleanConfig();
                    if(!config.IsClean())
                        cleanerror++;
                }
            }
            else
            {
                if(true)
                {
                    Log.Debug("CleanManager", sLConsole.GetString("CleanConfig is starting..."));
                    var config = new CleanConfig();
                    if(!config.IsClean())
                        cleanerror++;
                }

                if(true)
                {
                    Log.Debug("CleanManager", sLConsole.GetString("CleanDatabase is starting..."));
                    CDatabase = new CleanDatabase();
                    if(!CDatabase.IsClean())
                        cleanerror++;
                }
            }

            if(cleanerror > 0)
                Log.Warning("CleanManager", sLConsole.GetString("Some problems occured during cleanup in some place!"));

            if((Schumix.Framework.Config.CleanConfig.Config || Schumix.Framework.Config.CleanConfig.Database) && cleanerror == 0)
                Log.Notice("CleanManager", sLConsole.GetString("Cleanups have been finished."));
            else if(cleanerror == 0)
                Log.Warning("CleanManager", sLConsole.GetString("Cleanup is not turned on!"));
        }