Account Suspended
Account Suspended
This Account has been suspended.
Contact your hosting provider for more information.
 All Data Structures Functions Variables Pages
Public Member Functions | Data Fields | Protected Member Functions | Protected Attributes
ZurmoImap Class Reference
Inheritance diagram for ZurmoImap:
ZurmoBounce

Public Member Functions

 init ()
 
 loadInboundSettings ()
 
 setInboundSettings ()
 
 connect ()
 
 getMessageBoxStatsDetailed ()
 
 resolveMessageBoxStats ()
 
 getMessages ($searchCriteria= 'ALL', $messagesSinceTimestamp=0, $limit=null)
 
 expungeMessages ()
 
 deleteMessages ($expunge=false)
 
 deleteMessage ($msgUid)
 

Data Fields

 $imapHost
 
 $imapUsername
 
 $imapPassword
 
 $imapPort = 143
 
 $imapSSL = false
 
 $imapFolder = 'INBOX'
 

Protected Member Functions

 getMessage ($messageNumber, $mailHeaderInfo)
 
 getAttachments ($structure, $messageId)
 
 getMessageUId ($msgNo)
 
 mailCount ($query)
 
 getMimeType ($structure)
 
 getPart ($msgNumber, $mimeType, $structure=null, $partNumber=false)
 
 resolveContentFromStructure ($content, $structure)
 
 resolvePasswordKeyName ()
 
 resolveAttributeNameFromSettingsKey ($key)
 
 resolveAndParseMessageHeaders ($messageNumber)
 

Protected Attributes

 $imapStream
 
 $settingsToLoad
 

Detailed Description

Helper class to manage access to IMAP server

Definition at line 40 of file ZurmoImap.php.

Member Function Documentation

init ( )

Called once per page load, will load up outbound settings from the database if available. (non-PHPdoc)

See Also
CApplicationComponent::init()

Definition at line 96 of file ZurmoImap.php.

loadInboundSettings ( )

Load inbound settings from the database.

Definition at line 105 of file ZurmoImap.php.

setInboundSettings ( )

Set inbound settings into the database.

Definition at line 136 of file ZurmoImap.php.

connect ( )

Connect to imap server

Exceptions
CException
Returns
bool

Definition at line 158 of file ZurmoImap.php.

getMessageBoxStatsDetailed ( )

Get detailed info about imap mail box

Definition at line 209 of file ZurmoImap.php.

resolveMessageBoxStats ( )

Get info about imap mail box

Definition at line 217 of file ZurmoImap.php.

getMessage (   $messageNumber,
  $mailHeaderInfo 
)
protected

Get email with attachments

Parameters
intmessageNumbers - message number
Object$mailHeaderInfo
Returns
array the email info

Definition at line 232 of file ZurmoImap.php.

getMessages (   $searchCriteria = 'ALL',
  $messagesSinceTimestamp = 0,
  $limit = null 
)

Get all messages, that satisfy some criteria, for example: 'ALL', 'UNSEEN', 'SUBJECT "Hello"'

Parameters
string$searchCriteria
int$messagesSinceTimestamp
int$limit
Returns
array the messages that was found

Definition at line 333 of file ZurmoImap.php.

expungeMessages ( )

Expunge all messages on IMAP server

Definition at line 365 of file ZurmoImap.php.

deleteMessages (   $expunge = false)

Delete all messages on IMAP server

Definition at line 378 of file ZurmoImap.php.

deleteMessage (   $msgUid)

Delete message on IMAP server

Parameters
int$msgUid
Returns
mixed bool false if there is no imapStream available, otherwise result of imap_delete

Definition at line 400 of file ZurmoImap.php.

getAttachments (   $structure,
  $messageId 
)
protected

Get all message attachments

Parameters
object$structure
int$messageId

Definition at line 414 of file ZurmoImap.php.

getMessageUId (   $msgNo)
protected

Get a sequenced message id

Parameters
string$msgNoin the format <.**> from the email
Returns
mixed on imap its the unique id (int) and for others its a base64_encoded string

Definition at line 478 of file ZurmoImap.php.

mailCount (   $query)
protected

get the count of mails for the given conditions and params

Todo:
conditions / order other find params
Parameters
array$queryconditions for the query
Returns
int the number of emails found

Definition at line 495 of file ZurmoImap.php.

getMimeType (   $structure)
protected
Parameters
$structure
Returns
string

Definition at line 508 of file ZurmoImap.php.

getPart (   $msgNumber,
  $mimeType,
  $structure = null,
  $partNumber = false 
)
protected
Parameters
$msgNumber
$mimeType
null$structure
bool$partNumber
Returns
bool|string

Definition at line 526 of file ZurmoImap.php.

Field Documentation

$imapPort = 143

IMAP port

Definition at line 60 of file ZurmoImap.php.

$imapSSL = false

Does IMAP server require secure connection

Definition at line 65 of file ZurmoImap.php.

$imapFolder = 'INBOX'

IMAP folder

Definition at line 70 of file ZurmoImap.php.

$imapStream
protected

IMAP stream. It is setup after connection to IMAP server established.

Definition at line 75 of file ZurmoImap.php.

$settingsToLoad
protected
Initial value:
= array(
'imapHost',
'imapUsername',
'imapPassword',
'imapPort',
'imapSSL',
'imapFolder'
)

Definition at line 82 of file ZurmoImap.php.


The documentation for this class was generated from the following file:
Generated on Wed Nov 25 2020 07:11:07
Account Suspended
Account Suspended
This Account has been suspended.
Contact your hosting provider for more information.