API Documentation

Zend/Controller/Request/HttpTestCase.php

Show: inherited
Table of Contents

Zend Framework

LICENSE

This source file is subject to the new BSD license that is bundled with this package in the file LICENSE.txt. It is also available through the world-wide-web at this URL: http://framework.zend.com/license/new-bsd If you did not receive a copy of the license and are unable to obtain it through the world-wide-web, please send an email to license@zend.com so we can send you a copy immediately.

Category
Zend  
Copyright
Copyright (c) 2005-2012 Zend Technologies USA Inc. (http://www.zend.com)  
License
New BSD License  
Package
Zend_Controller  
Version
$Id: HttpTestCase.php 24594 2012-01-05 21:27:01Z matthew $  

\Zend_Controller_Request_HttpTestCase

Package: Zend\Controller\Request

Zend_Controller_Request_HttpTestCase

HTTP request object for use with Zend_Controller family.

Parent(s)
\Zend_Controller_Request_Http < \Zend_Controller_Request_Abstract
Uses
\Zend_Controller_Request_Http  

Properties

Propertyprotectedarray  $_headers= 'array()'

Request headers

Default valuearray()Details
Type
array
Propertyprotectedstring  $_method= ''GET''

Request method

Default value'GET'Details
Type
string
Propertyprotectedstring|null  $_rawBody= ''

Raw POST body

Details
Type
stringnull
Propertyprotectedarray  $_validMethodTypes= 'array( 'DELETE''

Valid request method types

Default valuearray( 'DELETE'Details
Type
array

Methods

methodprotected_normalizeHeaderName( string $name ) : string

Normalize a header name for setting and retrieval

Parameters
Name Type Description
$name string
Returns
Type Description
string
methodpublicclearCookies( ) : \Zend_Controller_Request_HttpTestCase

Clear all cookies

Returns
Type Description
\Zend_Controller_Request_HttpTestCase
methodpublicclearHeaders( ) : \Zend_Controller_Request_HttpTestCase

Clear request headers

Returns
Type Description
\Zend_Controller_Request_HttpTestCase
methodpublicclearPost( ) : \Zend_Controller_Request_HttpTestCase

Clear POST values

Returns
Type Description
\Zend_Controller_Request_HttpTestCase
methodpublicclearQuery( ) : \Zend_Controller_Request_HttpTestCase

Clear GET values

Returns
Type Description
\Zend_Controller_Request_HttpTestCase
methodpublicclearRawBody( ) : \Zend_Controller_Request_HttpTestCase

Clear raw POST body

Returns
Type Description
\Zend_Controller_Request_HttpTestCase
methodpublicgetHeader( string $header, mixed $default = null ) : string|null

Get request header

Parameters
Name Type Description
$header string
$default mixed
Returns
Type Description
string|null
methodpublicgetHeaders( ) : array

Get all request headers

Returns
Type Description
array
methodpublicgetMethod( ) : string|null

Get request method

Returns
Type Description
string|null
methodpublicgetRawBody( ) : string|null

Get RAW POST body

Returns
Type Description
string|null
methodpublicgetRequestUri( ) : null|string

Get REQUEST_URI

Returns
Type Description
null|string
methodpublicsetCookie( string $key, mixed $value ) : \Zend_Controller_Request_HttpTestCase

Set a cookie

Parameters
Name Type Description
$key string
$value mixed
Returns
Type Description
\Zend_Controller_Request_HttpTestCase
methodpublicsetCookies( array $cookies ) : void

Set multiple cookies at once

Parameters
Name Type Description
$cookies array
methodpublicsetHeader( string $key, string $value ) : \Zend_Controller_Request_HttpTestCase

Set a request header

Parameters
Name Type Description
$key string
$value string
Returns
Type Description
\Zend_Controller_Request_HttpTestCase
methodpublicsetHeaders( array $headers ) : \Zend_Controller_Request_HttpTestCase

Set request headers

Parameters
Name Type Description
$headers array
Returns
Type Description
\Zend_Controller_Request_HttpTestCase
methodpublicsetMethod( string $type ) : \Zend_Controller_Request_HttpTestCase

Set request method

Parameters
Name Type Description
$type string
Returns
Type Description
\Zend_Controller_Request_HttpTestCase
methodpublicsetRawBody( string $content ) : \Zend_Controller_Request_HttpTestCase

Set raw POST body

Parameters
Name Type Description
$content string
Returns
Type Description
\Zend_Controller_Request_HttpTestCase
Documentation was generated by DocBlox 0.15.1.