当前位置: 首页>>代码示例>>C#>>正文


C# ISession.CreateQueue方法代码示例

本文整理汇总了C#中ISession.CreateQueue方法的典型用法代码示例。如果您正苦于以下问题:C# ISession.CreateQueue方法的具体用法?C# ISession.CreateQueue怎么用?C# ISession.CreateQueue使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在ISession的用法示例。


在下文中一共展示了ISession.CreateQueue方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: Connect

 private void Connect()
 {
     factory = XmsUtilities.CreateConnectionFactory(destination);
     connection = factory.CreateConnection();
     connection.ExceptionListener += OnError;
     session = connection.CreateSession(transactional, AcknowledgeMode.AutoAcknowledge);
     queue = session.CreateQueue(destination.Queue);
     queue.SetIntProperty(XMSC.DELIVERY_MODE, XMSC.DELIVERY_PERSISTENT);
     producer = session.CreateProducer(queue);
 }
开发者ID:sasha-uk,项目名称:NServiceBus.Xms.2,代码行数:10,代码来源:XmsProducer.cs

示例2: Connect

 public void Connect()
 {
     log.Debug("New physical producer created. About to connect.");
     factory = XmsUtilities.CreateConnectionFactory(address);
     connection = factory.CreateConnection();
     connection.ExceptionListener += OnError;
     session = connection.CreateSession(transactional, AcknowledgeMode.AutoAcknowledge);
     queue = session.CreateQueue(address.Queue);
     queue.SetIntProperty(XMSC.DELIVERY_MODE, XMSC.DELIVERY_PERSISTENT);
     producer = session.CreateProducer(queue);
     connected = true;
     log.Debug("New physical producer successfully connected.");
 }
开发者ID:sasha-uk,项目名称:NServiceBus.Xms.3,代码行数:13,代码来源:XmsProducer.cs

示例3: Connect

 public void Connect()
 {
     factory = XmsUtilities.CreateConnectionFactory(address);
     connection = factory.CreateConnection();
     connection.ExceptionListener += OnError;
     session = connection.CreateSession(transactional, AcknowledgeMode.AutoAcknowledge);
     queue = session.CreateQueue(address.Queue);
     queue.SetIntProperty(XMSC.DELIVERY_MODE,
                          transactional ? XMSC.DELIVERY_PERSISTENT : XMSC.DELIVERY_NOT_PERSISTENT);
     consumer = session.CreateConsumer(queue);
     connection.Start();
     connected = true;
 }
开发者ID:sasha-uk,项目名称:NServiceBus.Xms.3,代码行数:13,代码来源:XmsConsumer.cs

示例4: ResolveQueue

 /// <summary> Resolve the given destination name to a Queue.</summary>
 /// <param name="session">the current EMS Session
 /// </param>
 /// <param name="queueName">the name of the desired Queue.
 /// </param>
 /// <returns> the EMS Queue name
 /// </returns>
 /// <throws>EMSException if resolution failed </throws>
 protected internal virtual Destination ResolveQueue(ISession session, string queueName)
 {
     return session.CreateQueue(queueName);
 }
开发者ID:ouyangyl,项目名称:MySpringNet,代码行数:12,代码来源:DynamicDestinationResolver.cs


注:本文中的ISession.CreateQueue方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。