\SocketWriteRead
Utility class used by Akismet
This class is used by Akismet to do the actual sending and receiving of data. It opens a connection to a remote host, sends some data and the reads the response and makes it available to the calling program.
The code that makes up this class originates in the Akismet WordPress plugin, which is .
N.B. It is not necessary to call this class directly to use the Akismet class. This is included here mainly out of a sense of completeness.
- Author: Alex Potsides
Synopsis
class SocketWriteRead
{
- // members
- private $host;
- private $port;
- private $request;
- private $response;
- private $responseLength;
- private $errorNumber;
- private $errorString;
- // methods
- public void __construct()
- public void send()
- public string getResponse()
- public int getErrorNumner()
- public string getErrorString()
Members
private
- $errorNumber
- $errorString
- $host
- $port
- $request
- $response
- $responseLength
Methods
public
- __construct()
- getErrorNumner() — Returns the error number
- getErrorString() — Returns the error string
- getResponse() — Returns the server response text
- send() — Sends the data to the remote host.