Mail_Queue
[ class tree: Mail_Queue ] [ index: Mail_Queue ] [ all elements ]

Class: Mail_Queue_Container_db

Source Location: /Mail_Queue-1.2.7/Mail/Queue/Container/db.php

Class Overview

Mail_Queue_Container
   |
   --Mail_Queue_Container_db

Mail_Queue_Container_db - Storage driver for fetching mail queue data from a PEAR_DB database


Author(s):

Version:

  • Release: @package_version@

Variables

Methods


Inherited Variables

Inherited Methods

Class: Mail_Queue_Container

Mail_Queue_Container::countSend()
Check how many times mail was sent.
Mail_Queue_Container::deleteMail()
Remove from queue mail with $id identifier.
Mail_Queue_Container::get()
Get next mail from queue. When exclude first time preload all queue
Mail_Queue_Container::getMailById()
Return mail by id $id (bypass mail_queue)
Mail_Queue_Container::getQueueCount()
Mail_Queue_Container::setAsSent()
Set mail as already sent.
Mail_Queue_Container::setOption()
Set common option
Mail_Queue_Container::skip()
Remove the current (problematic) mail from the buffer, but don't delete it from the db: it might be a temporary issue.
Mail_Queue_Container::_isSerialized()
Check if the string is a regular string or a serialized array

Class Details

[line 71]
Mail_Queue_Container_db - Storage driver for fetching mail queue data from a PEAR_DB database


[ Top ]


Class Variables

$db =

[line 79]

Reference to the current database connection.

Type:   object PEAR_DB


[ Top ]

$mail_table =  'mail_queue'

[line 85]

Table for sql database

Type:   string


[ Top ]

$sequence =  null

[line 90]

  • Var: the name of the sequence for this table

Type:   string


[ Top ]



Method Detail

__construct (Constructor)   [line 95]

Mail_Queue_Container_db __construct( $options)


Parameters:

   $options     

[ Top ]

Mail_Queue_Container_db (Constructor)   [line 114]

Mail_Queue_Container_db Mail_Queue_Container_db( mixed $options)

Constructor

Mail_Queue_Container_db()

  • Access: public

Parameters:

mixed   $options     An associative array of option names and their values. See DB_common::setOption for more information about connection options.

[ Top ]

countSend   [line 280]

mixed countSend( object Mail_Queue_Body $mail)

Check how many times mail was sent.
  • Return: Integer or Mail_Queue_Error class if error.
  • Access: public

Overrides Mail_Queue_Container::countSend() (Check how many times mail was sent.)

Parameters:

object Mail_Queue_Body   $mail     

[ Top ]

deleteMail   [line 429]

bool deleteMail( integer $id)

Remove from queue mail with $id identifier.
  • Return: True on success else Mail_Queue_Error class
  • Access: public

Overrides Mail_Queue_Container::deleteMail() (Remove from queue mail with $id identifier.)

Parameters:

integer   $id     Mail ID

[ Top ]

getMailById   [line 343]

mixed getMailById( integer $id)

Return mail by id $id (bypass mail_queue)
  • Return: Mail object or false on error.
  • Access: public

Overrides Mail_Queue_Container::getMailById() (Return mail by id $id (bypass mail_queue))

Parameters:

integer   $id     Mail ID

[ Top ]

getQueueCount   [line 379]

mixed getQueueCount( )

Return the number of emails currently in the queue.
  • Return: An int, or Mail_Queue_Error on failure.

Overrides Mail_Queue_Container::getQueueCount() (parent method not documented)
[ Top ]

put   [line 228]

mixed put( string $time_to_send, integer $id_user, string $ip, $sender, $recipient, $headers, string $body, [bool $delete_after_send = true], string $from, string $to, string $hdrs)

Put new mail in queue and save in database.

Mail_Queue_Container::put()

  • Return: ID of the record where this mail has been put or Mail_Queue_Error on error
  • Access: public

Parameters:

string   $time_to_send     When mail have to be send
integer   $id_user     Sender id
string   $ip     Sender ip
string   $from     Sender e-mail
string   $to     Reciepient e-mail
string   $hdrs     Mail headers (in RFC)
string   $body     Mail body (in RFC)
bool   $delete_after_send     Delete or not mail from db after send
   $sender     
   $recipient     
   $headers     

[ Top ]

setAsSent   [line 311]

bool setAsSent( object Mail_Queue_Body $mail)

Set mail as already sent.
  • Access: public

Overrides Mail_Queue_Container::setAsSent() (Set mail as already sent.)

Parameters:

object Mail_Queue_Body   $mail     object

[ Top ]


Documentation generated on Thu, 30 Jun 2011 16:00:04 +0000 by phpDocumentor 1.4.3. PEAR Logo Copyright © PHP Group 2004.