NameObjectCollectionBase.OnDeserialization(Object) 方法

定義

實作 ISerializable 介面,並於還原序列化完成時引發還原序列化事件。Implements the ISerializable interface and raises the deserialization event when the deserialization is complete.

public:
 virtual void OnDeserialization(System::Object ^ sender);
public virtual void OnDeserialization (object sender);
abstract member OnDeserialization : obj -> unit
override this.OnDeserialization : obj -> unit
Public Overridable Sub OnDeserialization (sender As Object)

參數

sender
Object

還原序列化之事件的來源。The source of the deserialization event.

實作

例外狀況

與目前 SerializationInfo 執行個體關聯的 NameObjectCollectionBase 物件是無效的。The SerializationInfo object associated with the current NameObjectCollectionBase instance is invalid.

備註

雖然 OnDeserialization com 用戶端預設不會看到該方法,但繼承 NameObjectCollectionBase 類別可以公開它,而且可能會在 com 用戶端中造成不必要的行為。While the OnDeserialization method is not visible to COM clients by default, inheriting the NameObjectCollectionBase class can expose it and can cause undesirable behavior in COM clients.

這個方法是 O (n) 運算,其中 nCountThis method is an O(n) operation, where n is Count.

適用於

另請參閱