Exemple #1
0
 public bool TryGetExceptionCode(Type type, out ExceptonCodeModel model)
 {
     if (exceptionCodes == null)
     {
         model = null;
         return(false);
     }
     return(exceptionCodes.TryGetValue(type, out model));
 }
        public void RegisterCode <T>(int errCode, bool logFullException = false, bool logPostData = false) where T : Exception
        {
            var model = new ExceptonCodeModel()
            {
                Code             = errCode,
                LogFullException = logFullException,
                LogPostData      = logPostData
            };
            var t = new Tuple <Type, ExceptonCodeModel>(typeof(T), model);

            codeList.Add(t);
        }