集体更换异常类所在命名空间,因为异常经常用到,所以应该让它享受更高层次的命名空间
Stone authored at 2014-12-03 16:04:24
1.40 KiB
X
using System;
using System.Runtime.Serialization;

namespace NewLife.CommonEntity.Exceptions
{
    /// <summary>实体异常</summary>
    public class EntityException : XException
    {
          #region 构造
        /// <summary>初始化</summary>
        public EntityException() { }

        /// <summary>初始化</summary>
        /// <param name="message"></param>
        public EntityException(String message) : base(message) { }

        /// <summary>初始化</summary>
        /// <param name="format"></param>
        /// <param name="args"></param>
        public EntityException(String format, params Object[] args) : base(format, args) { }

        /// <summary>初始化</summary>
        /// <param name="message"></param>
        /// <param name="innerException"></param>
        public EntityException(String message, Exception innerException) : base(message, innerException) { }

        /// <summary>初始化</summary>
        /// <param name="innerException"></param>
        public EntityException(Exception innerException) : base((innerException != null ? innerException.Message : null), innerException) { }

        /// <summary>初始化</summary>
        /// <param name="info"></param>
        /// <param name="context"></param>
        protected EntityException(SerializationInfo info, StreamingContext context) : base(info, context) { }
        #endregion
  }
}