コード例 #1
0
        public IDisposable CreateExternalProcessObject(Type type, bool shared)
        {
            CheckRemoteType(type);
            ProcessHostController hc = GetHost(type.ToString(), shared, null);

            return((IDisposable)hc.CreateInstance(type.Assembly.Location, type.FullName, GetRequiredAddins(type)));
        }
コード例 #2
0
        ProcessHostController GetHost(string id, bool shared, IExecutionHandler executionHandler)
        {
            if (!shared)
            {
                return(new ProcessHostController(id, 0, executionHandler));
            }

            lock (this) {
                if (externalProcess == null)
                {
                    externalProcess = new ProcessHostController("SharedHostProcess", 10000, null);
                }

                return(externalProcess);
            }
        }
コード例 #3
0
ファイル: ProcessService.cs プロジェクト: Kalnor/monodevelop
		ProcessHostController GetHost (string id, bool shared, IExecutionHandler executionHandler)
		{
			if (!shared)
				return new ProcessHostController (id, 0, executionHandler);
			
			lock (this) {
				if (externalProcess == null)
					externalProcess = new ProcessHostController ("SharedHostProcess", 10000, null);
	
				return externalProcess;
			}
		}