IPEndPointCollection.SetItem(Int32, IPEndPoint) 方法
定義
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
替換 IPEndPoint 指定索引的元素。
protected:
override void SetItem(int index, System::Net::IPEndPoint ^ item);
protected override void SetItem(int index, System.Net.IPEndPoint item);
override this.SetItem : int * System.Net.IPEndPoint -> unit
Protected Overrides Sub SetItem (index As Integer, item As IPEndPoint)
參數
- index
- Int32
要替換的元素的零基指數。
- item
- IPEndPoint
該元素在指定索引處的新 IPEndPoint 值。 值可以是 null 參考型別。
例外狀況
參數 item 為 null。
備註
IPEndPointCollection 不接受 null 為有效值。
IPEndPointCollection 允許元素重複。
此方法是 O(1) 作業。