C# Class IronPigeon.Dart.PostalService

An email sending and receiving service.
ファイルを表示 Open project: AArnott/IronPigeon

Public Methods

Method Description
DeleteAsync ( Message message, CancellationToken cancellationToken = default(CancellationToken) ) : Task

Deletes the specified message from its online inbox so it won't be retrieved again.

PostAsync ( Message message, IProgress bytesCopiedProgress = null, CancellationToken cancellationToken = default(CancellationToken) ) : Task>

Sends the specified dart to the recipients specified in the message.

PostalService ( ) : System

Initializes a new instance of the PostalService class.

PostalService ( Channel channel ) : System

Initializes a new instance of the PostalService class.

ReceiveAsync ( bool longPoll = false, bool purgeUnsupportedMessages = false, IProgress progress = null, CancellationToken cancellationToken = default(CancellationToken) ) : Task>

Retrieves all messages waiting for pickup at our endpoint.

Private Methods

Method Description
FromPayload ( Channel payloadReceipt ) : MessageReceipt

Extracts a message from its serialized payload wrapper.

Method Details

DeleteAsync() public method

Deletes the specified message from its online inbox so it won't be retrieved again.
public DeleteAsync ( Message message, CancellationToken cancellationToken = default(CancellationToken) ) : Task
message Message The message to delete from its online location.
cancellationToken System.Threading.CancellationToken The cancellation token.
return Task

PostAsync() public method

Sends the specified dart to the recipients specified in the message.
public PostAsync ( Message message, IProgress bytesCopiedProgress = null, CancellationToken cancellationToken = default(CancellationToken) ) : Task>
message Message The dart to send.
bytesCopiedProgress IProgress Progress feedback in terms of bytes uploaded.
cancellationToken System.Threading.CancellationToken The cancellation token.
return Task>

PostalService() public method

Initializes a new instance of the PostalService class.
public PostalService ( ) : System
return System

PostalService() public method

Initializes a new instance of the PostalService class.
public PostalService ( Channel channel ) : System
channel Channel The channel.
return System

ReceiveAsync() public method

Retrieves all messages waiting for pickup at our endpoint.
public ReceiveAsync ( bool longPoll = false, bool purgeUnsupportedMessages = false, IProgress progress = null, CancellationToken cancellationToken = default(CancellationToken) ) : Task>
longPoll bool if set to true [long poll].
purgeUnsupportedMessages bool A value indicating whether to purge any messages that are not Dart messages. False will skip the messages but will not delete them from the server.
progress IProgress A callback to invoke for each downloaded message as it arrives.
cancellationToken System.Threading.CancellationToken The cancellation token.
return Task>