FakeFolder
class FakeFolder implements FolderInterface (View source)
Traits
Methods
Constructor.
Get the folder's mailbox.
Get the folder path.
Get the folder flags.
Get the folder delimiter.
Get the folder name.
Begin querying for messages.
Begin idling on the current folder for the given timeout in seconds.
Begin polling for new messages at the given frequency in seconds.
Move or rename the current folder.
Select the current folder.
Get the folder's status.
Examine the current folder and get detailed status information.
Expunge the mailbox and return the expunged message sequence numbers.
Get the folder's quotas.
Delete the current folder.
Set the folder's path.
Set the folder's flags.
Set the folder's messages.
Get the folder's messages.
Set the folder's delimiter.
Details
protected bool
isSameFolder(FolderInterface $a, FolderInterface $b)
Determine if two folders are the same.
__construct(string $path = '', array $flags = [], array $messages = [], string $delimiter = '/', MailboxInterface|null $mailbox = null)
Constructor.
MailboxInterface
mailbox()
Get the folder's mailbox.
string
path()
Get the folder path.
array
flags()
Get the folder flags.
string
delimiter()
Get the folder delimiter.
string
name()
Get the folder name.
bool
is(FolderInterface $folder)
Determine if the current folder is the same as the given.
MessageQueryInterface
messages()
Begin querying for messages.
void
idle(callable $callback, callable|null $query = null, callable|int $timeout = 300)
Begin idling on the current folder for the given timeout in seconds.
void
poll(callable $callback, callable|null $query = null, callable|int $frequency = 60)
Begin polling for new messages at the given frequency in seconds.
void
move(string $newPath)
Move or rename the current folder.
void
select(bool $force = false)
Select the current folder.
array
status()
Get the folder's status.
array
examine()
Examine the current folder and get detailed status information.
array
expunge()
Expunge the mailbox and return the expunged message sequence numbers.
array
quota()
Get the folder's quotas.
void
delete()
Delete the current folder.
FakeFolder
setPath(string $path)
Set the folder's path.
FakeFolder
setFlags(array $flags)
Set the folder's flags.
FakeFolder
setMailbox(MailboxInterface $mailbox)
Set the folder's mailbox.
FakeFolder
setMessages(array $messages)
Set the folder's messages.
array
getMessages()
Get the folder's messages.
void
addMessage(FakeMessage $message)
Add a message to the folder.
FakeFolder
setDelimiter(string $delimiter = '/')
Set the folder's delimiter.