public LoggingAspectTransformation(LoggingAspectWeaver aspectWeaver, ILoggingBackend backend)
            : base(aspectWeaver)
        {
            this.backend = backend;

            this.assets = aspectWeaver.Module.Cache.GetItem(() => new Assets(aspectWeaver.Module));
        }
        public LoggingAspectTransformation(LoggingAspectWeaver aspectWeaver, ILoggingBackend backend)
            : base(aspectWeaver)
        {
            this.backend = backend;

            this.assets = aspectWeaver.Module.Cache.GetItem(() => new Assets(aspectWeaver.Module));
        }
Пример #3
0
        private ILoggingBackend GetBackend(string loggingBackendName)
        {
            foreach (ILoggingBackendProvider provider in this.Project.GetServices <ILoggingBackendProvider>())
            {
                ILoggingBackend backend = provider.GetBackend(loggingBackendName);
                if (backend != null)
                {
                    return(backend);
                }
            }

            return(null);
        }
Пример #4
0
        private void InitializeBackend()
        {
            string loggingBackendName = this.Project.Evaluate("{$LoggingBackend}", true);

            if (loggingBackendName == null)
            {
                return;
            }

            this.backend = this.GetBackend(loggingBackendName);

            if (this.backend == null)
            {
                InstrumentationMessageSource.Instance.Write(MessageLocation.Unknown, SeverityType.Fatal, "DIA0001",
                                                            loggingBackendName);
                return;
            }

            this.backend.Initialize(this.Project.Module);
        }
        private void InitializeBackend()
        {
            string loggingBackendName = this.Project.Evaluate("{$LoggingBackend}", true);

            if (loggingBackendName == null)
            {
                return;
            }

            this.backend = this.GetBackend(loggingBackendName);

            if (this.backend == null)
            {
                InstrumentationMessageSource.Instance.Write(MessageLocation.Unknown, SeverityType.Fatal, "IN0001",
                                                            loggingBackendName);
                return;
            }

            this.backend.Initialize(this.Project.Module);
        }
 public LoggingAspectTransformation(LoggingAspectWeaver aspectWeaver, ILoggingBackend backend)
     : base(aspectWeaver)
 {
     this.backend = backend;
 }
 public LoggingAspectTransformation(LoggingAspectWeaver aspectWeaver, ILoggingBackend backend)
     : base(aspectWeaver)
 {
     this.backend = backend;
 }