6
Shouts

C#/.NET Little Wonders: Interlocked Increment(), Decrement(), and Add()

published 271 days, 21 hours, 46 minutes ago posted by BlackRabbitCoderBlackRabbitCoder 281 days, 20 hours, 45 minutes ago
Monday, August 20, 2012 12:23:10 PM GMT Friday, August 10, 2012 1:23:41 PM GMT

Often times, we need to update a count in a multi-threaded program. This may be an incrementing, decrementing, or adding a value in a thread-safe manner.

This post will discuss one of the lightest ways to do this: the Interlocked class.

category: Web Dev | clicked: 56 | | source: www.blackrabbitcoder.net | show counter code
tags:

2 comments posted.

To post your comment please login or signup