Interfaces with the database to perform operations on the delayed_email_queue table.
More...
|
| __construct (Database $db) |
| Create new service. More...
|
|
| queueEmail (int $recipient_guid, string $delivery_interval, $item) |
| Insert a delayed email into the queue. More...
|
|
| getRow (int $id) |
| Get a row from the queue. More...
|
|
| getRecipientRows (int $recipient_guid, string $delivery_interval, int $timestamp=null, int $max_results=0) |
| Get all the rows in the queue for a given recipient. More...
|
|
| getNextRecipientGUID (string $delivery_interval, int $timestamp=null) |
| Fetch the GUID of the next recipient to process. More...
|
|
| deleteRow (int $id) |
| Remove a queue items from the database. More...
|
|
| deleteRecipientRows (int $recipient_guid, string $delivery_interval, int $timestamp=null, int $max_id=0) |
| Delete all the queue items from the database for the given recipient and interval. More...
|
|
| deleteAllRecipientRows (int $recipient_guid) |
| Deletes all the queue items from the database for the given recipient. More...
|
|
| updateRecipientInterval (int $recipient_guid, string $delivery_interval) |
| Update the queued notifications for the recipient to a new delivery interval. More...
|
|
| rowToRecord (\stdClass $row) |
| Convert a database row to a manageable object. More...
|
|
Interfaces with the database to perform operations on the delayed_email_queue table.
Definition at line 15 of file DelayedEmailQueueTable.php.
Elgg\Database\DelayedEmailQueueTable::__construct |
( |
Database |
$db | ) |
|
Elgg\Database\DelayedEmailQueueTable::deleteAllRecipientRows |
( |
int |
$recipient_guid | ) |
|
Deletes all the queue items from the database for the given recipient.
- Parameters
-
int | $recipient_guid | the recipient |
- Returns
- int number of deleted rows
Definition at line 168 of file DelayedEmailQueueTable.php.
Elgg\Database\DelayedEmailQueueTable::deleteRecipientRows |
( |
int |
$recipient_guid, |
|
|
string |
$delivery_interval, |
|
|
int |
$timestamp = null , |
|
|
int |
$max_id = 0 |
|
) |
| |
Delete all the queue items from the database for the given recipient and interval.
- Parameters
-
int | $recipient_guid | the recipient |
string | $delivery_interval | the interval for the recipient |
null | int | $timestamp | (optional) all queue items before time (default: now) |
int | $max_id | (optional) the max row ID to remove (this includes the given row ID) |
- Returns
- int number of deleted rows
Definition at line 146 of file DelayedEmailQueueTable.php.
Elgg\Database\DelayedEmailQueueTable::deleteRow |
( |
int |
$id | ) |
|
Elgg\Database\DelayedEmailQueueTable::getNextRecipientGUID |
( |
string |
$delivery_interval, |
|
|
int |
$timestamp = null |
|
) |
| |
Fetch the GUID of the next recipient to process.
- Parameters
-
string | $delivery_interval | the delivery interval to get |
null | int | $timestamp | (optional) based on queue items before time (default: now) |
- Returns
- null|int
Definition at line 105 of file DelayedEmailQueueTable.php.
Elgg\Database\DelayedEmailQueueTable::getRecipientRows |
( |
int |
$recipient_guid, |
|
|
string |
$delivery_interval, |
|
|
int |
$timestamp = null , |
|
|
int |
$max_results = 0 |
|
) |
| |
Get all the rows in the queue for a given recipient.
- Parameters
-
int | $recipient_guid | the recipient |
string | $delivery_interval | the interval for the recipient |
null | int | $timestamp | (optional) all queue items before time (default: now) |
int | $max_results | (optional) maximum number of rows to return |
- Returns
- DatabaseRecord[] database rows
Definition at line 81 of file DelayedEmailQueueTable.php.
Elgg\Database\DelayedEmailQueueTable::getRow |
( |
int |
$id | ) |
|
Elgg\Database\DelayedEmailQueueTable::queueEmail |
( |
int |
$recipient_guid, |
|
|
string |
$delivery_interval, |
|
|
|
$item |
|
) |
| |
Insert a delayed email into the queue.
- Parameters
-
int | $recipient_guid | the recipient of the email |
string | $delivery_interval | the desired interval of the recipient |
mixed | $item | the email to queue |
- Returns
- bool
Definition at line 44 of file DelayedEmailQueueTable.php.
Elgg\Database\DelayedEmailQueueTable::rowToRecord |
( |
\stdClass |
$row | ) |
|
Convert a database row to a manageable object.
- Parameters
-
\stdClass | $row | the database record |
- Returns
- DatabaseRecord
Definition at line 198 of file DelayedEmailQueueTable.php.
Elgg\Database\DelayedEmailQueueTable::updateRecipientInterval |
( |
int |
$recipient_guid, |
|
|
string |
$delivery_interval |
|
) |
| |
Update the queued notifications for the recipient to a new delivery interval.
- Parameters
-
int | $recipient_guid | the recipient |
string | $delivery_interval | the new delivery interval |
- Returns
- bool
Definition at line 183 of file DelayedEmailQueueTable.php.
Database Elgg\Database\DelayedEmailQueueTable::$db |
|
protected |
const Elgg\Database\DelayedEmailQueueTable::TABLE_NAME = 'delayed_email_queue' |
The documentation for this class was generated from the following file: