自定义异常的设计

class ServiceException:Exception
    {
        private string message;
        public ServiceException() : base() { }
        public ServiceException(string msg) : base(msg) { this.message = msg; }
        public ServiceException(string msg, Exception InnerException) : base(msg, InnerException) { this.message = msg; }
    }

posted @ 2013-04-02 19:22  Predator  阅读(156)  评论(0编辑  收藏  举报