共用方式為


AsyncReaderWriterLock.LockFlags Enumeration

Microsoft internal only. Flags that modify the default lock behavior.

This enumeration has a FlagsAttribute attribute that allows a bitwise combination of its member values.

Namespace:  Microsoft.VisualStudio.Threading
Assembly:  Microsoft.VisualStudio.Threading (in Microsoft.VisualStudio.Threading.dll)

Syntax

'Declaration
<FlagsAttribute> _
Public Enumeration LockFlags
[FlagsAttribute]
public enum LockFlags
[FlagsAttribute]
public enum class LockFlags
[<FlagsAttribute>]
type LockFlags
public enum LockFlags

Members

Member name Description
None Microsoft internal only. The default behavior.
StickyWrite Microsoft internal only. Causes an upgradeable reader to remain in an upgraded-write state once upgraded, even after the nested write lock has been released.

This is useful when you have a batch of possible write operations, which may or may not actually apply in the end, but if any of them change anything, all of their changes should be seen atomically (within a single write lock). This approach is preferable to simply acquiring a write lock around the batch of potential changes because it doesn't defeat concurrent readers until it knows there is a change that actually must be made.

See Also

Reference

Microsoft.VisualStudio.Threading Namespace