本文整理汇总了C#中Identity.RaceSetChannelSink方法的典型用法代码示例。如果您正苦于以下问题:C# Identity.RaceSetChannelSink方法的具体用法?C# Identity.RaceSetChannelSink怎么用?C# Identity.RaceSetChannelSink使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Identity
的用法示例。
在下文中一共展示了Identity.RaceSetChannelSink方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: TransitionCall
[System.Security.SecurityCritical] // auto-generated
internal TransitionCall(IntPtr targetCtxID, IntPtr eeData, int targetDomainID)
{
Contract.Assert(targetCtxID != IntPtr.Zero, "bad target ctx for call back");
Contract.Assert(targetDomainID !=0, "bad target ctx for call back");
_sourceCtxID = Thread.CurrentContext.InternalContextID;
_targetCtxID = targetCtxID;
_delegate = null;
_targetDomainID = targetDomainID;
_eeData = eeData;
// In the cross domain case, the client side just has a base Identity
// and the server domain has the Server identity. We fault in the latter
// when requested later.
// We are going to a context in another app domain
_srvID = null;
_ID = new Identity("TransitionCallURI", null);
// Create the data needed for the channel sink creation
CrossAppDomainData data =
new CrossAppDomainData(_targetCtxID,
_targetDomainID,
Identity.ProcessGuid);
String unUsed;
IMessageSink channelSink =
CrossAppDomainChannel.AppDomainChannel.CreateMessageSink(
null, //uri
data, //channelData
out unUsed);//out objURI
Contract.Assert(channelSink != null, "X-domain transition failure");
_ID.RaceSetChannelSink(channelSink);
} // TransitionCall