downloadexception.cs

来自「飞信的收发使用csharp进行开发」· CS 代码 · 共 57 行

CS
57
字号
namespace Imps.Client.Pc
{
    using System;
    using System.Runtime.Serialization;

    [Serializable]
    public class DownloadException : ApplicationException
    {
        private int _statusCode;

        public DownloadException()
        {
            this._statusCode = 200;
        }

        public DownloadException(string message) : base(message)
        {
            this._statusCode = 200;
        }

        protected DownloadException(SerializationInfo info, StreamingContext context) : base(info, context)
        {
            this._statusCode = 200;
        }

        public DownloadException(string message, Exception inner) : base(message, inner)
        {
            this._statusCode = 200;
        }

        public DownloadException(string message, int statusCode) : base(message)
        {
            this._statusCode = 200;
            this.StatusCode = statusCode;
        }

        public DownloadException(string message, int statusCode, Exception inner) : base(message, inner)
        {
            this._statusCode = 200;
            this.StatusCode = statusCode;
        }

        public int StatusCode
        {
            get
            {
                return this._statusCode;
            }
            private set
            {
                this._statusCode = value;
            }
        }
    }
}

⌨️ 快捷键说明

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