malaikuangren

What is the purpose or drive to build thing like (xxx),How can it achieve the original goal of design?
上一页 1 ··· 16 17 18 19 20 21 22 23 24 ··· 27 下一页

2012年6月10日

How to make the statemachine WF project templete available in the VS2010

摘要: The Microsoft .NET Platform Update 1 consists of three packages:Microsoft .NET Framework 4 Platform Update 1 (KB2478063)This package contains the runtime files for the platform update. This package must be deployed on systems where applications that target the platform update are deployed.Multi-Targ 阅读全文

posted @ 2012-06-10 22:08 malaikuangren 阅读(317) 评论(0) 推荐(0) 编辑

2012年6月4日

Thread-Safety Read Write Lock(Synchronization of .net)

摘要: Quite often, instances of a type are thread-safe for concurrent read operations, but not for concurrent updates (nor for a concurrent read and update). This can also be true with resources such as a file. Although protecting instances of such types with a simpleexclusive lockfor all modes of access 阅读全文

posted @ 2012-06-04 18:59 malaikuangren 阅读(561) 评论(0) 推荐(0) 编辑
Barrier Class Usage(Synchronization of .net 4.0)

摘要: TheBarrierclass is a signaling construct new to Framework 4.0. It implements athread execution barrier, which allows many threads to rendezvous at a point in time. The class is very fast and efficient, and is built uponWait, Pulse, and spinlocks.To use this class:Instantiate it, specifying how many 阅读全文

posted @ 2012-06-04 15:15 malaikuangren 阅读(353) 评论(0) 推荐(0) 编辑
Main purposes of C# Volatile fields

摘要: IntroductionThe article describes the internals of volatile fields. I've seen a lot of discussions in the web regarding volatile fields. I've performed my own small research in this area, and here are some thoughts on this.Volatile fields and memory barrier: A look insideThe two main purpose 阅读全文

posted @ 2012-06-04 00:05 malaikuangren 阅读(521) 评论(0) 推荐(0) 编辑

2012年6月3日

Synchronization constructs of four categories

摘要: Simple blocking methodsThese wait for another thread to finish or for a period of time to elapse.Sleep,Join, andTask.Waitare simple blocking methods.Locking constructsThese limit the number of threads that can perform some activity or execute a section of code at a time.Exclusivelocking constructs a 阅读全文

posted @ 2012-06-03 20:39 malaikuangren 阅读(193) 评论(0) 推荐(0) 编辑

2012年6月2日

Thread-Safety Mutex vs Lock(Synchronization of .net)

摘要: MutexA Mutex works in much the same way as thelockstatement (that we will look at in theCritical sectionssection below), so I won't harp on about it too much. But the main advantage the Mutex has overlockstatements and theMonitorobject is that it can work across multiple processes, which provide 阅读全文

posted @ 2012-06-02 21:59 malaikuangren 阅读(398) 评论(0) 推荐(0) 编辑
Thread-Safety with the Semaphores Class(Synchronization of .net)

摘要: SemaphoresA Semaphore inherits fromSystem.Threading.WaitHandle; as such, it has theWaitOne()method. You are also able to use the staticSystem.Threading.WaitHandle,WaitAny(),WaitAll(),SignalAndWait()methods for more complex tasks.semaphores model like this. see below:I read something that described a 阅读全文

posted @ 2012-06-02 21:38 malaikuangren 阅读(397) 评论(0) 推荐(0) 编辑
Thread-Safety with the AutoResetEvent, ManualResetEvent Class(Synchronization of .net)

摘要: AutoResetEventFrom MSDN:"A thread waits for a signal by callingWaitOneon theAutoResetEvent. If theAutoResetEventis in the non-signaled state, the thread blocks, waiting for the thread that currently controls the resource to signal that the resource is available by callingSet.CallingSetsignalsAu 阅读全文

posted @ 2012-06-02 21:24 malaikuangren 阅读(5343) 评论(0) 推荐(0) 编辑
Thread-Safety with the Interlocked Class(Synchronization of .net)

摘要: Thread-Safety with the Interlocked ClassWhen developing multi-threaded software or using parallel programming techniques, it is essential that classes remain thread-safe. The Interlocked class provides methods that assist with thread safety by performing atomic operations.Thread-SafetyWhen you are u 阅读全文

posted @ 2012-06-02 14:45 malaikuangren 阅读(406) 评论(0) 推荐(0) 编辑

2012年6月1日

Thread LifeCycle in .net

摘要: At any time, a thread is said to be in one of severalthread states(illustrated inFig. 12.1)2. This section discusses these states and the transitions between states. Two classes critical for multithreaded applications areThreadandMonitor(System.Threadingnamespace). This section also discusses severa 阅读全文

posted @ 2012-06-01 22:28 malaikuangren 阅读(195) 评论(0) 推荐(0) 编辑
上一页 1 ··· 16 17 18 19 20 21 22 23 24 ··· 27 下一页