Pitfalls of (Mis)Using C# Iterators to Implement Coroutines

前端 未结 4 672
刺人心
刺人心 2021-01-31 20:32

I am writing refactoring a Silverlight program to consumes a portion of its existing business logic from a WCF service. In doing so, I\'ve run into the restriction in Silverligh

4条回答
  •  心在旅途
    2021-01-31 21:28

    You should definitely look at the Concurrency and Coordination Runtime. It uses iterators for exactly this purpose.

    On the other hand, you should also look at Parallel Extensions and its approach to continuations. Parallel Extensions is part of .NET 4.0, whereas the CCR requires separate licensing. I would advise you to go with a framework written by people who eat, breathe and sleep this stuff though. It's just too easy to get details wrong on your own.

提交回复
热议问题