SortedSet<T>.ICollection.SyncRoot 屬性

定義

取得可用以同步存取 ICollection 的物件。Gets an object that can be used to synchronize access to the ICollection.

property System::Object ^ System::Collections::ICollection::SyncRoot { System::Object ^ get(); };
object System.Collections.ICollection.SyncRoot { get; }
member this.System.Collections.ICollection.SyncRoot : obj
 ReadOnly Property SyncRoot As Object Implements ICollection.SyncRoot

屬性值

Object

可用來同步存取 ICollection 的物件。An object that can be used to synchronize access to the ICollection. Dictionary<TKey,TValue>.KeyCollection 的預設實作中,這個屬性一律會傳回目前的執行個體。In the default implementation of Dictionary<TKey,TValue>.KeyCollection, this property always returns the current instance.

實作

備註

這個成員是明確介面成員實作,This member is an explicit interface member implementation. 只有在 SortedSet<T> 執行個體轉換成 ICollection 介面時,才能使用這個成員。It can be used only when the SortedSet<T> instance is cast to an ICollection interface.

這個方法是一項作業 O(1)This method is an O(1) operation.

適用於