TYPO3  7.6
Public Member Functions | Public Attributes | List of all members
Swift_Mime_MimeEntity Interface Reference
Inheritance diagram for Swift_Mime_MimeEntity:
Swift_Mime_CharsetObserver Swift_Mime_EncodingObserver Swift_Mime_Message Swift_Mime_SimpleMimeEntity Swift_Mime_SimpleMessage Swift_Mime_Attachment Swift_Mime_MimePart Swift_Message Swift_Attachment Swift_Mime_EmbeddedFile Swift_Mime_SimpleMessage Swift_MimePart Swift_SignedMessage MailMessage Swift_EmbeddedFile Swift_Message Swift_Image Swift_SignedMessage MailMessage

Public Member Functions

 getNestingLevel ()
 
 getContentType ()
 
 getId ()
 
 getChildren ()
 
 setChildren (array $children)
 
 getHeaders ()
 
 getBody ()
 
 setBody ($body, $contentType=null)
 
 toString ()
 
 toByteStream (Swift_InputByteStream $is)
 
- Public Member Functions inherited from Swift_Mime_CharsetObserver
 charsetChanged ($charset)
 
- Public Member Functions inherited from Swift_Mime_EncodingObserver
 encoderChanged (Swift_Mime_ContentEncoder $encoder)
 

Public Attributes

const LEVEL_TOP = 16
 
const LEVEL_MIXED = 256
 
const LEVEL_ALTERNATIVE = 4096
 
const LEVEL_RELATED = 65536
 

Detailed Description

A MIME entity, such as an attachment.

Author
Chris Corbyn

Definition at line 16 of file MimeEntity.php.

Member Function Documentation

getBody ( )

Get the body content of this entity as a string.

Returns NULL if no body has been set.

Returns
string|null

Implemented in Swift_Mime_SimpleMimeEntity.

Referenced by Swift_Mime_SimpleMessage\_becomeMimePart(), Swift_Message\saveMessage(), Swift_Mime_SimpleMessage\toByteStream(), and Swift_Mime_SimpleMessage\toString().

getChildren ( )
getContentType ( )

Get the qualified content-type of this mime entity.

Returns
string

Implemented in Swift_Mime_SimpleMimeEntity.

getHeaders ( )
getId ( )

Returns a unique ID for this entity.

For most entities this will likely be the Content-ID, though it has no explicit semantic meaning and can be considered an identifier for programming logic purposes.

If a Content-ID header is present, this value SHOULD match the value of the header.

Returns
string

Implemented in Swift_Mime_SimpleMimeEntity.

Referenced by Swift_Mime_SimpleMessage\__construct().

getNestingLevel ( )

Get the level at which this entity shall be nested in final document.

The lower the value, the more outermost the entity will be nested.

See Also
LEVEL_TOP, LEVEL_MIXED, LEVEL_RELATED, LEVEL_ALTERNATIVE
Returns
int

Implemented in Swift_Mime_MimePart, Swift_Mime_SimpleMimeEntity, Swift_Mime_SimpleMessage, Swift_Mime_Attachment, and Swift_Mime_EmbeddedFile.

setBody (   $body,
  $contentType = null 
)

Set the body content of this entity as a string.

Parameters
string$body
string$contentTypeoptional

Implemented in Swift_Mime_SimpleMimeEntity.

Referenced by Swift_Plugins_DecoratorPlugin\_restoreMessage().

setChildren ( array  $children)

Set all children nested inside this entity.

This includes grandchildren.

Parameters
Swift_Mime_MimeEntity[]$children

Referenced by Swift_Mime_SimpleMessage\attach(), Swift_Mime_SimpleMessage\detach(), Swift_Message\restoreMessage(), Swift_Message\saveMessage(), Swift_Mime_SimpleMessage\toByteStream(), and Swift_Mime_SimpleMessage\toString().

toByteStream ( Swift_InputByteStream  $is)
toString ( )

Get this entire entity in its string form.

Returns
string

Implemented in Swift_Mime_SimpleMessage, Swift_Mime_SimpleMimeEntity, and Swift_Message.

Referenced by MboxTransport\send(), and Swift_Transport_MailTransport\send().

Member Data Documentation

const LEVEL_ALTERNATIVE = 4096

An entity which nests with the same precedence as a mime part

Definition at line 25 of file MimeEntity.php.

const LEVEL_MIXED = 256

An entity which nests with the same precedence as an attachment

Definition at line 22 of file MimeEntity.php.

const LEVEL_RELATED = 65536

An entity which nests with the same precedence as embedded content

Definition at line 28 of file MimeEntity.php.

const LEVEL_TOP = 16

Main message document; there can only be one of these

Definition at line 19 of file MimeEntity.php.