本文整理汇总了C#中IDestination类的典型用法代码示例。如果您正苦于以下问题:C# IDestination类的具体用法?C# IDestination怎么用?C# IDestination使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
IDestination类属于命名空间,在下文中一共展示了IDestination类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C#代码示例。
示例1: CallIndirect
public CallIndirect(LIRMethod parent, ISource targetMethod, IEnumerable<ISource> sources = null, IDestination returnValueDest = null) : base(parent, LIROpCode.CallIndirect)
{
this.TargetMethod = targetMethod;
if (sources != null)
Sources.AddRange(sources);
this.ReturnValueDestination = returnValueDest;
}
开发者ID:carriercomm,项目名称:Proton-1,代码行数:7,代码来源:CallIndirect.cs
示例2: Producer
public Producer(ISession session, IDestination dest, int count, MsgPriority priority)
{
this.session = session;
this.dest = dest;
this.count = count;
this.priority = priority;
}
开发者ID:Redi0,项目名称:meijing-ui,代码行数:7,代码来源:QueueConsumerPriorityTest.cs
示例3: Initialize
public Task Initialize(IDestination actor, long repeats)
{
this.actor = actor;
this.repeats = repeats;
return TaskDone.Done;
}
开发者ID:dVakulen,项目名称:Orleans.PingPong,代码行数:7,代码来源:Implementations.cs
示例4: Convert
public Convert(LIRMethod parent, ISource source, LIRType sourceType, IDestination dest, LIRType destType) : base(parent, LIROpCode.Convert)
{
Source = source;
SourceType = sourceType;
Destination = dest;
DestinationType = destType;
}
开发者ID:carriercomm,项目名称:Proton-1,代码行数:7,代码来源:Convert.cs
示例5: Unary
public Unary(LIRMethod parent, ISource src, IDestination dest, UnaryOperation op, LIRType argType) : base(parent, LIROpCode.Unary)
{
Source = src;
Destination = dest;
Operation = op;
ArgumentType = argType;
}
开发者ID:carriercomm,项目名称:Proton-1,代码行数:7,代码来源:Unary.cs
示例6: Destination
public Destination(IDestination destination)
{
if (destination == null)
throw new ArgumentNullException("destination");
this.destination = destination;
this.destinationType = DestinationType.Destination;
}
开发者ID:cylwit,项目名称:EasyNMS,代码行数:8,代码来源:Destination.cs
示例7: NmsSystemEventsImpl
public NmsSystemEventsImpl(INmsOperations nmsOperations,
IDestination cargoHandledDestination,
IDestination cargoUpdateDestination)
{
this.nmsOperations = nmsOperations;
this.cargoHandledDestination = cargoHandledDestination;
this.cargoUpdateDestination = cargoUpdateDestination;
}
开发者ID:awhatley,项目名称:dddsample.net,代码行数:8,代码来源:NmsSystemEventsImpl.cs
示例8: Math
public Math(LIRMethod parent, ISource srcA, ISource srcB, IDestination dest, MathOperation op, LIRType argType) : base(parent, LIROpCode.Math)
{
SourceA = srcA;
SourceB = srcB;
Destination = dest;
Operation = op;
ArgumentType = argType;
}
开发者ID:carriercomm,项目名称:Proton-1,代码行数:8,代码来源:Math.cs
示例9: Compare
public Compare(LIRMethod parent, ISource sourceA, ISource sourceB, IDestination destination, LIRType type, CompareCondition condition) : base(parent, LIROpCode.Compare)
{
this.SourceA = sourceA;
this.SourceB = sourceB;
this.Destination = destination;
this.Type = type;
this.Condition = condition;
}
开发者ID:carriercomm,项目名称:Proton-1,代码行数:8,代码来源:Compare.cs
示例10: CreateConsumer
public IMessageConsumer CreateConsumer(IDestination destination, string selector, bool noLocal)
{
if (selector != null)
{
throw new NotImplementedException("Selectors are not supported by MSQM");
}
MessageQueue queue = MessageConverter.ToMsmqDestination(destination);
return new MessageConsumer(this, acknowledgementMode, queue);
}
开发者ID:JianwenSun,项目名称:mono-soc-2007,代码行数:9,代码来源:Session.cs
示例11: PurgeQueue
private void PurgeQueue(IConnection conn, IDestination queue)
{
ISession session = conn.CreateSession();
IMessageConsumer consumer = session.CreateConsumer(queue);
while(consumer.Receive(TimeSpan.FromMilliseconds(500)) != null)
{
}
consumer.Close();
session.Close();
}
开发者ID:Redi0,项目名称:meijing-ui,代码行数:11,代码来源:QueueConsumerPriorityTest.cs
示例12: removeTempDestination
public void removeTempDestination(IDestination destination)
{
for(int i = tempDestinations.Count - 1; i >= 0; i--)
{
DestinationInfo di = tempDestinations[i];
if(di.Destination.Equals(destination))
{
tempDestinations.RemoveAt(i);
}
}
}
开发者ID:Redi0,项目名称:meijing-ui,代码行数:11,代码来源:ConnectionState.cs
示例13: PooledProducer
public PooledProducer(IMessageProducer producer, IDestination destination)
{
this.producer = producer;
this.destination = destination;
this.deliveryMode = producer.DeliveryMode;
this.disableMessageID = producer.DisableMessageID;
this.disableMessageTimestamp = producer.DisableMessageTimestamp;
this.priority = producer.Priority;
this.timeToLive = producer.TimeToLive;
}
开发者ID:tabish121,项目名称:NMS.Pooled,代码行数:11,代码来源:PooledProducer.cs
示例14: Purge
public void Purge(ISession session, IDestination destination)
{
lock (destinations)
{
if (!destinations.Contains(destination))
{
session.DeleteDestination(destination);
destinations.Add(destination);
}
}
}
开发者ID:modulexcite,项目名称:NServiceBus.ActiveMQ,代码行数:12,代码来源:ActiveMqPurger.cs
示例15: Send
public void Send(IDestination destination, IMessage message, MsgDeliveryMode deliveryMode, MsgPriority priority, TimeSpan timeToLive)
{
if (destination == null)
{
destination = this.destination;
}
IMessageProducer producer = this.MessageProducer;
lock(producer)
{
producer.Send(destination, message, deliveryMode, priority, timeToLive);
}
}
开发者ID:tabish121,项目名称:NMS.Pooled,代码行数:14,代码来源:PooledProducer.cs
示例16: RequestDeferredMessages
public void RequestDeferredMessages(IDestination browseDestination)
{
var session = SessionFactory.GetSession();
var amqSchedulerManagementDestination =
session.GetTopic(ScheduledMessage.AMQ_SCHEDULER_MANAGEMENT_DESTINATION);
using (var producer = session.CreateProducer(amqSchedulerManagementDestination))
{
var request = session.CreateMessage();
request.Properties[ScheduledMessage.AMQ_SCHEDULER_ACTION] = ScheduledMessage.AMQ_SCHEDULER_ACTION_BROWSE;
request.NMSReplyTo = browseDestination;
producer.Send(request);
}
}
开发者ID:modulexcite,项目名称:NServiceBus.ActiveMQ,代码行数:14,代码来源:ActiveMqSchedulerManagementCommands.cs
示例17: Queue
public Queue(MsgDeliveryMode mode = MsgDeliveryMode.NonPersistent)
{
Uri msgQueue = new Uri("activemq:tcp://localhost:61616");
_factory = new ConnectionFactory(msgQueue);
try
{
_connection = _factory.CreateConnection();
}
catch (NMSConnectionException ex)
{
Log.FatalException("Error connecting to MQ server", ex);
throw;
}
// TODO check _connection for null
_connection.RequestTimeout = TimeSpan.FromSeconds(60);
Session = _connection.CreateSession();
// TODO need to find out if queue exists.
// It creates a new queue if it doesn't exist.
_destination = Session.GetDestination("queue://TwitterSearchStream");
_consumer = Session.CreateConsumer(_destination);
_producer = Session.CreateProducer(_destination);
_producer.RequestTimeout = TimeSpan.FromSeconds(60);
_producer.DeliveryMode = mode;
_connection.Start();
_connection.ExceptionListener += _connection_ExceptionListener;
_connection.ConnectionInterruptedListener += _connection_ConnectionInterruptedListener;
}
开发者ID:cfmayer,项目名称:Toketee,代码行数:32,代码来源:Queue.cs
示例18: OpenWireConsumer
/// <summary>
/// 消息消费构造器
/// </summary>
/// <param name="brokerUri">地址</param>
/// <param name="username">用户名</param>
/// <param name="psw">密码</param>
/// <param name="clientId">客户端标识 兼做队列接收目的地</param>
/// <param name="isClient">true 客户端;false 服务端</param>
public OpenWireConsumer(string brokerUri, string username, string psw, string clientId,bool isClient)
{
NMSConnectionFactory _factory = new NMSConnectionFactory(brokerUri, clientId);
_connection = _factory.CreateConnection(username, psw);
_connection.Start();
_session = _connection.CreateSession(AcknowledgementMode.AutoAcknowledge);
if (isClient)
{
_qReceiveDest = _session.GetDestination(clientId, DestinationType.TemporaryQueue);
}
else
{
_qReceiveDest = _session.GetQueue(clientId);
}
_messageConsumer = _session.CreateConsumer(_qReceiveDest);
_messageConsumer.Listener += (message) =>
{
if (Listener != null)
{
Listener(message);
}
};
}
开发者ID:OldApple,项目名称:MQProxy,代码行数:33,代码来源:OpenWireMiddleware.cs
示例19: Receive
public String Receive(String queueName)
{
String message = "";
using (IConnection connection = factory.CreateConnection())
using (ISession session = connection.CreateSession())
{
destination = SessionUtil.GetDestination(session, "queue://" + queueName);
Console.WriteLine("Using destination: " + destination);
using (IMessageConsumer consumer = session.CreateConsumer(destination))
{
connection.Start();
ITextMessage textMessage = consumer.Receive() as ITextMessage;
if (textMessage == null)
{
Console.WriteLine("No message received!");
}
else
{
message = textMessage.Text;
}
}
}
return message;
}
开发者ID:klusha,项目名称:VK,代码行数:25,代码来源:Consumer.cs
示例20: JmsPort
/// <summary>
/// Default constructor
/// </summary>
/// <param name="destination">Destionation to connect with OpenEngSB</param>
protected JmsPort(string destination)
{
connection = null;
factory = null;
session = null;
this.destination = null;
Configure(destination);
}
开发者ID:Mercynary,项目名称:loom-csharp,代码行数:12,代码来源:JMSPort.cs
注:本文中的IDestination类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论