C# Class EducationPathways.ServiceBus.SubscriptionReceiver

Inheritance: IMessageReceiver, IDisposable
ファイルを表示 Open project: pebblecode/EducationPathways

Public Methods

Method Description
Dispose ( ) : void

Stops the listener if it was started previously.

Start ( MessageReleaseAction>.Func messageHandler ) : void

Starts the listener.

Stop ( ) : void

Stops the listener.

Protected Methods

Method Description
Dispose ( bool disposing ) : void
InvokeMessageHandler ( BrokeredMessage message ) : MessageReleaseAction
SubscriptionReceiver ( ServiceBusSettings settings, string topic, string subscription, bool processInParallel, Microsoft.Practices.TransientFaultHandling.RetryStrategy backgroundRetryStrategy ) : System

Initializes a new instance of the SubscriptionReceiver class, automatically creating the topic and subscription if they don't exist.

Private Methods

Method Description
ReceiveMessages ( CancellationToken cancellationToken ) : void

Receives the messages in an endless asynchronous loop.

ReleaseMessage ( BrokeredMessage msg, MessageReleaseAction releaseAction, long processingElapsedMilliseconds, long schedulingElapsedMilliseconds, Stopwatch roundtripStopwatch ) : void
SubscriptionReceiver ( ServiceBusSettings settings, string topic, string subscription, bool processInParallel = false ) : System

Method Details

Dispose() public method

Stops the listener if it was started previously.
public Dispose ( ) : void
return void

Dispose() protected method

protected Dispose ( bool disposing ) : void
disposing bool
return void

InvokeMessageHandler() protected method

protected InvokeMessageHandler ( BrokeredMessage message ) : MessageReleaseAction
message BrokeredMessage
return MessageReleaseAction

Start() public method

Starts the listener.
public Start ( MessageReleaseAction>.Func messageHandler ) : void
messageHandler MessageReleaseAction>.Func
return void

Stop() public method

Stops the listener.
public Stop ( ) : void
return void

SubscriptionReceiver() protected method

Initializes a new instance of the SubscriptionReceiver class, automatically creating the topic and subscription if they don't exist.
protected SubscriptionReceiver ( ServiceBusSettings settings, string topic, string subscription, bool processInParallel, Microsoft.Practices.TransientFaultHandling.RetryStrategy backgroundRetryStrategy ) : System
settings ServiceBusSettings
topic string
subscription string
processInParallel bool
backgroundRetryStrategy Microsoft.Practices.TransientFaultHandling.RetryStrategy
return System