PoseBiz/stretcher — pull request #61 by andrewvc (2013-09-15 18:07:17+00:00)
Title: Improve Stretcher::SearchResults to be more lazy

In this patch Stretcher::SearchResults fixes a number of the issues brought up in #49 and #59 . The concerns people had were:

* Accessing raw, unmodified search responses (no special copying of _ prefixed names)
* Accessing raw unmodified data w/o hashie mashification
* The #results method is poorly named, I've provided a better alias, #documents

To fix this the following changes were made

* The new #documents method is now lazy, it will only construct the fancy version of the response if invoked.
* The #raw method is now a lazy way to return the server response as a Hashie::Mash
* The new #raw_plain method returns the server response as a standard ruby Hash
* The code has been DRYed up in general