SendMailJobCollection Class |
Namespace: MailBee.SmtpMail
The SendMailJobCollection type exposes the following members.
Name | Description | |
---|---|---|
Add |
Adds a send-mail job into the collection.
| |
Clear |
Removes all elements from the collection.
| |
CopyTo |
Copies the entire collection to a compatible one-dimensional Array, starting at the specified index of the target array.
| |
Equals | Determines whether the specified object is equal to the current object. (Inherited from Object.) | |
Finalize | Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection. (Inherited from Object.) | |
GetEnumerator |
Returns an enumerator that can iterate through the collection.
| |
GetHashCode | Serves as the default hash function. (Inherited from Object.) | |
GetIndicesAsArray |
Returns the integer array containing list of data table row indices
associated with the jobs belonging to the collection.
| |
GetIndicesAsString |
Returns the string containing comma-separated list of data table row indices
associated with the jobs belonging to the collection.
| |
GetType | Gets the Type of the current instance. (Inherited from Object.) | |
MemberwiseClone | Creates a shallow copy of the current Object. (Inherited from Object.) | |
Remove |
Removes the specified SendMailJob from the collection.
| |
RemoveAt |
Removes the job with the specified index from the collection.
| |
ToString | Returns a string that represents the current object. (Inherited from Object.) |
Name | Description | |
---|---|---|
Count |
Gets the number of elements contained in the collection.
| |
IsReadOnly |
Gets whether the collection may not be modified.
| |
IsSynchronized |
Gets a value indicating whether access to the collection is synchronized (thread-safe).
| |
Item |
Gets the element at the specified index.
| |
SyncRoot |
Gets an object that can be used to synchronize access to the collection.
|
In MailBee, instances of this class contain lists of mail messages or mail merge tasks which will be (or already have been) processed.
JobsPending, JobsRunning, JobsSuccessful, and JobsFailed properties of Smtp class have SendMailJobCollection type.
JobsPending contains jobs to be processed, JobsRunning - currently being processed, JobsSuccessful and JobsFailed - finished jobs.
During processing, jobs migrate between the collections (i.e. the job which had originally been placed into JobsPending moves into JobsRunning when processing starts, and ends up in JobsSuccessful or JobsFailed).
However, mail merge jobs may spawn additional jobs. I.e. if a mail merge job of processing 10 data table rows goes into processing, it resides in JobsPending for a while (and the number of rows yet to be processed sequentially decrements to 9, 8, etc). At the same time, rows which are being processed are converted into SendMailJob objects representing tasks to process a single data row as mail merge. Thus, usually mail merge of 10 data rows (a single job) finally ends up in 10 SendMailJob objects in JobsSuccessful or JobsFailed collections. To change this behavior, create mail merge jobs using Smtp.AddJob(string, string, EmailAddressCollection, DataTable, object, bool, bool) overload or its IDataReader version (Smtp.AddJob(string, string, EmailAddressCollection, IDataReader, object, bool, bool)).
Note |
---|
In .NET Core and UWP apps, only single-message mail jobs are supported. There is no mail merge over database support. |