SortedSet<T>.GetObjectData(SerializationInfo, StreamingContext) 方法

定義

實作 ISerializable 介面,並傳回序列化 SortedSet<T> 物件所必須具備的資料。Implements the ISerializable interface and returns the data that you must have to serialize a SortedSet<T> object.

protected:
 virtual void GetObjectData(System::Runtime::Serialization::SerializationInfo ^ info, System::Runtime::Serialization::StreamingContext context);
protected virtual void GetObjectData (System.Runtime.Serialization.SerializationInfo info, System.Runtime.Serialization.StreamingContext context);
abstract member GetObjectData : System.Runtime.Serialization.SerializationInfo * System.Runtime.Serialization.StreamingContext -> unit
override this.GetObjectData : System.Runtime.Serialization.SerializationInfo * System.Runtime.Serialization.StreamingContext -> unit
Protected Overridable Sub GetObjectData (info As SerializationInfo, context As StreamingContext)

參數

info
SerializationInfo

SerializationInfo 物件,包含序列化 SortedSet<T> 物件所需的資訊。A SerializationInfo object that contains the information that is required to serialize the SortedSet<T> object.

context
StreamingContext

StreamingContext 結構,包含與 SortedSet<T> 物件相關聯之已序列化資料流的來源和目的地。A StreamingContext structure that contains the source and destination of the serialized stream associated with the SortedSet<T> object.

例外狀況

infonullinfo is null.

備註

呼叫這個方法是一項作業 O(n) ,其中 nCountCalling this method is an O(n) operation, where n is Count.

適用於