我希望在提交操作运行时监控传输的字节速率
我使用了SvnClient.Progress事件,但是
我的代码是:
using (SvnClient cl = new SvnClient()) {
cl.Progress += new EventHandler<SvnProgressEventArgs>(cl_Progress);
SvnCommitResult res;
cl.Commit(PathToFile, new SvnCommitArgs {LogMessage = "Commit message" }, out res);
}
事件处理程序:
static void cl_Progress(object sender, SvnProgressEventArgs e) {
log( e.TotalProgress - e.Progress ) ;
}