C# Class SevenDigital.Messaging.MessageReceiving.LocalQueue.LocalQueuePollingNode

Message polling node that reads from a locally accessible DiskQueue
Inheritance: ITypedPollingNode
显示文件 Open project: i-e-b/SevenDigital.Messaging

Public Methods

Method Description
AddMessageType ( Type type ) : void

A message type for which to poll

BlockUntilReady ( ) : bool

Advisory method: block if the queue is waiting to be populated.

Always immediately returns true in this instance.

Enqueue ( IPendingMessage work ) : void

Not supported

Length ( ) : int

Approximate snapshot length.

Always returns zero in this instance.

LocalQueuePollingNode ( string dispatchPath, string incomingPath, IMessageSerialiser serialiser, ISleepWrapper sleeper ) : System

Create a local polling node.

You should not use this yourself. Use:

MessagingSystem.Configure.WithLocalQueue(...);

and receive messages as normal.

Stop ( ) : void

Stop receiving messages

Deregisters all message types

TryDequeue ( ) : IWorkQueueItem>

Try and get an item from this queue. Success is encoded in the WorkQueueItem{T} result 'HasItem'

Private Methods

Method Description
Ignore ( ) : void

Ignore exceptions of this type

TryPumpingMessages ( IPersistentQueue dispatchQueue ) : void

Try to move messages from the incoming queue to the dispatch queue

Method Details

AddMessageType() public method

A message type for which to poll
public AddMessageType ( Type type ) : void
type System.Type
return void

BlockUntilReady() public method

Advisory method: block if the queue is waiting to be populated.

Always immediately returns true in this instance.

public BlockUntilReady ( ) : bool
return bool

Enqueue() public method

Not supported
public Enqueue ( IPendingMessage work ) : void
work IPendingMessage
return void

Length() public method

Approximate snapshot length.

Always returns zero in this instance.

public Length ( ) : int
return int

LocalQueuePollingNode() public method

Create a local polling node.

You should not use this yourself. Use:

MessagingSystem.Configure.WithLocalQueue(...);

and receive messages as normal.
public LocalQueuePollingNode ( string dispatchPath, string incomingPath, IMessageSerialiser serialiser, ISleepWrapper sleeper ) : System
dispatchPath string
incomingPath string
serialiser IMessageSerialiser
sleeper ISleepWrapper
return System

Stop() public method

Stop receiving messages

Deregisters all message types

public Stop ( ) : void
return void

TryDequeue() public method

Try and get an item from this queue. Success is encoded in the WorkQueueItem{T} result 'HasItem'
public TryDequeue ( ) : IWorkQueueItem>
return IWorkQueueItem>