private string sharedRootPath = null;//共享的根目录,如果为null,表示共享整个磁盘。 #region Initialize public void Initialize(IFileOutter outter, string rootPath) { this.fileOutter = outter; this.sharedRootPath = rootPath; //要作为单例使用,否则,应该调用其Dispose方法,以释放预定的事件。 this.fileOutter.FileRequestReceived += new CbFileRequestReceived(fileOutter_FileRequestReceived); }
public NDiskForm(string ownerID,string nickName, IFileOutter fileOutter , INDiskOutter diskOutter) { InitializeComponent(); this.TopMost = false; this.ShowInTaskbar = true; this.nDiskBrowser1.Initialize(ownerID, fileOutter, diskOutter); this.Text = ownerID == null ? "我的网盘" : string.Format("远程磁盘 - {0}", nickName); }
public NDiskForm(string ownerID, string nickName, IFileOutter fileOutter, INDiskOutter diskOutter) { InitializeComponent(); this.TopMost = false; this.ShowInTaskbar = true; this.nDiskBrowser1.Initialize(ownerID, fileOutter, diskOutter); this.Text = ownerID == null ? "我的网盘" : string.Format("远程磁盘 - {0}", nickName); }
public void Initialize(IFileOutter _fileOutter, string friendUserID) { if (friendUserID == null) { friendUserID = ESFramework.NetServer.SystemUserID; } this.Initialize(_fileOutter, delegate(TransferingProject pro) { return(pro.DestUserID == friendUserID); }); }
/// <summary> /// 初始化。 /// </summary> /// <param name="_ownerID">如果为null,表示访问服务器上的某个目录(网盘)。否则,表示访问在线的目标用户的硬盘。</param> public void Initialize(string _ownerID, IFileOutter _fileOutter, INDiskOutter outter) { this.ownerID = _ownerID ?? NetServer.SystemUserID; this.currentDirPath = null; this.cutOrCopyAction = null; this.fileOutter = _fileOutter; this.fileDirectoryOutter = outter; this.fileTransferingViewer1.Initialize(this.fileOutter, this.FilterTransferingProject); this.LoadDirectory(null, true); }
public FileTransferingProgress imethod_3(string string_1) { IFileOutter interface2 = this.safeDictionary_1.Get(string_1); if (interface2 == null) { return(null); } return(interface2.imethod_1()); }
public void Initialize(string _ownerID, IFileOutter _fileOutter, INDiskOutter outter) { this.ownerID = _ownerID ?? NetServer.SystemUserID; this.currentDirPath = null; this.cutOrCopyAction = null; this.fileOutter = _fileOutter; this.fileDirectoryOutter = outter; this.fileTransferingViewer1.Initialize(this.fileOutter, delegate(TransferingProject pro) { return(pro.Comment != null && this.ownerID == pro.DestUserID); }); this.LoadDirectory(null, true); }
public void imethod_8(string string_1, out int int_1, out int int_2) { int_1 = 0; int_2 = 0; IFileOutter interface2 = this.safeDictionary_1.Get(string_1); if (interface2 != null) { int_1 = interface2.imethod_10(); int_2 = interface2.imethod_8(); } }
/// <summary> /// 调用该方法可恢复到未做任何连接的初始状态。 /// </summary> public void Reset() { this.ownerID = null; this.currentDirPath = null; this.cutOrCopyAction = null; this.fileOutter = null; this.fileDirectoryOutter = null; this.listView_fileDirectory.Clear(); this.toolStripButton_state.Image = this.imageList2.Images[0]; this.toolStripLabel_msg.Text = "就绪"; this.toolStripTextBox1.Text = ""; }
public void HnFdepcbbe(string string_1, ulong ulong_0, string string_2, ulong ulong_1) { TransferingProject project = this.imethod_2(string_1); if (project != null) { SendingFileParas paras = this.class3_0.imethod_0(project.AccepterID); int filePackageSize = paras.FilePackageSize; int sendingSpanInMSecs = paras.SendingSpanInMSecs; if (project.method_0() != null) { filePackageSize = project.method_0().FilePackageSize; sendingSpanInMSecs = project.method_0().SendingSpanInMSecs; } if (filePackageSize > (GlobalUtil.MaxLengthOfMessage - 100)) { filePackageSize = GlobalUtil.MaxLengthOfMessage - 100; } IFileOutter interface2 = null; if (project.IsFolder) { interface2 = new DirectorySender(this.emptyAgileLogger_0, (IFilePackageHelper)this.object_0, project.OriginPath, project.AccepterID, string_2, ulong_0, ulong_1); } else if (project.OriginStream == null) { interface2 = new FileSender(this.emptyAgileLogger_0, (IFilePackageHelper)this.object_0, project.OriginPath, project.AccepterID, ulong_0); } else { interface2 = new Class22(this.emptyAgileLogger_0, (IFilePackageHelper)this.object_0, project.OriginPath, project.OriginStream, project.TotalSize, project.AccepterID); } interface2.imethod_9(filePackageSize); interface2.imethod_11(sendingSpanInMSecs); interface2.imethod_13(this.int_0); interface2.imethod_6(project.ProjectID); interface2.FileTransProgress += new CbFileSendedProgress(this.method_8); interface2.FileTransCompleted += new CbFileTransCompleted(this.method_9); interface2.FileTransDisruptted += new CbFileTransDisruptted(this.method_10); this.safeDictionary_1.Add(interface2.imethod_5(), interface2); if (ulong_0 == 0L) { this.FileTransStarted(project); } else { this.FileTransCompleted(project); } interface2.HnFdepcbbe(this.bool_0); } }
public ChatForm(string _currentUserID, string _friendID, ICustomizeOutter _customizeInfoOutter, IFileOutter _fileOutter) { InitializeComponent(); this.currentUserID = _currentUserID; this.friendID = _friendID; this.fileOutter = _fileOutter; this.fileTransferingViewer1.Initialize(this.friendID, this.fileOutter); this.customizeInfoOutter = _customizeInfoOutter; this.textChatControl1.Initialize(_currentUserID, _friendID, _customizeInfoOutter); this.panel_plus.Visible = false; this.Width = 500; this.Text = string.Format("正在与{0}对话中...", _friendID); }
/// <summary> /// 初始化控件。 /// </summary> /// <param name="filter">当前的Viewer要显示哪些传送项目的状态信息</param> public void Initialize(IFileOutter _fileOutter, Func <TransferingProject, bool> filter) { this.fileOutter = _fileOutter; this.projectFilter = filter; //this.fileOutter.FileRequestReceived += new ESPlus.Application.FileTransfering.CbFileRequestReceived(fileOutter_FileRequestReceived); this.fileOutter.FileSendingEvents.FileTransStarted += new CbGeneric <TransferingProject>(fileTransStarted); this.fileOutter.FileSendingEvents.FileTransCompleted += new CbGeneric <TransferingProject>(fileTransCompleted); this.fileOutter.FileSendingEvents.FileTransDisruptted += new CbGeneric <TransferingProject, FileTransDisrupttedType>(fileTransDisruptted); this.fileOutter.FileSendingEvents.FileTransProgress += new CbFileSendedProgress(fileTransProgress); this.fileOutter.FileSendingEvents.FileResumedTransStarted += new CbGeneric <TransferingProject>(fileSenderManager_FileResumedTransStarted); this.fileOutter.FileReceivingEvents.FileTransStarted += new CbGeneric <TransferingProject>(fileTransStarted); this.fileOutter.FileReceivingEvents.FileResumedTransStarted += new CbGeneric <TransferingProject>(fileReceiverManager_FileResumedTransStarted); this.fileOutter.FileReceivingEvents.FileTransCompleted += new CbGeneric <TransferingProject>(fileTransCompleted); this.fileOutter.FileReceivingEvents.FileTransDisruptted += new CbGeneric <TransferingProject, FileTransDisrupttedType>(fileTransDisruptted); this.fileOutter.FileReceivingEvents.FileTransProgress += new CbFileSendedProgress(fileTransProgress); }
public void imethod_7(string string_1, FileTransDisrupttedType fileTransDisrupttedType_0, string string_2) { IFileOutter interface2 = this.safeDictionary_1.Get(string_1); if (interface2 != null) { interface2.imethod_0(fileTransDisrupttedType_0, string_2); } else { TransferingProject project = this.safeDictionary_0.Get(string_1); if (project != null) { this.safeDictionary_0.Remove(string_1); project.method_2(string_2); this.FileTransDisruptted(project, fileTransDisrupttedType_0); } } }
public void Initialize(IFileOutter _fileOutter) { this.Initialize(_fileOutter, (Func <TransferingProject, bool>)null); }
public void Initialize(IFileOutter outter, string rootPath) { this.fileOutter = outter; this.sharedRootPath = rootPath; //要作为单例使用,否则,应该调用其Dispose方法,以释放预定的事件。 this.fileOutter.FileRequestReceived += new CbFileRequestReceived(fileOutter_FileRequestReceived); }
public void Initialize(IFileOutter _fileOutter, string friendUserID) { if (friendUserID == null) { friendUserID = ESFramework.NetServer.SystemUserID; } this.Initialize(_fileOutter, delegate(TransferingProject pro) { return pro.DestUserID == friendUserID; }); }
public NDiskOutter(IFileOutter outter, ICustomizeOutter _customizeOutter) { this.fileOutter = outter; this.customizeOutter = _customizeOutter; }
public void Initialize(IFileOutter _fileOutter) { this.Initialize(_fileOutter, (Func<TransferingProject, bool>)null); }
/// <summary> /// ��ʼ���ؼ��� /// </summary> /// <param name="filter">��ǰ��ViewerҪ��ʾ��Щ������Ŀ��״̬��Ϣ</param> public void Initialize(IFileOutter _fileOutter, Func<TransferingProject, bool> filter) { this.fileOutter = _fileOutter; this.projectFilter = filter; //this.fileOutter.FileRequestReceived += new ESPlus.Application.FileTransfering.CbFileRequestReceived(fileOutter_FileRequestReceived); this.fileOutter.FileSendingEvents.FileTransStarted += new CbGeneric<TransferingProject>(fileTransStarted); this.fileOutter.FileSendingEvents.FileTransCompleted += new CbGeneric<TransferingProject>(fileTransCompleted); this.fileOutter.FileSendingEvents.FileTransDisruptted += new CbGeneric<TransferingProject, FileTransDisrupttedType>(fileTransDisruptted); this.fileOutter.FileSendingEvents.FileTransProgress += new CbFileSendedProgress(fileTransProgress); this.fileOutter.FileSendingEvents.FileResumedTransStarted += new CbGeneric<TransferingProject>(fileSenderManager_FileResumedTransStarted); this.fileOutter.FileReceivingEvents.FileTransStarted += new CbGeneric<TransferingProject>(fileTransStarted); this.fileOutter.FileReceivingEvents.FileResumedTransStarted += new CbGeneric<TransferingProject>(fileReceiverManager_FileResumedTransStarted); this.fileOutter.FileReceivingEvents.FileTransCompleted += new CbGeneric<TransferingProject>(fileTransCompleted); this.fileOutter.FileReceivingEvents.FileTransDisruptted += new CbGeneric<TransferingProject, FileTransDisrupttedType>(fileTransDisruptted); this.fileOutter.FileReceivingEvents.FileTransProgress += new CbFileSendedProgress(fileTransProgress); }
public void Initialize(string _ownerID, IFileOutter _fileOutter, INDiskOutter outter) { this.ownerID = _ownerID ?? NetServer.SystemUserID; this.currentDirPath = null; this.cutOrCopyAction = null; this.fileOutter = _fileOutter; this.fileDirectoryOutter = outter; this.fileTransferingViewer1.Initialize(this.fileOutter, delegate(TransferingProject pro) { return pro.Comment != null && this.ownerID == pro.DestUserID; }); this.LoadDirectory(null, true); }