Ejemplo n.º 1
0
 public override void SetTask(object task)
 {
     baseTask = task as ITaskEx;
     baseTask.SetTaskControl(new ProxyTaskControl(this));
     ScheduleMode = true;
     baseTask.Run();
 }
Ejemplo n.º 2
0
		public TaskRowModel(string name, TestNodeType type, ITaskEx task, bool delaySubscribeToTask)
		{
			_name = name;
			_type = type;
			_task = task;

			// Normally the TaskRowModel and task are created in the same AppDomain
			// and then the TaskRowModel is sent back to the main AppDomain. In this
			// case, we should not subscribe to PropertyChanged until deserialization.
			if (!delaySubscribeToTask) Subscribe();
		}
Ejemplo n.º 3
0
 private void UnloadDomainOf(ITaskEx task)
 {
     foreach (var assembly in _assemblies.Where(a => a.Domain.DomainCreated && a.Domain.Domain == task.Domain))
     {
         try {
             assembly.Domain.Unload();
         } catch (Exception ex) {
             Trace.WriteLine(ex.GetType().Name + " occurred while unloading domain of " + assembly.Path + ": " + ex.Message);
         }
     }
     _indUnloadSignal.OnSet();
 }
Ejemplo n.º 4
0
        public TaskRowModel(string name, TestNodeType type, ITaskEx task, bool delaySubscribeToTask)
        {
            _name = name;
            _type = type;
            _task = task;

            // Normally the TaskRowModel and task are created in the same AppDomain
            // and then the TaskRowModel is sent back to the main AppDomain. In this
            // case, we should not subscribe to PropertyChanged until deserialization.
            if (!delaySubscribeToTask)
            {
                Subscribe();
            }
        }
Ejemplo n.º 5
0
		private void UnloadDomainOf(ITaskEx task)
		{
			foreach (var assembly in _assemblies.Where(a => a.Domain.DomainCreated && a.Domain.Domain == task.Domain)) {
				try {
					assembly.Domain.Unload();
				} catch(Exception ex) {
					Trace.WriteLine(ex.GetType().Name + " occurred while unloading domain of " + assembly.Path + ": " + ex.Message);
				}
			}
			_indUnloadSignal.OnSet();
		}