package Default

 Methods

append a new message to mail storage

appendMessage(string|\Zend\Mail\Message|\Zend\Mime\Message $message, null|string|\Zend\Mail\Storage\Folder $folder = null, null|array $flags = null

Parameters

$message

string\Zend\Mail\Message\Zend\Mime\Message

message as string or instance of message class

$folder

nullstring\Zend\Mail\Storage\Folder

folder for new message, else current folder is taken

$flags

nullarray

set flags for new message, else a default set is used

Exceptions

\Zend\Mail\Storage\Exception\ExceptionInterface

copy an existing message

copyMessage(integer $id, string|\Zend\Mail\Storage\Folder $folder) 

Parameters

$id

integer

number of message

$folder

string\Zend\Mail\Storage\Folder

name or instance of target folder

Exceptions

\Zend\Mail\Storage\Exception\ExceptionInterface

create a new folder

createFolder(string $name, string|\Zend\Mail\Storage\Folder $parentFolder = null

This method also creates parent folders if necessary. Some mail storages may restrict, which folder may be used as parent or which chars may be used in the folder name

Parameters

$name

string

global name of folder, local name if $parentFolder is set

$parentFolder

string\Zend\Mail\Storage\Folder

parent folder for new folder, else root folder is parent

Exceptions

\Zend\Mail\Storage\Exception\ExceptionInterface

move an existing message

moveMessage(integer $id, string|\Zend\Mail\Storage\Folder $folder) 

Parameters

$id

integer

number of message

$folder

string\Zend\Mail\Storage\Folder

name or instance of target folder

Exceptions

\Zend\Mail\Storage\Exception\ExceptionInterface

remove a folder

removeFolder(string|\Zend\Mail\Storage\Folder $name) 

Parameters

$name

string\Zend\Mail\Storage\Folder

name or instance of folder

Exceptions

\Zend\Mail\Storage\Exception\ExceptionInterface

rename and/or move folder

renameFolder(string|\Zend\Mail\Storage\Folder $oldName, string $newName) 

The new name has the same restrictions as in createFolder()

Parameters

$oldName

string\Zend\Mail\Storage\Folder

name or instance of folder

$newName

string

new global name of folder

Exceptions

\Zend\Mail\Storage\Exception\ExceptionInterface

set flags for message

setFlags(integer $id, array $flags) 

NOTE: this method can't set the recent flag.

Parameters

$id

integer

number of message

$flags

array

new flags for message

Exceptions

\Zend\Mail\Storage\Exception\ExceptionInterface