Skip to content

Commit

Permalink
Update session phpdoc
Browse files Browse the repository at this point in the history
  • Loading branch information
rmccue committed Sep 30, 2013
1 parent f265e25 commit b93972e
Showing 1 changed file with 15 additions and 3 deletions.
18 changes: 15 additions & 3 deletions library/Requests/Session.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,11 @@
/**
* Session handler for persistent requests and default parameters
*
* Allows various options to be set as default values, and merges both the
* options and URL properties together. A base URL can be set for all requests,
* with all subrequests resolved from this. Base options can be set (including
* a shared cookie jar), then overridden for individual requests.
*
* @package Requests
* @subpackage Session Handler
*/
Expand All @@ -29,13 +34,20 @@ class Requests_Session {

/**
* Base data for requests
*
* If both the base data and the per-request data are arrays, the data will
* be merged before sending the request.
*
* @var array
*/
public $data = array();

/**
* Base options for requests
*
* The base options are merged with the per-request data for each request.
* The only default option is a shared cookie jar between requests.
*
* Values here can also be set directly via properties on the Session
* object, e.g. `$session->useragent = 'X';`
*
Expand All @@ -47,9 +59,9 @@ class Requests_Session {
* Create a new session
*
* @param string|null $url Base URL for requests
* @param array $headers Headers
* @param array $data [description]
* @param array $options [description]
* @param array $headers Default headers for requests
* @param array $data Default data for requests
* @param array $options Default options for requests
*/
public function __construct($url = null, $headers = array(), $data = array(), $options = array()) {
$this->url = $url;
Expand Down

0 comments on commit b93972e

Please sign in to comment.