Documentation

Horde_ActiveSync_Mime
in package

This class provides some base functionality for dealing with MIME objects in the context of ActiveSync requests.

Tags
license

http://www.horde.org/licenses/gpl GPLv2

copyright

2012-2020 Horde LLC (http://www.horde.org)

author

Michael J Rubinsky mrubinsk@horde.org

since
2.19.0

Table of Contents

$_base  : Horde_Mime_Part
The composited mime part.
$_hasAttachments  : bool
Local cache of hasAttachments data.
__call()  : mixed
Delegate calls to the composed MIME object.
__construct()  : mixed
Cont'r
__destruct()  : mixed
__get()  : mixed
Accessor
alterPart()  : mixed
Replace the specified MimePart with the provided part.
findBody()  : mixed
Finds the main "body" text part (if any) in a message. "Body" data is the first text part under this part. Considers only body data that should be displayed as the main body on an EAS client. I.e., this ignores any text parts contained withing "attachment" parts such as messages/rfc822 attachments.
hasAttachments()  : bool
Return the hasAttachments flag
hasiCalendar()  : mixed
Return the MIME part of the iCalendar attachment, if available.
isAttachment()  : bool
Determines if a MIME type is an attachment.
isEncrypted()  : bool
Return the S/MIME encryption status of this message.
isSigned()  : bool
Return the S/MIME status of this message (RFC2633)

Properties

$_base

The composited mime part.

protected Horde_Mime_Part $_base

$_hasAttachments

Local cache of hasAttachments data.

protected bool $_hasAttachments

Methods

__call()

Delegate calls to the composed MIME object.

public __call(string $method, array<string|int, mixed> $params) : mixed
Parameters
$method : string

The method name.

$params : array<string|int, mixed>

The parameters.

Return values
mixed

__construct()

Cont'r

public __construct(Horde_Mime_Part $mime) : mixed
Parameters
$mime : Horde_Mime_Part

The mime data.

Return values
mixed

__destruct()

public __destruct() : mixed
Return values
mixed

__get()

Accessor

public __get(string $property) : mixed
Parameters
$property : string

The property name.

Return values
mixed

alterPart()

Replace the specified MimePart with the provided part.

public alterPart(string $id, Horde_Mime_Part $newPart) : mixed
Parameters
$id : string

The part id of the part to replace.

$newPart : Horde_Mime_Part

The new mimePart.

Return values
mixed

findBody()

Finds the main "body" text part (if any) in a message. "Body" data is the first text part under this part. Considers only body data that should be displayed as the main body on an EAS client. I.e., this ignores any text parts contained withing "attachment" parts such as messages/rfc822 attachments.

public findBody([string $subtype = null ]) : mixed
Parameters
$subtype : string = null

Specifically search for this subtype.

Return values
mixed

The MIME ID of the main body part, or null if a body part is not found.

hasAttachments()

Return the hasAttachments flag

public hasAttachments() : bool
Return values
bool

hasiCalendar()

Return the MIME part of the iCalendar attachment, if available.

public hasiCalendar() : mixed
Return values
mixed

The mime id of an iCalendar part, if present. Otherwise false.

isAttachment()

Determines if a MIME type is an attachment.

public isAttachment(string $id, string $mime_type) : bool

For our purposes, an attachment is any MIME part that can be downloaded by itself (i.e. all the data needed to view the part is contained within the download data).

Parameters
$id : string

The MIME Id for the part we are checking.

$mime_type : string

The MIME type.

Tags
todo

Pass a single mime part as parameter.

Return values
bool

True if an attachment.

isEncrypted()

Return the S/MIME encryption status of this message.

public isEncrypted([Horde_Mime_Part $mime = null ]) : bool
Parameters
$mime : Horde_Mime_Part = null
Tags
since
2.20.0
todo

For 3.0, combine into one method with self::isSigned() and return a bitmask result.

Return values
bool

True if message is S/MIME encrypted, otherwise false.

isSigned()

Return the S/MIME status of this message (RFC2633)

public isSigned([Horde_Mime_Part $mime = null ]) : bool
Parameters
$mime : Horde_Mime_Part = null
Return values
bool

True if message is S/MIME signed, otherwise false.

Search results