cfileexception.cs

来自「KTDictSeg 简介: KTDictSeg 是由KaiToo搜索开发的一款基」· CS 代码 · 共 59 行

CS
59
字号
using System;
using System.Collections.Generic;
using System.Text;
using System.Diagnostics;

namespace FTAlgorithm.General
{
    /// <summary>
    /// 文件操作异常
    /// </summary>
    public class CFileException : CException
    {
        /// <summary>
        /// 设置异常类型
        /// </summary>
        protected override void SetExceptionType()
        {
            m_Type = ExceptionType.FileException;
        }

        /// <summary>
        /// 构造函数
        /// </summary>
        /// <param name="Code">异常代码</param>
        /// <param name="strMessage">异常消息</param>
        /// <param name="strReason">异常原因</param>
        public CFileException(ExceptionCode Code, String strMessage, String strReason)
            : base(Code, strMessage, strReason)
        {
            Debug.Assert((int)Code >= 1100 && (int)Code < 1200);
        }

        /// <summary>
        /// 构造函数
        /// </summary>
        /// <param name="Code">异常代码</param>
        /// <param name="strMessage">异常消息</param>
        /// <param name="e">从这个异常引入的异常</param>
        /// <example>
        /// try
        /// {
        /// ......
        /// 
        /// }
        /// catch (Exception e)
        /// {
        ///     CDbException E = new CDbException ("Example Exception", e);
        ///     E.Raise();
        /// }
        /// </example>
        public CFileException(ExceptionCode Code, String strMessage, Exception e)
            : base(Code, strMessage,e)
        {
            Debug.Assert((int)Code >= 1100 && (int)Code < 1200);
        }
 
    }
}

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?