示例#1
0
文件: WorkSpace.cs 项目: BgRva/Blob1
 internal void _pipesMgr_Added(IPipes sender, PipeCollectionEventArgs ea)
 {
     if (sender != null)
     {
         for (int i = 0; i < ea.Pipes.Length; i++)
         {
             ea.Pipes[i].StatusChanging+= new StatusChangeEventHandler<IPipe, PipeStatusChangeEventArgs>(pipe_StatusChanging);
             ea.Pipes[i].StatusChanged += new StatusChangeEventHandler<IPipe, PipeStatusChangeEventArgs>(pipe_StatusChanged);
         }
         if (ea.Pipes.Length>0)
         {
             PipeInstancesAddedEventArgs arg = new PipeInstancesAddedEventArgs(ea.Pipes);
             OnPipeInstancesAdded(arg);
         }
     }
 }
示例#2
0
 public void PipeInstancesAdded_DummyHandler(IWorkSpace sender, PipeInstancesAddedEventArgs ea)
 {
     //throw new Exception("The method or operation is not implemented.");
     PipeInstancesAdded_TimesHandled++;
 }
示例#3
0
文件: WorkSpace.cs 项目: BgRva/Blob1
 /// <summary>
 /// Triggers the PipeInstancesAdded event.
 /// </summary>
 internal virtual void OnPipeInstancesAdded(PipeInstancesAddedEventArgs ea)
 {
     if (PipeInstancesAdded != null)
         PipeInstancesAdded(this, ea);
 }
示例#4
0
 internal void _wkSpce_PipeInstanceAdded(IWorkSpace sender, PipeInstancesAddedEventArgs ea)
 {
     // TODO LOG!!!!! this is where to log that an pipe instance was added, as this is the confirmation
     // from the workspace.  Here to is were you should notify of errors.  Otherwise, there is nothing else needed to do here
     //if (sender != null)
     //{
     //    StringBuilder sb = new StringBuilder();
     //    sb.Append("Pipe (models) added:");
     //    sb.Append(Environment.NewLine);
     //    for (int i = 0; i < ea.Pipes.Length; i++)
     //    {
     //        sb.Append(string.Format("{0}: [{1}]", ea.Pipes[i].GetType().FullName, ea.Pipes[i].Id));
     //        sb.Append(Environment.NewLine);
     //    }
     //    Debug.Write(sb.ToString());
     //}
 }