PHP Класс Swift_Plugins_AntiFloodPlugin, Halite

Автор: Chris Corbyn
Наследование: implements Swift_Events_SendListener, implements Swift_Plugins_Sleeper
Показать файл Открыть проект Примеры использования класса

Открытые методы

Метод Описание
__construct ( integer $threshold = 99, integer $sleep, Swift_Plugins_Sleeper $sleeper = null ) Create a new AntiFloodPlugin with $threshold and $sleep time.
beforeSendPerformed ( Swift_Events_SendEvent $evt ) Invoked immediately before the Message is sent.
getSleepTime ( ) : integer Get the number of seconds to sleep for during a restart.
getThreshold ( ) : integer Get the number of emails to send before restarting.
sendPerformed ( Swift_Events_SendEvent $evt ) Invoked immediately after the Message is sent.
setSleepTime ( integer $sleep ) Set the number of seconds to sleep for during a restart.
setThreshold ( integer $threshold ) Set the number of emails to send before restarting.
sleep ( integer $seconds ) Sleep for $seconds.

Описание методов

__construct() публичный Метод

Create a new AntiFloodPlugin with $threshold and $sleep time.
public __construct ( integer $threshold = 99, integer $sleep, Swift_Plugins_Sleeper $sleeper = null )
$threshold integer
$sleep integer time
$sleeper Swift_Plugins_Sleeper (not needed really)

beforeSendPerformed() публичный Метод

Invoked immediately before the Message is sent.
public beforeSendPerformed ( Swift_Events_SendEvent $evt )
$evt Swift_Events_SendEvent

getSleepTime() публичный Метод

Get the number of seconds to sleep for during a restart.
public getSleepTime ( ) : integer
Результат integer

getThreshold() публичный Метод

Get the number of emails to send before restarting.
public getThreshold ( ) : integer
Результат integer

sendPerformed() публичный Метод

Invoked immediately after the Message is sent.
public sendPerformed ( Swift_Events_SendEvent $evt )
$evt Swift_Events_SendEvent

setSleepTime() публичный Метод

Set the number of seconds to sleep for during a restart.
public setSleepTime ( integer $sleep )
$sleep integer time

setThreshold() публичный Метод

Set the number of emails to send before restarting.
public setThreshold ( integer $threshold )
$threshold integer

sleep() публичный Метод

Sleep for $seconds.
public sleep ( integer $seconds )
$seconds integer