Property | Type | Description | |
---|---|---|---|
$contentTypes | array | ||
$customHttpMethodsMap | array | Map of custom HTTP methods and their handlers | |
$eventIdentifier | {@inheritDoc} | ||
$identifierName | string | Name of request or query parameter containing identifier | |
$jsonDecodeType | integer | boolean | The flags in Zend\Json\Json::decode are integers, but when evaluated in a boolean context map to the flag passed as the second parameter to json_decode(). As such, you can specify either the Zend\Json\Json constant or the boolean value. By default, starting in v3, we use the boolean value, and cast to integer if using Zend\Json\Json::decode. Default value is boolean true, meaning JSON should be cast to associative arrays (vs objects). Override the value in an extending class to set the default behavior for your class. |
Method | Description | |
---|---|---|
addHttpMethodHandler ( string $method, Callable $handler ) : |
Register a handler for a custom HTTP method | |
create ( mixed $data ) : mixed | Create a new resource | |
delete ( mixed $id ) : mixed | Delete an existing resource | |
deleteList ( $data ) : mixed | Delete the entire resource collection | |
dispatch ( Zend\Stdlib\RequestInterface $request, Zend\Stdlib\ResponseInterface $response = null ) : mixed | Zend\Stdlib\ResponseInterface | Dispatch a request | |
get ( mixed $id ) : mixed | Return single resource | |
getIdentifierName ( ) : string | Retrieve the route match/query parameter name containing the identifier | |
getList ( ) : mixed | Return list of resources | |
head ( null | mixed $id = null ) : mixed | Retrieve HEAD metadata for the resource | |
notFoundAction ( ) : array | Basic functionality for when a page is not available | |
onDispatch ( |
Handle the request | |
options ( ) : mixed | Respond to the OPTIONS method | |
patch ( $id, $data ) : array | Respond to the PATCH method | |
patchList ( mixed $data ) : mixed | Modify a resource collection without completely replacing it | |
processPostData ( Zend\Stdlib\RequestInterface $request ) : mixed | Process post data and call create | |
replaceList ( mixed $data ) : mixed | Replace an entire resource collection | |
requestHasContentType ( Zend\Stdlib\RequestInterface $request, string | null $contentType = '' ) : boolean | Check if request has certain content type | |
setIdentifierName ( string $name ) : self | Set the route match/query parameter name containing the identifier | |
update ( mixed $id, mixed $data ) : mixed | Update an existing resource |
Method | Description | |
---|---|---|
getIdentifier ( Zend\Router\RouteMatch $routeMatch, Zend\Stdlib\RequestInterface $request ) : false | mixed | Retrieve the identifier, if any | |
jsonDecode ( $string ) : mixed | Decode a JSON string. | |
processBodyContent ( mixed $request ) : object | string | array | Process the raw body content |
public addHttpMethodHandler ( string $method, Callable $handler ) : |
||
$method | string | |
$handler | Callable | |
return |
public deleteList ( $data ) : mixed | ||
return | mixed |
protected getIdentifier ( Zend\Router\RouteMatch $routeMatch, Zend\Stdlib\RequestInterface $request ) : false | mixed | ||
$routeMatch | Zend\Router\RouteMatch | |
$request | Zend\Stdlib\RequestInterface | |
return | false | mixed |
public getIdentifierName ( ) : string | ||
return | string |
protected jsonDecode ( $string ) : mixed | ||
return | mixed |
public notFoundAction ( ) : array | ||
return | array |
public onDispatch ( |
||
$e | ||
return | mixed |
public processPostData ( Zend\Stdlib\RequestInterface $request ) : mixed | ||
$request | Zend\Stdlib\RequestInterface | |
return | mixed |
public replaceList ( mixed $data ) : mixed | ||
$data | mixed | |
return | mixed |
public setIdentifierName ( string $name ) : self | ||
$name | string | |
return | self |
protected array $customHttpMethodsMap | ||
return | array |
protected string $identifierName | ||
return | string |