Esempio n. 1
0
        internal FusionContext(Loader loader, AssemblyProbe pluginProbe, IntPtr nativePluginLink)
        {
            if (loader == null)
                throw new ArgumentNullException("loader");

            if (pluginProbe == null)
                throw new ArgumentNullException("pluginProbe");

            if (nativePluginLink == IntPtr.Zero) 
                throw new ArgumentNullException("nativePluginLink");

            this.loader = loader;
            this.assemblyProbe = pluginProbe;
            this.nativePluginLink = nativePluginLink;
        }
Esempio n. 2
0
        public void LoadAssemblyProbe()
        {
            AssemblyProbe customProbe = null;

            try
            {
                string fusionAssemblyName = RuntimeConfiguration.Singleton.CustomFusionAssemblyName;
                string assemblyProbeTypeName = RuntimeConfiguration.Singleton.CustomAssemblyProbeTypeName;

                if (!String.IsNullOrEmpty(fusionAssemblyName) && !String.IsNullOrEmpty(assemblyProbeTypeName))
                    customProbe = InstantiateRemoteObject<AssemblyProbe>(fusionAssemblyName, assemblyProbeTypeName, null);
            }
            catch (Exception e)
            {
                Log.DebuggerWrite(0, Loader.LogCategory, "Unable to load custom assembly probe (" + e.Message + "), defaulting to the built-in one.");
            }

            assemblyProbe = customProbe ?? InstantiateRemoteObject<AssemblyProbe>(GetType().Assembly.FullName, typeof(DefaultAssemblyProbe).FullName);
        }