다음을 통해 공유


RemotingSurrogateSelector.GetSurrogate 메서드

제공된 컨텍스트에서 제공된 형식에 맞는 서로게이트를 반환합니다.

네임스페이스: System.Runtime.Remoting.Messaging
어셈블리: mscorlib(mscorlib.dll)

구문

‘선언
Public Overridable Function GetSurrogate ( _
    type As Type, _
    context As StreamingContext, _
    <OutAttribute> ByRef ssout As ISurrogateSelector _
) As ISerializationSurrogate
‘사용 방법
Dim instance As RemotingSurrogateSelector
Dim type As Type
Dim context As StreamingContext
Dim ssout As ISurrogateSelector
Dim returnValue As ISerializationSurrogate

returnValue = instance.GetSurrogate(type, context, ssout)
public virtual ISerializationSurrogate GetSurrogate (
    Type type,
    StreamingContext context,
    out ISurrogateSelector ssout
)
public:
virtual ISerializationSurrogate^ GetSurrogate (
    Type^ type, 
    StreamingContext context, 
    [OutAttribute] ISurrogateSelector^% ssout
)
public ISerializationSurrogate GetSurrogate (
    Type type, 
    StreamingContext context, 
    /** @attribute OutAttribute() */ /** @ref */ ISurrogateSelector ssout
)
JScript에서는 값 형식 인수를 참조로 전달할 수 없습니다.

매개 변수

  • type
    서로게이트가 요청되는 Type입니다.
  • context
    serialization 소스 또는 대상입니다.
  • ssout
    이 메서드가 반환될 때 지정된 개체 형식에 맞는 ISurrogateSelector를 포함합니다. 이 매개 변수는 초기화되지 않은 상태로 전달됩니다.

반환 값

지정된 컨텍스트의 지정된 형식에 맞는 서로게이트입니다.

설명

원격 서로게이트는 MarshalByRefObject에서 파생되는 개체의 원격 serialization 요구 사항을 처리합니다. MarshalByRefObject에서 파생되는 개체를 원격 위치로 serialize하는 동안 원격 서로게이트는 원격 개체를 활성화하고 이 개체와 통신하는 데 필요한 모든 관련 정보가 들어 있는 ObjRef를 만듭니다. 새로 만든 ObjRef를 원격 위치로 보내고 프록시를 만드는 데 사용할 수 있습니다.

플랫폼

Windows 98, Windows 2000 SP4, Windows Millennium Edition, Windows Server 2003, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP SP2, Windows XP Starter Edition

.NET Framework에서 모든 플래폼의 모든 버전을 지원하지는 않습니다. 지원되는 버전의 목록은 시스템 요구 사항을 참조하십시오.

버전 정보

.NET Framework

2.0, 1.1, 1.0에서 지원

참고 항목

참조

RemotingSurrogateSelector 클래스
RemotingSurrogateSelector 멤버
System.Runtime.Remoting.Messaging 네임스페이스