zendframework/zf2 — pull request #3482 by weierophinney (2013-01-18 19:24:20+00:00)
Title: Feature/rest delete replace collection

In reviewing the `AbstractRestfulController` implementation against various docs, I discovered two capabilities we currently not only do not support, but raise exceptions for:

* **DELETE** to a _collection_ (i.e., to "/users" vs "/users/1"). While rarely used, this method is allowed, and is used to indicate that the entire collection should be _deleted_.
* **PUT** to a _collection_ (i.e., to "/users" vs "/users/1"). While rarely used, this method is allowed, and is used to indicate that the entire collection should be _replaced_ with what is provided in the request.

This PR adds support for both operations. It adds two new methods, `deleteList()` and `replaceList()`, which were chosen to mirror the existing `getList()` method while semantically indicating purpose.