• 您的位置我爱Aspx >> VB.Net >> 介绍VB.NET的线程(英文)
  • 介绍VB.NET的线程(英文)

  • 作者:aspxer  来源:internet  日期:2007-5-20 14:01:01  关键字:.net
  • One classic server application example is collating information from diverse data sources. Imagine you build a method on an object that needs to collect responses from five or six Web Services dotted around the Internet. Each of those Web Services will have a certain response time, depending on how busy the server is, how far away it is (in terms of the quality of the link) and what it has to do to get the data. You cannot return from the method until you@#ve correlated all of the responses from each of the servers.

    Without threading, you have to do this job sequentially, i.e. you ask the first one, wait for a response, ask the second one, wait again, and so on. With threading, you can make all the operations sequential by making all six requests at the same time, and then collate information when all the requests have been satisfied. That way, the caller has to wait for the "longest response time", rather than an aggregate of all six of the response times.

    我对这篇文章有话说?
  • 广告位招租,广告代号:content_468_15
  • 上一篇:Visual Basic.NET 中的语言新变化
    下一篇:一步一步安装VB.Net(图片较多,请稍等)