次の方法で共有


RealProxy.GetObjectData(SerializationInfo, StreamingContext) メソッド

定義

RealProxy の現在のインスタンスが表すオブジェクトの透過プロキシを、指定した SerializationInfo に追加します。

public:
 virtual void GetObjectData(System::Runtime::Serialization::SerializationInfo ^ info, System::Runtime::Serialization::StreamingContext context);
public virtual void GetObjectData (System.Runtime.Serialization.SerializationInfo info, System.Runtime.Serialization.StreamingContext context);
[System.Security.SecurityCritical]
public 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
[<System.Security.SecurityCritical>]
abstract member GetObjectData : System.Runtime.Serialization.SerializationInfo * System.Runtime.Serialization.StreamingContext -> unit
override this.GetObjectData : System.Runtime.Serialization.SerializationInfo * System.Runtime.Serialization.StreamingContext -> unit
Public Overridable Sub GetObjectData (info As SerializationInfo, context As StreamingContext)

パラメーター

info
SerializationInfo

透過プロキシのシリアル化先の SerializationInfo

context
StreamingContext

シリアル化元とシリアル化先。

属性

例外

info パラメーターまたは context パラメーターが null です。

直前の呼び出し元に、SerializationFormatter アクセス許可がありません。

[System::Security::Permissions::SecurityPermissionAttribute(
System::Security::Permissions::SecurityAction::LinkDemand,
Flags=System::Security::Permissions::SecurityPermissionFlag::Infrastructure)]
virtual void GetObjectData( SerializationInfo^ info, StreamingContext context ) override
{
   // Add your custom data if any here.
   RealProxy::GetObjectData( info, context );
}
public override void GetObjectData( SerializationInfo info,
                                    StreamingContext context)
{
   // Add your custom data if any here.
   base.GetObjectData(info, context);
}
Public Overrides Sub GetObjectData(info As SerializationInfo, context As StreamingContext)
   ' Add your custom data if any here.
   MyBase.GetObjectData(info, context)
End Sub

適用対象