Swift_Plugins_BandwidthMonitorPlugin
in package
implements
Swift_Events_SendListener, Swift_Events_CommandListener, Swift_Events_ResponseListener, Swift_InputByteStream
Reduces network flooding when sending large amounts of mail.
Tags
Interfaces, Classes and Traits
- Swift_Events_SendListener
- Listens for Messages being sent from within the Transport system.
- Swift_Events_CommandListener
- Listens for Transports to send commands to the server.
- Swift_Events_ResponseListener
- Listens for responses from a remote SMTP server.
- Swift_InputByteStream
- An abstract means of writing data.
Table of Contents
- $in : int
- The incoming traffic counter.
- $mirrors : mixed
- Bound byte streams
- $out : int
- The outgoing traffic counter.
- beforeSendPerformed() : mixed
- Not used.
- bind() : mixed
- Attach $is to this stream.
- commandSent() : mixed
- Invoked immediately following a command being sent.
- commit() : mixed
- Not used.
- flushBuffers() : mixed
- Not used.
- getBytesIn() : int
- Get the total number of bytes received from the server.
- getBytesOut() : int
- Get the total number of bytes sent to the server.
- reset() : mixed
- Reset the internal counters to zero.
- responseReceived() : mixed
- Invoked immediately following a response coming back.
- sendPerformed() : mixed
- Invoked immediately after the Message is sent.
- unbind() : mixed
- Remove an already bound stream.
- write() : int
- Called when a message is sent so that the outgoing counter can be increased.
Properties
$in
The incoming traffic counter.
private
int
$in
= 0
$mirrors
Bound byte streams
private
mixed
$mirrors
= []
$out
The outgoing traffic counter.
private
int
$out
= 0
Methods
beforeSendPerformed()
Not used.
public
beforeSendPerformed(Swift_Events_SendEvent $evt) : mixed
Parameters
- $evt : Swift_Events_SendEvent
Return values
mixed —bind()
Attach $is to this stream.
public
bind(Swift_InputByteStream $is) : mixed
The stream acts as an observer, receiving all data that is written. All and operations will be mirrored.
Parameters
- $is : Swift_InputByteStream
Return values
mixed —commandSent()
Invoked immediately following a command being sent.
public
commandSent(Swift_Events_CommandEvent $evt) : mixed
Parameters
- $evt : Swift_Events_CommandEvent
Return values
mixed —commit()
Not used.
public
commit() : mixed
Return values
mixed —flushBuffers()
Not used.
public
flushBuffers() : mixed
Return values
mixed —getBytesIn()
Get the total number of bytes received from the server.
public
getBytesIn() : int
Return values
int —getBytesOut()
Get the total number of bytes sent to the server.
public
getBytesOut() : int
Return values
int —reset()
Reset the internal counters to zero.
public
reset() : mixed
Return values
mixed —responseReceived()
Invoked immediately following a response coming back.
public
responseReceived(Swift_Events_ResponseEvent $evt) : mixed
Parameters
- $evt : Swift_Events_ResponseEvent
Return values
mixed —sendPerformed()
Invoked immediately after the Message is sent.
public
sendPerformed(Swift_Events_SendEvent $evt) : mixed
Parameters
- $evt : Swift_Events_SendEvent
Return values
mixed —unbind()
Remove an already bound stream.
public
unbind(Swift_InputByteStream $is) : mixed
If $is is not bound, no errors will be raised. If the stream currently has any buffered data it will be written to $is before unbinding occurs.
Parameters
- $is : Swift_InputByteStream
Return values
mixed —write()
Called when a message is sent so that the outgoing counter can be increased.
public
write(string $bytes) : int
Parameters
- $bytes : string