Ejemplo n.º 1
0
        public void Init()
        {
#if NETCOREAPP3_1_OR_GREATER
            //初始化配置文件
            Assembly      entryAssembly = Assembly.GetExecutingAssembly();
            Configuration configuration = ConfigurationExtension.GetConfigurationFromAssembly(entryAssembly);
            AopSection.Initialize(configuration);
#endif
        }
Ejemplo n.º 2
0
        public void Initialize()
        {
#if NETCOREAPP3_1_OR_GREATER
            //初始化配置文件
            Assembly      entryAssembly = Assembly.GetExecutingAssembly();
            Configuration configuration = ConfigurationExtension.GetConfigurationFromAssembly(entryAssembly);
            AopSection.Initialize(configuration);
#endif
            string baseDirectory = AppDomain.CurrentDomain.BaseDirectory;
            AppDomain.CurrentDomain.SetData("DataDirectory", baseDirectory);
        }