System.Reflection.Assembly.GetCallingAssembly()

Here are the examples of the csharp api System.Reflection.Assembly.GetCallingAssembly() taken from open source projects. By voting up you can indicate which examples are most useful and appropriate.

633 Examples 7

19 View Source File : AssemblyHelper.cs
License : MIT License
Project Creator : 17MKH

public string GetCurrentreplacedemblyName()
    {
        return replacedembly.GetCallingreplacedembly().GetName().Name;
    }

19 View Source File : DbBuilder.cs
License : MIT License
Project Creator : 17MKH

private void CreateDbContext()
    {
        var sp = Services.BuildServiceProvider();
        var dbLogger = new DbLogger(Options, sp.GetService<IDbLoggerProvider>());
        var accountResolver = sp.GetService<IAccountResolver>();

        //获取数据库适配器的程序集
        var dbAdapterreplacedemblyName = replacedembly.GetCallingreplacedembly().GetName().Name!.Replace("Core", "Adapter.") + Options.Provider;
        var dbAdapterreplacedembly = replacedemblyLoadContext.Default.LoadFromreplacedemblyName(new replacedemblyName(dbAdapterreplacedemblyName));

        //创建数据库上下文实例,通过反射设置属性
        DbContext = (IDbContext)Activator.CreateInstance(_dbContextType);
        _dbContextType.GetProperty("Options")?.SetValue(DbContext, Options);
        _dbContextType.GetProperty("Logger")?.SetValue(DbContext, dbLogger);
        _dbContextType.GetProperty("Adapter")?.SetValue(DbContext, CreateDbAdapter(dbAdapterreplacedemblyName, dbAdapterreplacedembly));
        _dbContextType.GetProperty("SchemaProvider")?.SetValue(DbContext, CreateSchemaProvider(dbAdapterreplacedemblyName, dbAdapterreplacedembly));
        _dbContextType.GetProperty("CodeFirstProvider")?.SetValue(DbContext, CreateCodeFirstProvider(dbAdapterreplacedemblyName, dbAdapterreplacedembly, Services));
        _dbContextType.GetProperty("AccountResolver")?.SetValue(DbContext, accountResolver);

        // ReSharper disable once replacedignNullToNotNullAttribute
        Services.AddSingleton(_dbContextType, DbContext);
    }

19 View Source File : Kernel.cs
License : MIT License
Project Creator : 99x

public void Initialize()
        {
            replacedembly asm;

            if (callingreplacedembly == null)
            {
                asm = replacedembly.GetEntryreplacedembly();
                if (asm == null)
                    asm = replacedembly.GetCallingreplacedembly();
            }
            else
            {
                asm = callingreplacedembly;
            }


            ResourceRepository.Initialize(asm);
        }

19 View Source File : AspDotNetRadiumPlugin.cs
License : MIT License
Project Creator : 99x

public void Handle(HttpContext context)
        {
            Kernel kernel = RadiumAspService.Kernel;
            if (kernel == null)
            {
                kernel = new Kernel(replacedembly.GetCallingreplacedembly());
                
                RadiumAspService.Kernel = kernel;
            }

            ServiceInvoker.Invoke(kernel, new Messaging.ASPRadiumContext(context));
        }

19 View Source File : RtmpServerBuilder.cs
License : MIT License
Project Creator : a1q123456

public RtmpServer Build()
        {
            _options = _options ?? new RtmpServerOptions();
            _options.Startup = _startup;
            var types = replacedembly.GetCallingreplacedembly().GetTypes();

            var registerInternalControllers = true;
            _websocketOptions._serverOptions = _options;
            foreach (var type in types)
            {
                var neverRegister = type.GetCustomAttribute<NeverRegisterAttribute>();
                if (neverRegister != null)
                {
                    continue;
                }

                if (typeof(NetStream).IsreplacedignableFrom(type) && !type.IsAbstract)
                {
                    _options.RegisterStream(type);
                }
                else if (typeof(RtmpController).IsreplacedignableFrom(type) && !type.IsAbstract)
                {
                    _options.RegisterController(type);
                }

                if (typeof(LivingController).IsreplacedignableFrom(type))
                {
                    registerInternalControllers = false;
                }
                if (_useWebSocket)
                {
                    if (typeof(WebSocketController).IsreplacedignableFrom(type) && !type.IsAbstract)
                    {
                        _websocketOptions.RegisterController(type);
                    }
                    if (typeof(WebSocketPlayController).IsreplacedignableFrom(type))
                    {
                        registerInternalControllers = false;
                    }
                }
            }

            if (registerInternalControllers)
            {
                _options.RegisterController<LivingController>();
                _options.RegisterStream<LivingStream>();
                _options.RegisterStream<RecordStream>();
                _options.RegisterController<RecordController>();
                if (_useWebSocket)
                {
                    _websocketOptions.RegisterController<WebSocketPlayController>();
                }
            }
           
            if (_useSsl)
            {
                _options.Cert = _cert;
            }
            _options.CleanupRpcRegistration();
            _options.BuildContainer();
            var ret = new RtmpServer(_options, _websocketOptions);
            return ret;
        }

19 View Source File : Resources.cs
License : MIT License
Project Creator : action-bi-toolkit

public static T GetEmbeddedResource<T>(string name, Func<Stream, T> transform, replacedembly replacedembly = null)
        {
            using (var stream = GetEmbeddedResourceStream(name, replacedembly ?? replacedembly.GetCallingreplacedembly()))
            {
                return transform(stream);
            }
        }

19 View Source File : Resources.cs
License : MIT License
Project Creator : action-bi-toolkit

public static string GetEmbeddedResourceString(string name, Encoding encoding = null, replacedembly replacedembly = null)
        {
            using (var stream = GetEmbeddedResourceStream(name, replacedembly ?? replacedembly.GetCallingreplacedembly()))
            using (var reader = new StreamReader(stream, encoding ?? Encoding.UTF8))
            {
                return reader.ReadToEnd();
            }
        }

19 View Source File : Resources.cs
License : MIT License
Project Creator : action-bi-toolkit

public static T GetEmbeddedResourceFromString<T>(string name, Func<string, T> transform, replacedembly replacedembly = null) =>
            GetEmbeddedResource<T>(name, stream =>
            {
                using (var reader = new StreamReader(stream, Encoding.UTF8))
                {
                    return transform(reader.ReadToEnd());
                }
            }, replacedembly ?? replacedembly.GetCallingreplacedembly());

19 View Source File : Resources.cs
License : MIT License
Project Creator : action-bi-toolkit

public static Stream GetEmbeddedResourceStream(string name, replacedembly replacedembly = null)
        {
            var asm = replacedembly ?? replacedembly.GetCallingreplacedembly();

            var resourceNames = asm.GetManifestResourceNames();
            var match = resourceNames.FirstOrDefault(n => n.EndsWith(name));
            if (match == null) throw new ArgumentException($"Embedded resource '{name}' not found.", nameof(name));

            return asm.GetManifestResourceStream(match);
        }

19 View Source File : VideoSource.cs
License : MIT License
Project Creator : adamfisher

public static VideoSource FromResource(string resource, replacedembly replacedembly = default(replacedembly))
        {
			if (string.IsNullOrEmpty (resource))
				return null;
			
			if (!Path.HasExtension (resource))
				throw new Exception ($"The specified resource '{resource}' must contain a valid file extension.");

            var foundResource = false;
			var format = Path.GetExtension (resource)?.Replace (".", string.Empty);
            replacedembly parameterreplacedembly = null, callingreplacedembly = null, entryreplacedembly = null;

            if (replacedembly != null)
            {
                parameterreplacedembly = replacedembly;
                foundResource = replacedembly.ContainsManifestResource(resource);
            }

            if (!foundResource)
            {
                replacedembly = replacedembly.GetCallingreplacedembly();
                callingreplacedembly = replacedembly;
                foundResource = replacedembly.ContainsManifestResource(resource);
            }

            if (!foundResource)
            {
                replacedembly = replacedembly.GetEntryreplacedembly();
                entryreplacedembly = replacedembly;
                foundResource = replacedembly.ContainsManifestResource(resource);
            }
            
            if (!foundResource)
            {
                var resourceNames = new List<string>();

                if (parameterreplacedembly != null)
                    resourceNames.AddRange(parameterreplacedembly.GetManifestResourceNames());
                if (callingreplacedembly != null)
                    resourceNames.AddRange(callingreplacedembly.GetManifestResourceNames());
                if (entryreplacedembly != null)
                    resourceNames.AddRange(entryreplacedembly.GetManifestResourceNames());

                Log.Error($"Unable to locate the embedded resource '{resource}'. " +
                          $"Possible candidates are: {Environment.NewLine}{string.Join(Environment.NewLine, resourceNames)}");

                return null;
            }

			return FromStream(() => replacedembly.GetEmbeddedResourceStream(resource), format);
        }

19 View Source File : AppShortcuts.android.cs
License : MIT License
Project Creator : adenearnshaw

public void Init()
        {
            _drawableClreplaced = replacedembly.GetCallingreplacedembly().GetTypes().FirstOrDefault(x => x.Name == "Drawable" || x.Name == "Resource_Drawable");
            (_customIconProvider as CustomIconProvider)?.Init(_drawableClreplaced);
        }

19 View Source File : MainWindow.xaml.cs
License : GNU General Public License v2.0
Project Creator : adrifcastr

private static void Extract(string nameSpace, string outDirectory, string internalFilePath, string resourceName)
        {
            replacedembly replacedembly = replacedembly.GetCallingreplacedembly();

            using (Stream s = replacedembly.GetManifestResourceStream(nameSpace + "." + (internalFilePath == "" ? "" : internalFilePath + ".") + resourceName))
            using (BinaryReader r = new BinaryReader(s))
            using (FileStream fs = new FileStream(outDirectory + "\\" + resourceName, FileMode.OpenOrCreate))
            using (BinaryWriter w = new BinaryWriter(fs))
                w.Write(r.ReadBytes((int)s.Length));
        }

19 View Source File : BlockMiningService.cs
License : MIT License
Project Creator : AElfProject

private static replacedembly OnreplacedemblyResolve(object sender, ResolveEventArgs args)
        {
            var folderPath = Path.GetDirectoryName(replacedembly.GetCallingreplacedembly().Location);
            var replacedemblyPath = Path.Combine(folderPath, new replacedemblyName(args.Name).Name + ".dll");
            if (!File.Exists(replacedemblyPath)) return null;
            var replacedembly = replacedembly.LoadFrom(replacedemblyPath);
            return replacedembly;
        }

19 View Source File : FileResourcePath.cs
License : GNU General Public License v2.0
Project Creator : afrantzis

public static string GetBinPath(params string[] dirs)
	{
		// Get replacedembly path
		string replacedemblyPath = replacedembly.GetCallingreplacedembly().Location;
		// Get replacedembly dir
		string replacedemblyDir = Path.GetDirectoryName(replacedemblyPath);

		string resourcePath = replacedemblyDir;

		foreach (string s in dirs)
			resourcePath = Path.Combine(resourcePath, s);

		return resourcePath;
	}

19 View Source File : Extends.cs
License : MIT License
Project Creator : AiursoftWeb

public static IServiceCollection AddAiursoftIdenreplacedy<TUser>(this IServiceCollection services,
            string archonEndpoint,
            string observerEndpoint,
            string probeEndpoint,
            string gateEndpoint) where TUser : AiurUserBase, new()
        {
            services.AddObserverServer(observerEndpoint); // For error reporting.
            services.AddArchonServer(archonEndpoint); // For token exchanging.
            services.AddProbeServer(probeEndpoint); // For file storaging.
            services.AddGatewayServer(gateEndpoint); // For authentication.
            services.AddAiursoftSDK(replacedembly.GetCallingreplacedembly(), abstracts: typeof(IAuthProvider));
            services.AddScoped<UserImageGenerator<TUser>>();
            services.AddScoped<AuthService<TUser>>();
            return services;
        }

19 View Source File : Extends.cs
License : MIT License
Project Creator : AiursoftWeb

public static IServiceCollection AddLibraryDependencies(this IServiceCollection services, params Type[] abstracts)
        {
            var calling = replacedembly.GetCallingreplacedembly();
            var executingTypes = new ClreplacedScanner().AllClreplacedUnder(calling, false, false);
            Register(executingTypes, services, abstracts);
            return services;
        }

19 View Source File : ServicesExtends.cs
License : MIT License
Project Creator : AiursoftWeb

public static IServiceCollection AddAiursoftSDK(this IServiceCollection services,
            replacedembly replacedembly = null,
            params Type[] abstracts)
        {
            services.AddHttpClient();
            services.AddMemoryCache();
            var abstractsArray = abstracts
                .AddWith(typeof(IHostedService))
                .AddWith(typeof(ISeeder))
                .ToArray();
            if (EntryExtends.IsProgramEntry())
            {
                // Program is starting itself.
                services.AddScannedDependencies(abstractsArray);
            }
            else if (replacedembly != null)
            {
                // Program is started in UT or EF. Method called from extension.
                services.AddreplacedemblyDependencies(replacedembly, abstractsArray);
            }
            else
            {
                // Program is started in UT or EF. Method called from web project.
                services.AddreplacedemblyDependencies(replacedembly.GetCallingreplacedembly(), abstractsArray);
            }
            return services;
        }

19 View Source File : Functions.cs
License : GNU General Public License v3.0
Project Creator : Albo1125

[Obfuscation(Exclude = false, Feature = "-ref proxy")]
        public static bool AddActionToButton(Action action, string buttonName)
        {
           
            Game.LogTrivial(replacedembly.GetCallingreplacedembly().GetName().Name + " requesting a PoliceSmartRadio action to be added to " + buttonName);
            //Game.LogTrivial("DoneLoading?" + DisplayHandler.DoneLoadingTextures);
            return DisplayHandler.AddActionToButton(action, null, replacedembly.GetCallingreplacedembly().GetName().Name, buttonName);
        }

19 View Source File : Functions.cs
License : GNU General Public License v3.0
Project Creator : Albo1125

public static void SetAutomaticVehicleDeatilsChecksEnabled(bool enabled)
        {
            Game.LogTrivial("Traffic Policer API: replacedembly " + replacedembly.GetCallingreplacedembly().GetName().Name + " setting automatic vehicle details checks to: " + enabled.ToString());
            VehicleDetails.AutomaticDetailsChecksEnabled = enabled;
        }

19 View Source File : Functions.cs
License : GNU General Public License v3.0
Project Creator : Albo1125

[Obfuscation(Exclude = false, Feature = "-ref proxy")]
        public static bool AddActionToButton(Action action, Func<bool> isAvailable, string buttonName)
        {
            Game.LogTrivial(replacedembly.GetCallingreplacedembly().GetName().Name + " requesting a PoliceSmartRadio action to be added to " + buttonName);
            //Game.LogTrivial("DoneLoading?" + DisplayHandler.DoneLoadingTextures);
            return DisplayHandler.AddActionToButton(action, isAvailable, replacedembly.GetCallingreplacedembly().GetName().Name, buttonName);
        }

19 View Source File : Utilities.cs
License : Apache License 2.0
Project Creator : AmpScm

public static string GetCallingreplacedemblyVersion()
        {
            return GetreplacedemblyVersion(replacedembly.GetCallingreplacedembly());
        }

19 View Source File : LayoutFileReader.cs
License : GNU General Public License v3.0
Project Creator : AndreiFedarets

public static string ReadViewModelLayout(IViewModel viewModel)
        {
            string viewModelLayout = string.Empty;
            replacedembly callingreplacedembly = replacedembly.GetCallingreplacedembly();
            string replacedemblyFilePath = callingreplacedembly.GetreplacedemblyPath();
            if (string.IsNullOrEmpty(replacedemblyFilePath))
            {
                return viewModelLayout;
            }
            string viewModelUid = viewModel.ViewModelUid;
            foreach (string searchDirectory in SearchDirectories)
            {
                string layoutFileFullName = Path.Combine(replacedemblyFilePath, searchDirectory, viewModelUid);
                layoutFileFullName += LayoutFileExtension;
                FileInfo fileInfo = new FileInfo(layoutFileFullName);
                //TODO: check size of file to prevent loading of huge files
                if (fileInfo.Exists)
                {
                    viewModelLayout = File.ReadAllText(layoutFileFullName);
                    return viewModelLayout;
                }
            }
            return null;
        }

19 View Source File : ApplicationManager.cs
License : GNU General Public License v3.0
Project Creator : AndreiFedarets

private static string GetApplicationFullName()
        {
            string fullName = replacedembly.GetCallingreplacedembly().GetreplacedemblyPath();
            fullName = Path.Combine(fullName, Constants.CoreProcessName.Host);
            return fullName;
        }

19 View Source File : FrameworkAdapter.cs
License : GNU General Public License v3.0
Project Creator : AndreiFedarets

private string GetAgentLibraryFullName()
        {
            string fullName = replacedembly.GetCallingreplacedembly().GetreplacedemblyPath();
            fullName = Path.Combine(fullName, Constants.AgentLibraryName);
            return fullName;
        }

19 View Source File : ApplicationManager.cs
License : GNU General Public License v3.0
Project Creator : AndreiFedarets

public static Process RunApplication()
            {
                string path = replacedembly.GetCallingreplacedembly().GetreplacedemblyPath();
                string fullName = Path.Combine(path, Constants.CoreExecutableName.Client);
                Process process = new Process();
                process.StartInfo = new ProcessStartInfo(fullName);
                //TODO: use command line argument instead of env variable
                process.StartInfo.UseShellExecute = false;
                process.Start();
                return process;
            }

19 View Source File : ApplicationManager.cs
License : GNU General Public License v3.0
Project Creator : AndreiFedarets

public static Process RunApplication(Guid sessionUid)
            {
                string path = replacedembly.GetCallingreplacedembly().GetreplacedemblyPath();
                string fullName = Path.Combine(path, Constants.CoreExecutableName.Client);
                Process process = new Process();
                process.StartInfo = new ProcessStartInfo(fullName);
                //TODO: use command line argument instead of env variable
                process.StartInfo.EnvironmentVariables[Chronos.Constants.SessionUidEnvironmentVariableName] = sessionUid.ToString();
                process.StartInfo.UseShellExecute = false;
                process.Start();
                return process;
            }

19 View Source File : AgentInstaller.cs
License : GNU General Public License v3.0
Project Creator : AndreiFedarets

private VariableCollection PrepareVariables()
        {
            VariableCollection variables = new VariableCollection();
            string location = replacedembly.GetCallingreplacedembly().Location;
            location = Path.GetDirectoryName(location);
            variables["replacedEMBLY_PATH"] = location;
            return variables;
        }

19 View Source File : Loc.cs
License : GNU General Public License v3.0
Project Creator : Angelinsky7

public static T Get<T>(String key) {
            return LocExtension.GetLocalizedValue<T>(replacedembly.GetCallingreplacedembly().GetName().Name + ":Resources:" + key);
        }

19 View Source File : WriteableBitmapConvertExtensions.cs
License : Apache License 2.0
Project Creator : anmcgrath

public static WriteableBitmap FromResource(this WriteableBitmap bmp, string relativePath)
      {
         var fullName = replacedembly.GetCallingreplacedembly().FullName;
         var asmName = new replacedemblyName(fullName).Name;
         return bmp.FromContent(asmName + ";component/" + relativePath);
      }

19 View Source File : ProgramConfiguration.cs
License : GNU General Public License v3.0
Project Creator : anotak

public string ReadPluginSetting(string setting, string defaultsetting) { return cfg.ReadSetting(GetPluginPathPrefix(replacedembly.GetCallingreplacedembly()) + setting, defaultsetting); }

19 View Source File : ProgramConfiguration.cs
License : GNU General Public License v3.0
Project Creator : anotak

public short ReadPluginSetting(string setting, short defaultsetting) { return cfg.ReadSetting(GetPluginPathPrefix(replacedembly.GetCallingreplacedembly()) + setting, defaultsetting); }

19 View Source File : ProgramConfiguration.cs
License : GNU General Public License v3.0
Project Creator : anotak

public int ReadPluginSetting(string setting, int defaultsetting) { return cfg.ReadSetting(GetPluginPathPrefix(replacedembly.GetCallingreplacedembly()) + setting, defaultsetting); }

19 View Source File : ProgramConfiguration.cs
License : GNU General Public License v3.0
Project Creator : anotak

public float ReadPluginSetting(string setting, float defaultsetting) { return cfg.ReadSetting(GetPluginPathPrefix(replacedembly.GetCallingreplacedembly()) + setting, defaultsetting); }

19 View Source File : ProgramConfiguration.cs
License : GNU General Public License v3.0
Project Creator : anotak

public long ReadPluginSetting(string setting, long defaultsetting) { return cfg.ReadSetting(GetPluginPathPrefix(replacedembly.GetCallingreplacedembly()) + setting, defaultsetting); }

19 View Source File : ProgramConfiguration.cs
License : GNU General Public License v3.0
Project Creator : anotak

public bool ReadPluginSetting(string setting, bool defaultsetting) { return cfg.ReadSetting(GetPluginPathPrefix(replacedembly.GetCallingreplacedembly()) + setting, defaultsetting); }

19 View Source File : ProgramConfiguration.cs
License : GNU General Public License v3.0
Project Creator : anotak

public byte ReadPluginSetting(string setting, byte defaultsetting) { return cfg.ReadSetting(GetPluginPathPrefix(replacedembly.GetCallingreplacedembly()) + setting, defaultsetting); }

19 View Source File : ProgramConfiguration.cs
License : GNU General Public License v3.0
Project Creator : anotak

public IDictionary ReadPluginSetting(string setting, IDictionary defaultsetting) { return cfg.ReadSetting(GetPluginPathPrefix(replacedembly.GetCallingreplacedembly()) + setting, defaultsetting); }

19 View Source File : ProgramConfiguration.cs
License : GNU General Public License v3.0
Project Creator : anotak

public bool WritePluginSetting(string setting, object settingvalue) { return cfg.WriteSetting(GetPluginPathPrefix(replacedembly.GetCallingreplacedembly()) + setting, settingvalue); }

19 View Source File : ProgramConfiguration.cs
License : GNU General Public License v3.0
Project Creator : anotak

public bool DeletePluginSetting(string setting) { return cfg.DeleteSetting(GetPluginPathPrefix(replacedembly.GetCallingreplacedembly()) + setting); }

19 View Source File : MapOptions.cs
License : GNU General Public License v3.0
Project Creator : anotak

public string ReadPluginSetting(string setting, string defaultsetting) { return mapconfig.ReadSetting(GetPluginPathPrefix(replacedembly.GetCallingreplacedembly()) + setting, defaultsetting); }

19 View Source File : MapOptions.cs
License : GNU General Public License v3.0
Project Creator : anotak

public int ReadPluginSetting(string setting, int defaultsetting) { return mapconfig.ReadSetting(GetPluginPathPrefix(replacedembly.GetCallingreplacedembly()) + setting, defaultsetting); }

19 View Source File : MapOptions.cs
License : GNU General Public License v3.0
Project Creator : anotak

public float ReadPluginSetting(string setting, float defaultsetting) { return mapconfig.ReadSetting(GetPluginPathPrefix(replacedembly.GetCallingreplacedembly()) + setting, defaultsetting); }

19 View Source File : MapOptions.cs
License : GNU General Public License v3.0
Project Creator : anotak

public short ReadPluginSetting(string setting, short defaultsetting) { return mapconfig.ReadSetting(GetPluginPathPrefix(replacedembly.GetCallingreplacedembly()) + setting, defaultsetting); }

19 View Source File : MapOptions.cs
License : GNU General Public License v3.0
Project Creator : anotak

public long ReadPluginSetting(string setting, long defaultsetting) { return mapconfig.ReadSetting(GetPluginPathPrefix(replacedembly.GetCallingreplacedembly()) + setting, defaultsetting); }

19 View Source File : MapOptions.cs
License : GNU General Public License v3.0
Project Creator : anotak

public bool ReadPluginSetting(string setting, bool defaultsetting) { return mapconfig.ReadSetting(GetPluginPathPrefix(replacedembly.GetCallingreplacedembly()) + setting, defaultsetting); }

19 View Source File : MapOptions.cs
License : GNU General Public License v3.0
Project Creator : anotak

public byte ReadPluginSetting(string setting, byte defaultsetting) { return mapconfig.ReadSetting(GetPluginPathPrefix(replacedembly.GetCallingreplacedembly()) + setting, defaultsetting); }

19 View Source File : MapOptions.cs
License : GNU General Public License v3.0
Project Creator : anotak

public IDictionary ReadPluginSetting(string setting, IDictionary defaultsetting) { return mapconfig.ReadSetting(GetPluginPathPrefix(replacedembly.GetCallingreplacedembly()) + setting, defaultsetting); }

19 View Source File : MapOptions.cs
License : GNU General Public License v3.0
Project Creator : anotak

public bool WritePluginSetting(string setting, object settingvalue) { return mapconfig.WriteSetting(GetPluginPathPrefix(replacedembly.GetCallingreplacedembly()) + setting, settingvalue); }

19 View Source File : MapOptions.cs
License : GNU General Public License v3.0
Project Creator : anotak

public bool DeletePluginSetting(string setting) { return mapconfig.DeleteSetting(GetPluginPathPrefix(replacedembly.GetCallingreplacedembly()) + setting); }

19 View Source File : AppLogger.cs
License : MIT License
Project Creator : anoyetta

public static void Init(
            string defaultLoggerName,
            string configFileName = null)
        {
            LoadConfiguration(configFileName, replacedembly.GetCallingreplacedembly());
            defaultLogger = LogManager.GetLogger(defaultLoggerName);

            Write($"{defaultLogger.Name} Init.");
        }

See More Examples