本文整理汇总了C#中ISerializer.Requires方法的典型用法代码示例。如果您正苦于以下问题:C# ISerializer.Requires方法的具体用法?C# ISerializer.Requires怎么用?C# ISerializer.Requires使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类ISerializer
的用法示例。
在下文中一共展示了ISerializer.Requires方法的9个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: Listeners
internal Listeners(XDMessagingClient client, ISerializer serializer)
{
client.Requires("client").IsNotNull();
serializer.Requires("serializer").IsNotNull();
this.serializer = serializer;
}
示例2: XDIOStreamListener
internal XDIOStreamListener(ISerializer serializer)
{
serializer.Requires().IsNotNull();
this.serializer = serializer;
watcherList = new Dictionary<string, FileSystemWatcher>(StringComparer.InvariantCultureIgnoreCase);
}
示例3: WinMsgDataGram
internal WinMsgDataGram(ISerializer serializer, string channel, string dataType, string message)
{
serializer.Requires("serializer").IsNotNull();
this.serializer = serializer;
allocatedMemory = false;
dataStruct = new Native.COPYDATASTRUCT();
dataGram = new DataGram(channel, dataType, message);
}
示例4: NetworkRelayBroadcaster
public NetworkRelayBroadcaster(ISerializer serializer, XDTransportMode originalTransportMode,
IXDBroadcaster networkBroadcaster)
{
serializer.Requires("serializer").IsNotNull();
networkBroadcaster.Requires("networkBroadcaster").IsNotNull();
this.serializer = serializer;
this.originalTransportMode = originalTransportMode;
this.networkBroadcaster = networkBroadcaster;
networkChannel = GetNetworkListenerName(originalTransportMode);
}
示例5: XDAmazonBroadcaster
internal XDAmazonBroadcaster(ISerializer serializer, IPublisherService publisherService,
TopicRepository topicRepository)
{
serializer.Requires("serializer").IsNotNull();
publisherService.Requires("publisherService").IsNotNull();
topicRepository.Requires("topicRepository").IsNotNull();
this.serializer = serializer;
this.publisherService = publisherService;
this.topicRepository = topicRepository;
}
示例6: XDAmazonListener
internal XDAmazonListener(IIdentityProvider identityProvider, ISerializer serializer,
ITopicRepository topicRepository,
ISubscriberRepository subscriberRepository, ISubscriptionService subscriptionService)
{
identityProvider.Requires("identityProvider").IsNotNull();
serializer.Requires("serializer").IsNotNull();
topicRepository.Requires("topicRepository").IsNotNull();
subscriberRepository.Requires("subscriberRepository").IsNotNull();
subscriptionService.Requires("subscriptionService").IsNotNull();
useLongLiveQueues = identityProvider.Scope == IdentityScope.Machine;
uniqueInstanceId = identityProvider.GetUniqueId();
this.serializer = serializer;
this.topicRepository = topicRepository;
this.subscriberRepository = subscriberRepository;
this.subscriptionService = subscriptionService;
}
示例7: XDWinMsgListener
internal XDWinMsgListener(ISerializer serializer)
{
serializer.Requires("serializer").IsNotNull();
this.serializer = serializer;
var p = new CreateParams
{
Width = 0,
Height = 0,
X = 0,
Y = 0,
Caption = string.Concat("TheCodeKing.Net.XDServices.", Guid.NewGuid().ToString()),
Parent = IntPtr.Zero
};
CreateHandle(p);
}
示例8: XDIOStreamBroadcaster
internal XDIOStreamBroadcaster(ISerializer serializer)
{
serializer.Requires("serializer").IsNotNull();
this.serializer = serializer;
}
示例9: Broadcasters
internal Broadcasters(XDMessagingClient client, ISerializer serializer)
{
serializer.Requires("serializer").IsNotNull();
this.serializer = serializer;
}