Method | Description | |
---|---|---|
__construct ( resource $connection, integer $uid ) | Creates an instance. | |
decodeBody ( string $body, string $encoding ) : string | Decodes body. | |
getAllRelatedParts ( string $pid ) : array | Returns all related parts. | |
getAttachments ( ) : array | Returns a list of attachments. | |
getBody ( string $pid = '1', integer $mode = self::BODY, string $mimeType = 'text/html', integer $attempt = 1 ) : array | Returns body of the given part. | |
getHeaders ( string $pid = null ) : array | Returns headers. | |
getInlines ( ) : array | Returns a list of part Ids of inline parts. | |
getMime ( array $types ) : array | Returns a list of part Ids of given types. | |
getMimeExcept ( array $exceptTypes ) : array | Returns a list of part Ids of all parts except for the given types. | |
getRelatedParts ( string $pid, array $types, boolean $all = false ) : array | Returns related parts. | |
parseBody ( string $pid = null, string $mimeType = 'text/html', boolean $alternative = true, boolean $all = false ) | Parses message body. |
Method | Description | |
---|---|---|
addPart ( integer $structureNo, string $partType ) | Adds a part to the list. | |
checkIfParsed ( ) | Parses a message if not already parsed. | |
convertToUtf8 ( string $string, string $charset = '' ) : string | Converts a string from various encodings to UTF-8. | |
decodeFilename ( string $filename ) : string | Decodes attachment's name. | |
decodeMimeHeader ( string $header ) : string | Decodes given header. | |
getDefaultPid ( string $mimeType = 'text/html', integer $attempt = 1 ) : string | Returns default part's Id. | |
getMajorMimeType ( integer $mimetypeNo ) : string | Returns textual representation of the major mime-type. | |
getMultipartPid ( string $pid, string $mimeType, string $lookFor ) : string | Returns a part Id. | |
getRawHeaders ( string $pid = null ) : string | Returns raw headers. | |
isMultipart ( string $subtype ) : boolean | Returns if the message is multipart/subtype. | |
isParentAlternative ( integer $partNo ) : boolean | Returns if the parent is multipart/alternative type. | |
isPartMultipart ( integer $partNo, string $subtype ) : boolean | Returns if the given part is is multipart/subtype. | |
parseMultiparts ( string $pid, string $mimeType, string $lookFor = 'all', integer $pidAdd = 1, boolean $getAlternative = true ) | Parses multiple parts. | |
setStructure ( array $subparts = null, string $parentPartId = null, boolean $skipPart = false, boolean $lastWasSigned = false ) | Creates message structure. |
public __construct ( resource $connection, integer $uid ) | ||
$connection | resource | IMAP folder connection. |
$uid | integer | Message Id |
public getAllRelatedParts ( string $pid ) : array | ||
$pid | string | Part Id |
return | array |
public getAttachments ( ) : array | ||
return | array |
public getHeaders ( string $pid = null ) : array | ||
$pid | string | Part Id |
return | array |
public getInlines ( ) : array | ||
return | array |
public getMimeExcept ( array $exceptTypes ) : array | ||
$exceptTypes | array | Ignored part types |
return | array |