Example #1
0
 /// <summary>自定义异常体系,若需要定义系统的已知未知异常等请调用此方法进行定义
 /// </summary>
 /// <param name="exceptionSystem">异常体系的实例</param>
 /// <returns></returns>
 public new SystemConfigWithCastle ExceptionSystem(IExceptionSystem exceptionSystem)
 {
     (DependencyResolver.Resolver as WindsorResolver).Container
     .Register(Component
               .For <IExceptionSystem>()
               .Instance(exceptionSystem)
               .IsDefault());
     return(this);
 }
        protected SystemConfig(SystemConfig config)
            : this(config.AppName
                   , config.VersionFlag)
        {
            this._enableRefresh        = config._enableRefresh;
            this._isCommonConfigReaded = config._isCommonConfigReaded;
            this._justTestIdentity     = config._justTestIdentity;

            this._dict            = config._dict;
            this._exceptionSystem = config._exceptionSystem;
            this._cacheManager    = config._cacheManager;

            this.FoundationConfig = config.FoundationConfig;
        }
Example #3
0
 public ServiceInterceptor(ILoggerFactory fatory, IExceptionSystem es)
 {
     this._loggerFactory = fatory;
     this._exceptionSystem = es;
 }
Example #4
0
 //HACK:拦截器禁止随意增加构造器参数,影响面过广,可能会造成其他层次组件注入行为的差异
 public ServiceInterceptor(ILoggerFactory fatory, IExceptionSystem es)
 {
     this._loggerFactory   = fatory;
     this._exceptionSystem = es;
 }
 /// <summary>自定义异常体系,若需要定义系统的已知未知异常等请调用此方法进行定义
 /// </summary>
 /// <param name="exceptionSystem">异常体系的实例</param>
 /// <returns></returns>
 public SystemConfig ExceptionSystem(IExceptionSystem exceptionSystem)
 {
     this._exceptionSystem = exceptionSystem;
     return(this);
 }