Class Zend_Http_Client_Adapter_Socket

Description

Implements interfaces:

A sockets based (fsockopen) adapter class for Zend_Http_Client. Can be used on almost every PHP environment, and does not require any special extensions.

  • license: New BSD License
  • copyright: Copyright (c) 2005-2007 Zend Technologies USA Inc. (http://www.zend.com)

Located in /Zend/Http/Client/Adapter/Socket.php (line 38)


	
			
Direct descendents
Class Description
 class Zend_Http_Client_Adapter_Proxy HTTP Proxy-supporting Zend_Http_Client adapter class, based on the default socket based adapter.
Variable Summary
 array $config
 resource|null $socket
Method Summary
 Zend_Http_Client_Adapter_Socket __construct ()
 void __destruct ()
 void close ()
 void connect (string $host, [int $port = 80], [boolean $secure = false], int $timeout)
 string read ()
 void setConfig ([array $config = array()])
 string write (string $method, Zend_Uri_Http $uri, [string $http_ver = '1.1'], [array $headers = array()], [string $body = ''])
Variables
array $config = array(
'ssltransport' => 'sslv2'
)
(line 59)

Parameters array

  • access: protected

Redefined in descendants as:
array $connected_to = array(null, null) (line 52)

What host/port are we connected to?

  • access: protected
resource|null $socket = null (line 45)

The socket for server connection

  • access: protected
Methods
Constructor __construct (line 67)

Adapter constructor, currently empty. Config is set using setConfig()

  • access: public
Zend_Http_Client_Adapter_Socket __construct ()
Destructor __destruct (line 268)

Destructor: make sure the socket is disconnected

  • access: public
void __destruct ()

Redefined in descendants as:
close (line 257)

Close the connection to the server

  • access: public
void close ()

Implementation of:
Zend_Http_Client_Adapter_Interface::close()
Close the connection to the server
connect (line 95)

Connect to the remote server

  • access: public
void connect (string $host, [int $port = 80], [boolean $secure = false], int $timeout)
  • string $host
  • int $port
  • boolean $secure
  • int $timeout

Implementation of:
Zend_Http_Client_Adapter_Interface::connect()
Connect to the remote server

Redefined in descendants as:
read (line 170)

Read response from server

  • access: public
string read ()

Implementation of:
Zend_Http_Client_Adapter_Interface::read()
Read response from server
setConfig (line 76)

Set the configuration array for the adapter

  • access: public
void setConfig ([array $config = array()])
  • array $config

Implementation of:
Zend_Http_Client_Adapter_Interface::setConfig()
Set the configuration array for the adapter
write (line 134)

Send request to the remote server

  • return: Request as string
  • access: public
string write (string $method, Zend_Uri_Http $uri, [string $http_ver = '1.1'], [array $headers = array()], [string $body = ''])
  • string $method
  • Zend_Uri_Http $uri
  • string $http_ver
  • array $headers
  • string $body

Implementation of:
Zend_Http_Client_Adapter_Interface::write()
Send request to the remote server

Redefined in descendants as:

Documentation generated on Thu, 18 Jan 2007 09:59:19 -0800 by phpDocumentor 1.3.1