Code Coverage |
||||||||||
Lines |
Functions and Methods |
Classes and Traits |
||||||||
| Total | n/a |
0 / 0 |
n/a |
0 / 0 |
CRAP | n/a |
0 / 0 |
|||
| 1 | <?php |
| 2 | /** |
| 3 | * Pop PHP Framework (https://www.popphp.org/) |
| 4 | * |
| 5 | * @link https://github.com/popphp/popphp-framework |
| 6 | * @author Nick Sagona, III <dev@noladev.com> |
| 7 | * @copyright Copyright (c) 2009-2026 NOLA Interactive, LLC. |
| 8 | * @license https://www.popphp.org/license New BSD License |
| 9 | */ |
| 10 | |
| 11 | /** |
| 12 | * @namespace |
| 13 | */ |
| 14 | namespace Pop\Mail\Client; |
| 15 | |
| 16 | use Pop\Http; |
| 17 | |
| 18 | /** |
| 19 | * Http client interface |
| 20 | * |
| 21 | * @category Pop |
| 22 | * @package Pop\Mail |
| 23 | * @author Nick Sagona, III <dev@noladev.com> |
| 24 | * @copyright Copyright (c) 2009-2026 NOLA Interactive, LLC. |
| 25 | * @license https://www.popphp.org/license New BSD License |
| 26 | * @version 4.0.7 |
| 27 | */ |
| 28 | interface HttpClientInterface |
| 29 | { |
| 30 | |
| 31 | /** |
| 32 | * Get messages |
| 33 | * |
| 34 | * @param string $folder |
| 35 | * @param array $search |
| 36 | * @param int $limit |
| 37 | * @throws Exception|Http\Exception|Http\Client\Exception|Http\Client\Handler\Exception |
| 38 | * @return mixed |
| 39 | */ |
| 40 | public function getMessages(string $folder = 'Inbox', array $search = [], int $limit = 10): mixed; |
| 41 | |
| 42 | /** |
| 43 | * Get messages |
| 44 | * |
| 45 | * @param string $messageId |
| 46 | * @param bool $raw |
| 47 | * @throws Exception|Http\Exception|Http\Client\Exception|Http\Client\Handler\Exception |
| 48 | * @return mixed |
| 49 | */ |
| 50 | public function getMessage(string $messageId, bool $raw = false): mixed; |
| 51 | |
| 52 | /** |
| 53 | * Get message attachments |
| 54 | * |
| 55 | * @param string $messageId |
| 56 | * @param string $folder |
| 57 | * @throws Exception|Http\Exception|Http\Client\Exception|Http\Client\Handler\Exception |
| 58 | * @return mixed |
| 59 | */ |
| 60 | public function getAttachments(string $messageId, string $folder = 'Inbox'): mixed; |
| 61 | |
| 62 | /** |
| 63 | * Get message attachment |
| 64 | * |
| 65 | * @param string $messageId |
| 66 | * @param string $attachmentId |
| 67 | * @param string $folder |
| 68 | * @throws Exception|Http\Exception|Http\Client\Exception|Http\Client\Handler\Exception |
| 69 | * @return mixed |
| 70 | */ |
| 71 | public function getAttachment(string $messageId, string $attachmentId, string $folder = 'Inbox'): mixed; |
| 72 | |
| 73 | /** |
| 74 | * Mark message as read |
| 75 | * |
| 76 | * @param string $messageId |
| 77 | * @param bool $isRead |
| 78 | * @throws Exception|Http\Exception|Http\Client\Exception|Http\Client\Handler\Exception |
| 79 | * @return HttpClientInterface |
| 80 | */ |
| 81 | public function markAsRead(string $messageId, bool $isRead = true): HttpClientInterface; |
| 82 | |
| 83 | /** |
| 84 | * Mark message as unread |
| 85 | * |
| 86 | * @param string $messageId |
| 87 | * @throws Exception|Http\Exception|Http\Client\Exception|Http\Client\Handler\Exception |
| 88 | * @return HttpClientInterface |
| 89 | */ |
| 90 | public function markAsUnread(string $messageId): HttpClientInterface; |
| 91 | |
| 92 | } |