CSharpTest.Net
IgnoreLocking Class
Members  Example  See Also  Send Feedback Download Help File
CSharpTest.Net.Library Assembly > CSharpTest.Net.Synchronization Namespace : IgnoreLocking Class

Glossary Item Box

wraps the reader/writer lock around Monitor

Syntax

Visual Basic (Declaration) 
Public Class IgnoreLocking 
   Implements ILockStrategy 
C# 
public class IgnoreLocking : ILockStrategy  

Example

Library/Library.Test/TestSynchronizedCollections.cs

C#Copy Code
SynchronizedList<int> list = new SynchronizedList<int>(new List<int>(), new IgnoreLocking());
list.Insert(0, 1);
Assert.AreEqual(1, list.Count);
list.ReplaceStorage(new List<int>());
Assert.AreEqual(0, list.Count);
VB.NETCopy Code
Dim list As New SynchronizedList(Of Integer)(New List(Of Integer)(), New IgnoreLocking())
list.Insert(0, 1)
Assert.AreEqual(1, list.Count)
list.ReplaceStorage(New List(Of Integer)())
Assert.AreEqual(0, list.Count)

Inheritance Hierarchy

System.Object
   CSharpTest.Net.Synchronization.IgnoreLocking

Requirements

Target Platforms: Windows XP, Windows Server 2003, Windows Vista, Windows Server 2008, Windows 7

See Also

Generated with Document! X 2011 by Innovasys