equal
deleted
inserted
replaced
57 |
57 |
58 /** |
58 /** |
59 * Retrieves headers associated with the response. |
59 * Retrieves headers associated with the response. |
60 * |
60 * |
61 * @since 4.6.0 |
61 * @since 4.6.0 |
62 * |
|
63 * @see \Requests_Utility_CaseInsensitiveDictionary |
|
64 * |
62 * |
65 * @return \Requests_Utility_CaseInsensitiveDictionary Map of header name to header value. |
63 * @return \Requests_Utility_CaseInsensitiveDictionary Map of header name to header value. |
66 */ |
64 */ |
67 public function get_headers() { |
65 public function get_headers() { |
68 // Ensure headers remain case-insensitive. |
66 // Ensure headers remain case-insensitive. |
133 /** |
131 /** |
134 * Retrieves the response data. |
132 * Retrieves the response data. |
135 * |
133 * |
136 * @since 4.6.0 |
134 * @since 4.6.0 |
137 * |
135 * |
138 * @return mixed Response data. |
136 * @return string Response data. |
139 */ |
137 */ |
140 public function get_data() { |
138 public function get_data() { |
141 return $this->response->body; |
139 return $this->response->body; |
142 } |
140 } |
143 |
141 |
144 /** |
142 /** |
145 * Sets the response data. |
143 * Sets the response data. |
146 * |
144 * |
147 * @since 4.6.0 |
145 * @since 4.6.0 |
148 * |
146 * |
149 * @param mixed $data Response data. |
147 * @param string $data Response data. |
150 */ |
148 */ |
151 public function set_data( $data ) { |
149 public function set_data( $data ) { |
152 $this->response->body = $data; |
150 $this->response->body = $data; |
153 } |
151 } |
154 |
152 |