generated from Nodarx/template
feat: harmonize mailbox messages
Signed-off-by: Sebastian Krupinski <krupinski01@gmail.com>
This commit is contained in:
@@ -22,6 +22,8 @@ final class Mailbox
|
||||
private readonly int $recent = 0,
|
||||
private readonly array $flags = [],
|
||||
private readonly bool $readOnly = true,
|
||||
private readonly ?int $uidNext = null,
|
||||
private readonly ?int $highestModSeq = null,
|
||||
) {}
|
||||
|
||||
public function fromStatus(MailboxStatusResult $status): self
|
||||
@@ -38,6 +40,8 @@ final class Mailbox
|
||||
$this->recent,
|
||||
$this->flags,
|
||||
$this->readOnly,
|
||||
$items['UIDNEXT'] ?? $this->uidNext,
|
||||
$items['HIGHESTMODSEQ'] ?? $this->highestModSeq,
|
||||
);
|
||||
}
|
||||
|
||||
@@ -64,6 +68,16 @@ final class Mailbox
|
||||
return $this->uidValidity;
|
||||
}
|
||||
|
||||
public function uidNext(): ?int
|
||||
{
|
||||
return $this->uidNext;
|
||||
}
|
||||
|
||||
public function highestModSeq(): ?int
|
||||
{
|
||||
return $this->highestModSeq;
|
||||
}
|
||||
|
||||
public function messages(): int
|
||||
{
|
||||
return $this->messages;
|
||||
|
||||
Reference in New Issue
Block a user