mail service improvements

This commit is contained in:
root
2025-12-28 05:25:39 -05:00
parent 7449ebca75
commit 74f9278749
4 changed files with 494 additions and 1 deletions

View File

@@ -0,0 +1,98 @@
<?php
declare(strict_types=1);
/**
* SPDX-FileCopyrightText: Sebastian Krupinski <krupinski01@gmail.com>
* SPDX-License-Identifier: AGPL-3.0-or-later
*/
namespace KTXF\Mail\Collection;
/**
* Mail Collection Mutable Interface
*
* Interface for creating and modifying mail collections with fluent setters.
*
* @since 2025.05.01
*/
interface ICollectionMutable extends ICollectionBase {
/**
* Sets the parent collection identifier
*
* @since 2025.05.01
*
* @param string|int|null $in Parent collection ID or null for root
*
* @return self
*/
public function setIn(string|int|null $in): self;
/**
* Sets the collection identifier
*
* @since 2025.05.01
*
* @param string|int $id
*
* @return self
*/
public function setId(string|int $id): self;
/**
* Sets the collection label/name
*
* @since 2025.05.01
*
* @param string $label
*
* @return self
*/
public function setLabel(string $label): self;
/**
* Sets the collection role
*
* @since 2025.05.01
*
* @param CollectionRoles $role
*
* @return self
*/
public function setRole(CollectionRoles $role): self;
/**
* Sets the total message count
*
* @since 2025.05.01
*
* @param int|null $total
*
* @return self
*/
public function setTotal(?int $total): self;
/**
* Sets the unread message count
*
* @since 2025.05.01
*
* @param int|null $unread
*
* @return self
*/
public function setUnread(?int $unread): self;
/**
* Sets the collection signature/sync token
*
* @since 2025.05.01
*
* @param string|null $signature
*
* @return self
*/
public function setSignature(?string $signature): self;
}