DateTime.ISerializable.GetObjectData(SerializationInfo, StreamingContext) DateTime.ISerializable.GetObjectData(SerializationInfo, StreamingContext) DateTime.ISerializable.GetObjectData(SerializationInfo, StreamingContext) Method

定义

使用序列化当前的 SerializationInfo 对象所需的所有数据填充 DateTime 对象。Populates a SerializationInfo object with the data needed to serialize the current DateTime object.

 virtual void System.Runtime.Serialization.ISerializable.GetObjectData(System::Runtime::Serialization::SerializationInfo ^ info, System::Runtime::Serialization::StreamingContext context) = System::Runtime::Serialization::ISerializable::GetObjectData;
[System.Security.SecurityCritical]
void ISerializable.GetObjectData (System.Runtime.Serialization.SerializationInfo info, System.Runtime.Serialization.StreamingContext context);
Sub GetObjectData (info As SerializationInfo, context As StreamingContext) Implements ISerializable.GetObjectData

参数

info
SerializationInfo SerializationInfo SerializationInfo

要填充数据的对象。The object to populate with data.

context
StreamingContext StreamingContext StreamingContext

此序列化的目标。The destination for this serialization. (未使用此参数;指定 null。)(This parameter is not used; specify null.)

实现

异常

注解

此方法info Ticks用和Kind属性值填充参数。This method populates the info parameter with the Ticks and Kind property values.

安全性

SecurityCriticalAttribute
需要对直接调用方的完全信任。requires full trust for the immediate caller. 部分受信任的或透明的代码不能使用此成员。This member cannot be used by partially trusted or transparent code.

适用于