PHP Class Swift_Message

Author: Chris Corbyn
Inheritance: extends Swift_Mime_SimpleMessage
Exibir arquivo Open project: swiftmailer/swiftmailer Class Usage Examples

Public Methods

Method Description
__clone ( ) Clone Message Signers.
__construct ( string $subject = null, string $body = null, string $contentType = null, string $charset = null ) Create a new Message.
__wakeup ( )
addPart ( string | Swift_OutputByteStream $body, string $contentType = null, string $charset = null ) : Swift_Mime_SimpleMessage Add a MimePart to this Message.
attachSigner ( Swift_Signer $signer ) : Swift_Message Detach a signature handler from a message.
detachSigner ( Swift_Signer $signer ) : Swift_Message Attach a new signature handler to the message.
toByteStream ( Swift_InputByteStream $is ) Write this message to a {@link Swift_InputByteStream}.
toString ( ) : string Get this message as a complete string.

Protected Methods

Method Description
doSign ( ) loops through signers and apply the signatures.
restoreHeaders ( ) Remove or restore altered headers.
restoreMessage ( ) Restore message body.
saveHeaders ( array $altered ) save the original headers.
saveMessage ( ) save the message before any signature is applied.

Method Details

__clone() public method

Clone Message Signers.
See also: Swift_Mime_SimpleMimeEntity::__clone()
public __clone ( )

__construct() public method

Details may be optionally passed into the constructor.
public __construct ( string $subject = null, string $body = null, string $contentType = null, string $charset = null )
$subject string
$body string
$contentType string
$charset string

__wakeup() public method

public __wakeup ( )

addPart() public method

Add a MimePart to this Message.
public addPart ( string | Swift_OutputByteStream $body, string $contentType = null, string $charset = null ) : Swift_Mime_SimpleMessage
$body string | Swift_OutputByteStream
$contentType string
$charset string
return Swift_Mime_SimpleMessage

attachSigner() public method

Detach a signature handler from a message.
public attachSigner ( Swift_Signer $signer ) : Swift_Message
$signer Swift_Signer
return Swift_Message

detachSigner() public method

Attach a new signature handler to the message.
public detachSigner ( Swift_Signer $signer ) : Swift_Message
$signer Swift_Signer
return Swift_Message

doSign() protected method

loops through signers and apply the signatures.
protected doSign ( )

restoreHeaders() protected method

Remove or restore altered headers.
protected restoreHeaders ( )

restoreMessage() protected method

Restore message body.
protected restoreMessage ( )

saveHeaders() protected method

save the original headers.
protected saveHeaders ( array $altered )
$altered array

saveMessage() protected method

save the message before any signature is applied.
protected saveMessage ( )

toByteStream() public method

Write this message to a {@link Swift_InputByteStream}.
public toByteStream ( Swift_InputByteStream $is )
$is Swift_InputByteStream

toString() public method

Get this message as a complete string.
public toString ( ) : string
return string