CoreFiles by mySites.guru
Transport.php41 lines, 1,220 bytes, from wordpress-5.3.21.zip
Raw History Compare with 5.3.20
md5
019c993bce6bed178baf4b5c566cc617
sha1
d86f34d08ddf135e385c7dd2e053b784c507f3d8
sha256
e81e1b9a527a8f4fbe0ab94d016ba09e9ffaf57902e7cd7587fdc8c631f8513b
<?php
/**
 * Base HTTP transport
 *
 * @package Requests
 * @subpackage Transport
 */

/**
 * Base HTTP transport
 *
 * @package Requests
 * @subpackage Transport
 */
interface Requests_Transport {
	/**
	 * Perform a request
	 *
	 * @param string $url URL to request
	 * @param array $headers Associative array of request headers
	 * @param string|array $data Data to send either as the POST body, or as parameters in the URL for a GET/HEAD
	 * @param array $options Request options, see {@see Requests::response()} for documentation
	 * @return string Raw HTTP result
	 */
	public function request($url, $headers = array(), $data = array(), $options = array());

	/**
	 * Send multiple requests simultaneously
	 *
	 * @param array $requests Request data (array of 'url', 'headers', 'data', 'options') as per {@see Requests_Transport::request}
	 * @param array $options Global options, see {@see Requests::response()} for documentation
	 * @return array Array of Requests_Response objects (may contain Requests_Exception or string responses as well)
	 */
	public function request_multiple($requests, $options);

	/**
	 * Self-test whether the transport can be used
	 * @return bool
	 */
	public static function test();
}

The same content is in 481 releases, WordPress 4.6-beta1 to 5.7.21. See them all, or every version of this file.