Zend Framework
3.0
|
Public Member Functions | |
isValid () | |
Is the message valid? | |
setEncoding ($encoding) | |
Set the message encoding. | |
getEncoding () | |
Get the message encoding. | |
setHeaders (Headers $headers) | |
Compose headers. | |
getHeaders () | |
Access headers collection. | |
setFrom ($emailOrAddressList, $name=null) | |
Set (overwrite) From addresses. | |
addFrom ($emailOrAddressOrList, $name=null) | |
Add a "From" address. | |
getFrom () | |
Retrieve list of From senders. | |
setTo ($emailOrAddressList, $name=null) | |
Overwrite the address list in the To recipients. | |
addTo ($emailOrAddressOrList, $name=null) | |
Add one or more addresses to the To recipients. | |
getTo () | |
Access the address list of the To header. | |
setCc ($emailOrAddressList, $name=null) | |
Set (overwrite) CC addresses. | |
addCc ($emailOrAddressOrList, $name=null) | |
Add a "Cc" address. | |
getCc () | |
Retrieve list of CC recipients. | |
setBcc ($emailOrAddressList, $name=null) | |
Set (overwrite) BCC addresses. | |
addBcc ($emailOrAddressOrList, $name=null) | |
Add a "Bcc" address. | |
getBcc () | |
Retrieve list of BCC recipients. | |
setReplyTo ($emailOrAddressList, $name=null) | |
Overwrite the address list in the Reply-To recipients. | |
addReplyTo ($emailOrAddressOrList, $name=null) | |
Add one or more addresses to the Reply-To recipients. | |
getReplyTo () | |
Access the address list of the Reply-To header. | |
setSender ($emailOrAddress, $name=null) | |
setSender | |
getSender () | |
Retrieve the sender address, if any. | |
setSubject ($subject) | |
Set the message subject header value. | |
getSubject () | |
Get the message subject header value. | |
setBody ($body) | |
Set the message body. | |
getBody () | |
Return the currently set message body. | |
getBodyText () | |
Get the string-serialized message body text. | |
toString () | |
Serialize to string. | |
Static Public Member Functions | |
static | fromString ($rawMessage) |
Instantiate from raw message string. | |
Protected Member Functions | |
getHeaderByName ($headerName, $headerClass) | |
Retrieve a header by name. | |
clearHeaderByName ($headerName) | |
Clear a header by name. | |
getAddressListFromHeader ($headerName, $headerClass) | |
Retrieve the AddressList from a named header. | |
updateAddressList (AddressList $addressList, $emailOrAddressOrList, $name, $callingMethod) | |
Update an address list. | |
Protected Attributes | |
$body | |
$headers | |
$encoding = 'ASCII' | |
addBcc | ( | $emailOrAddressOrList, | |
$name = null |
|||
) |
Add a "Bcc" address.
string | Address | array | AddressList | Traversable | $emailOrAddressOrList | |
string | null | $name |
addCc | ( | $emailOrAddressOrList, | |
$name = null |
|||
) |
Add a "Cc" address.
string | Address | array | AddressList | Traversable | $emailOrAddressOrList | |
string | null | $name |
addFrom | ( | $emailOrAddressOrList, | |
$name = null |
|||
) |
Add a "From" address.
string | Address | array | AddressList | Traversable | $emailOrAddressOrList | |
string | null | $name |
addReplyTo | ( | $emailOrAddressOrList, | |
$name = null |
|||
) |
Add one or more addresses to the Reply-To recipients.
Appends to the list.
string | Address\AddressInterface | array | AddressList | Traversable | $emailOrAddressOrList | |
null | string | $name |
addTo | ( | $emailOrAddressOrList, | |
$name = null |
|||
) |
Add one or more addresses to the To recipients.
Appends to the list.
string | Address\AddressInterface | array | AddressList | Traversable | $emailOrAddressOrList | |
null | string | $name |
|
protected |
Clear a header by name.
string | $headerName |
|
static |
|
protected |
Retrieve the AddressList from a named header.
Used with To, From, Cc, Bcc, and ReplyTo headers. If the header does not exist, instantiates it.
string | $headerName | |
string | $headerClass |
Exception\DomainException |
getBcc | ( | ) |
Retrieve list of BCC recipients.
getBody | ( | ) |
Return the currently set message body.
getBodyText | ( | ) |
Get the string-serialized message body text.
getCc | ( | ) |
Retrieve list of CC recipients.
getEncoding | ( | ) |
Get the message encoding.
getFrom | ( | ) |
Retrieve list of From senders.
|
protected |
Retrieve a header by name.
If not found, instantiates one based on $headerClass.
string | $headerName | |
string | $headerClass |
getHeaders | ( | ) |
getReplyTo | ( | ) |
Access the address list of the Reply-To header.
getSender | ( | ) |
Retrieve the sender address, if any.
getSubject | ( | ) |
Get the message subject header value.
getTo | ( | ) |
Access the address list of the To header.
isValid | ( | ) |
Is the message valid?
If we don't any From addresses, we're invalid, according to RFC2822.
setBcc | ( | $emailOrAddressList, | |
$name = null |
|||
) |
Set (overwrite) BCC addresses.
string | Address\AddressInterface | array | AddressList | Traversable | $emailOrAddressList | |
string | null | $name |
setBody | ( | $body | ) |
Set the message body.
null | string | \Zend\Mime\Message | object | $body |
Exception\InvalidArgumentException |
setCc | ( | $emailOrAddressList, | |
$name = null |
|||
) |
Set (overwrite) CC addresses.
string | Address\AddressInterface | array | AddressList | Traversable | $emailOrAddressList | |
string | null | $name |
setEncoding | ( | $encoding | ) |
setFrom | ( | $emailOrAddressList, | |
$name = null |
|||
) |
Set (overwrite) From addresses.
string | Address\AddressInterface | array | AddressList | Traversable | $emailOrAddressList | |
string | null | $name |
setReplyTo | ( | $emailOrAddressList, | |
$name = null |
|||
) |
Overwrite the address list in the Reply-To recipients.
string | Address\AddressInterface | array | AddressList | Traversable | $emailOrAddressList | |
null | string | $name |
setSender | ( | $emailOrAddress, | |
$name = null |
|||
) |
setSubject | ( | $subject | ) |
setTo | ( | $emailOrAddressList, | |
$name = null |
|||
) |
Overwrite the address list in the To recipients.
string | Address\AddressInterface | array | AddressList | Traversable | $emailOrAddressList | |
null | string | $name |
toString | ( | ) |
Serialize to string.
|
protected |
Update an address list.
Proxied to this from addFrom, addTo, addCc, addBcc, and addReplyTo.
AddressList | $addressList | |
string | Address\AddressInterface | array | AddressList | Traversable | $emailOrAddressOrList | |
null | string | $name | |
string | $callingMethod |
Exception\InvalidArgumentException |
|
protected |
|
protected |
|
protected |