FileWebRequest.GetObjectData(SerializationInfo, StreamingContext) 方法

定义

使用将目标对象序列化所需的数据填充 SerializationInfoPopulates a SerializationInfo with the data needed to serialize the target object.

protected:
 override void GetObjectData(System::Runtime::Serialization::SerializationInfo ^ serializationInfo, System::Runtime::Serialization::StreamingContext streamingContext);
protected override void GetObjectData (System.Runtime.Serialization.SerializationInfo serializationInfo, System.Runtime.Serialization.StreamingContext streamingContext);
override this.GetObjectData : System.Runtime.Serialization.SerializationInfo * System.Runtime.Serialization.StreamingContext -> unit

参数

serializationInfo
SerializationInfo

要填充数据的 SerializationInfoThe SerializationInfo to populate with data.

streamingContext
StreamingContext

用于指定该序列化的目标的 StreamingContextA StreamingContext that specifies the destination for this serialization.

实现

注解

格式化程序将自动跟踪和序列化 SerializationInfo 中包含的所有对象。Any objects that are included in the SerializationInfo are automatically tracked and serialized by the formatter.

适用于