本文整理汇总了C#中EndpointAddress类的典型用法代码示例。如果您正苦于以下问题:C# EndpointAddress类的具体用法?C# EndpointAddress怎么用?C# EndpointAddress使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
EndpointAddress类属于命名空间,在下文中一共展示了EndpointAddress类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: CreateSubscriptionRequest
static MessagePayload CreateSubscriptionRequest(EndpointAddress subscriberAddress, EndpointAddress publisherAddress)
{
return new MessagePayload()
.SetFromEndpointAddress(subscriberAddress)
.SetToEndpointAddress(publisherAddress)
.AsSubscriptionRequest();
}
示例2: ClientWebSocketTransportDuplexSessionChannel
public ClientWebSocketTransportDuplexSessionChannel(HttpChannelFactory<IDuplexSessionChannel> channelFactory, ClientWebSocketFactory connectionFactory, EndpointAddress remoteAddresss, Uri via, ConnectionBufferPool bufferPool)
: base(channelFactory, remoteAddresss, via, bufferPool)
{
Contract.Assert(channelFactory != null, "connection factory must be set");
_channelFactory = channelFactory;
_connectionFactory = connectionFactory;
}
示例3: IssuedSecurityTokenParameters
public IssuedSecurityTokenParameters (string tokenType,
EndpointAddress issuerAddress, Binding issuerBinding)
{
token_type = tokenType;
issuer_address = issuerAddress;
binding = issuerBinding;
}
示例4: CreateQueue
public static MessageQueue CreateQueue(EndpointAddress address, bool isTransactional = true)
{
var name = address.GetQueueName();
var queue = MessageQueue.Create(name, isTransactional);
SetQueuePermissions(queue);
return queue;
}
示例5: DuplexClientRuntimeChannel
public DuplexClientRuntimeChannel (ServiceEndpoint endpoint,
ChannelFactory factory, EndpointAddress remoteAddress, Uri via)
: base (endpoint, factory, remoteAddress, via)
{
var ed = new EndpointDispatcher (remoteAddress, endpoint.Contract.Name, endpoint.Contract.Namespace);
ed.InitializeServiceEndpoint (true, null, endpoint);
Runtime.CallbackDispatchRuntime = ed.DispatchRuntime;
}
示例6: DirectChannelConfiguration
public DirectChannelConfiguration(EndpointAddress address, MessagingConfiguration messagingConfiguration)
{
Contract.Requires(messagingConfiguration != null);
Contract.Requires(address != null);
this.messagingConfiguration = messagingConfiguration;
this.address = address;
}
示例7: AdjustAddress
static void AdjustAddress(ref EndpointAddress reference, Uri via)
{
// if we don't have an identity and we have differing Uris, we should use the Via
if (reference.Identity == null && reference.Uri != via)
{
reference = new EndpointAddress(via);
}
}
示例8: CallbackContextMessageProperty
public CallbackContextMessageProperty(EndpointAddress callbackAddress)
{
if (callbackAddress == null)
{
throw DiagnosticUtility.ExceptionUtility.ThrowHelperArgumentNull("callbackAddress");
}
this.callbackAddress = callbackAddress;
}
示例9: SenderAuthenticationSessionAttacher
public SenderAuthenticationSessionAttacher(
AuthenticationSessionCache cache,
AuthenticatedServerRegistry registry,
EndpointAddress address) : base(cache, registry)
{
Contract.Requires(address != null);
this.address = address;
}
示例10: ServiceEndpoint
public ServiceEndpoint(ContractDescription contract, Binding binding, EndpointAddress address)
{
if (contract == null)
throw DiagnosticUtility.ExceptionUtility.ThrowHelperArgumentNull("contract");
_contract = contract;
_binding = binding;
_address = address;
}
示例11: Send
public void Send(EndpointAddress destination, ChannelMessage channelMessage)
{
var queueName = destination.QueueName;
if (!namespaceManager.QueueExists(queueName)) throw new Exception(string.Format("Destination {0} does not exist.", destination));
var sendingClient = QueueClient.Create(queueName);
var message = CreateBrokeredMessage(channelMessage);
sendingClient.Send(message);
}
示例12: WebSocketTransportDuplexSessionChannel
public WebSocketTransportDuplexSessionChannel(HttpChannelFactory<IDuplexSessionChannel> channelFactory, EndpointAddress remoteAddresss, Uri via)
: base(channelFactory, channelFactory, EndpointAddress.AnonymousAddress, channelFactory.MessageVersion.Addressing.AnonymousUri, remoteAddresss, via)
{
Fx.Assert(channelFactory.WebSocketSettings != null, "channelFactory.WebSocketTransportSettings should not be null.");
_webSocketSettings = channelFactory.WebSocketSettings;
_transferMode = channelFactory.TransferMode;
_maxBufferSize = channelFactory.MaxBufferSize;
_transportFactorySettings = channelFactory;
}
示例13: CreateEndpointSettings
public CreateEndpointSettings(IEndpointAddress address)
: this()
{
Guard.Against.Null(address, "The address cannot be null");
Address = new EndpointAddress(address.Uri);
SetDefaultErrorAddress();
}
示例14: MessageTransmitTraceRecord
MessageTransmitTraceRecord(Message message, string addressElementName, EndpointAddress address)
:
this(message, addressElementName)
{
if (address != null)
{
this.address = address.Uri;
}
}
示例15: FreeUpSlot
void FreeUpSlot(Guid messageId, EndpointAddress address, PersistenceUseType useType)
{
if (useType != cache.UseType || address != cache.Address) return;
MessagePayload message;
sentMessages.TryRemove(messageId, out message);
SendMessages();
}