Public Member Functions | Protected Attributes

Zend_Mail_Storage_Pop3 Class Reference

Inheritance diagram for Zend_Mail_Storage_Pop3:
Zend_Mail_Storage_Abstract

Public Member Functions

 countMessages ()
 getSize ($id=0)
 getMessage ($id)
 getRawHeader ($id, $part=null, $topLines=0)
 getRawContent ($id, $part=null)
 __construct ($params)
 close ()
 noop ()
 removeMessage ($id)
 getUniqueId ($id=null)
 getNumberByUniqueId ($id)
 __get ($var)

Protected Attributes

 $_protocol

Detailed Description

Definition at line 47 of file Pop3.php.


Constructor & Destructor Documentation

__construct ( params )

create instance with parameters Supported paramters are

  • host hostname or ip address of POP3 server
  • user username
  • password password for user 'username' [optional, default = '']
  • port port for POP3 server [optional, default = 110]
  • ssl 'SSL' or 'TLS' for secure sockets
Parameters:
$paramsarray mail reader specific parameters
Exceptions:
Zend_Mail_Storage_Exception
Zend_Mail_Protocol_Exception

See also:
Zend_Mail_Storage_Exception

Reimplemented from Zend_Mail_Storage_Abstract.

Definition at line 161 of file Pop3.php.


Member Function Documentation

__get ( var )

Special handling for hasTop and hasUniqueid. The headers of the first message is retrieved if Top wasn't needed/tried yet.

See also:
Zend_Mail_Storage_Abstract:__get()
Parameters:
string$var
Returns:
string
Exceptions:
Zend_Mail_Storage_Exception

Reimplemented from Zend_Mail_Storage_Abstract.

Definition at line 295 of file Pop3.php.

close (  )

Close resource for mail lib. If you need to control, when the resource is closed. Otherwise the destructor would call this.

Returns:
null

Reimplemented from Zend_Mail_Storage_Abstract.

Definition at line 200 of file Pop3.php.

countMessages (  )

Count messages all messages in current box

Returns:
int number of messages
Exceptions:
Zend_Mail_Storage_Exception
Zend_Mail_Protocol_Exception

Reimplemented from Zend_Mail_Storage_Abstract.

Definition at line 63 of file Pop3.php.

getMessage ( id )

Fetch a message

Parameters:
int$idnumber of message
Returns:
Zend_Mail_Message
Exceptions:
Zend_Mail_Protocol_Exception

Reimplemented from Zend_Mail_Storage_Abstract.

Definition at line 89 of file Pop3.php.

getNumberByUniqueId ( id )

get a message number from a unique id

I.e. if you have a webmailer that supports deleting messages you should use unique ids as parameter and use this method to translate it to message number right before calling removeMessage()

Parameters:
string$idunique id
Returns:
int message number
Exceptions:
Zend_Mail_Storage_Exception

See also:
Zend_Mail_Storage_Exception

Reimplemented from Zend_Mail_Storage_Abstract.

Definition at line 266 of file Pop3.php.

getRawContent ( id,
part = null 
)

Get raw content of message or part

Parameters:
int$idnumber of message
null | array | string$partpath to part or null for messsage content
Returns:
string raw content

See also:
Zend_Mail_Storage_Exception

Reimplemented from Zend_Mail_Storage_Abstract.

Definition at line 131 of file Pop3.php.

getRawHeader ( id,
part = null,
topLines = 0 
)

Get raw header of message or part

Parameters:
int$idnumber of message
null | array | string$partpath to part or null for messsage header
int$topLinesinclude this many lines with header (after an empty line)
Returns:
string raw header

See also:
Zend_Mail_Storage_Exception

Reimplemented from Zend_Mail_Storage_Abstract.

Definition at line 108 of file Pop3.php.

getSize ( id = 0 )

get a list of messages with number and size

Parameters:
int$idnumber of message
Returns:
int|array size of given message of list with all messages as array(num => size)
Exceptions:
Zend_Mail_Protocol_Exception

Reimplemented from Zend_Mail_Storage_Abstract.

Definition at line 76 of file Pop3.php.

getUniqueId ( id = null )

get unique id for one or all messages

if storage does not support unique ids it's the same as the message number

Parameters:
int | null$idmessage number
Returns:
array|string message number for given message or all messages as array
Exceptions:
Zend_Mail_Storage_Exception

Reimplemented from Zend_Mail_Storage_Abstract.

Definition at line 239 of file Pop3.php.

noop (  )

Keep the server busy.

Returns:
null
Exceptions:
Zend_Mail_Protocol_Exception

Reimplemented from Zend_Mail_Storage_Abstract.

Definition at line 211 of file Pop3.php.

removeMessage ( id )

Remove a message from server. If you're doing that from a web enviroment you should be careful and use a uniqueid as parameter if possible to identify the message.

Parameters:
int$idnumber of message
Returns:
null
Exceptions:
Zend_Mail_Protocol_Exception

Reimplemented from Zend_Mail_Storage_Abstract.

Definition at line 225 of file Pop3.php.


The documentation for this class was generated from the following file: