Exemple #1
0
        public LoggedException(string message, ExType level, Exception ex) : base(message, ex)
        {
            _log = new AppLogger();
            _ex  = ex;
            switch (level)
            {
            case ExType.Error:
                _log.LogError("MESSAGE: " + ex.Message + "\n *-*-*-*-*- \nSTACK TRACE: " + ex.StackTrace);
                break;

            case ExType.Fatal:
                _log.LogFatal("MESSAGE: " + ex.Message + "\n *-*-*-*-*- \nSTACK TRACE: " + ex.StackTrace);
                break;
            }
        }