ForEachItem::IsSynchronized Property

 

Gets a Boolean that indicates whether access to the collection is synchronized (thread-safe).

Namespace:   Microsoft.SqlServer.Dts.Runtime.Enumerators.Item
Assembly:  Microsoft.SqlServer.ManagedDTS (in Microsoft.SqlServer.ManagedDTS.dll)

public:
property bool IsSynchronized {
	virtual bool get() sealed;
}

Property Value

Type: System::Boolean

True if access to the collection is synchronized (thread-safe); otherwise, false. The default is false.

Implements ICollection.IsSynchronized. If a collection is thread safe, the IsSynchronized property returns true, and the programmer does not have to do anything to keep the collection thread safe.

If the property returns false, then the SyncRoot property returns an object that can be used with the C# lock keyword. For more information, see ICollection.IsSynchronized.

The ArrayList is a .NET Framework Class that inherits and implements the IsSynchronized property. The following code example shows how to synchronize an ArrayList, determine if an ArrayList is synchronized and use a synchronized ArrayList.

No code example is currently available or this language may not be supported.

Sample Output:

myAL is not synchronized.

mySyncdAL is synchronized.

Return to top
Show: