3.0 query abstraction

This moves most of `Cake\ORM\Query` into `Cake\Datasource\QueryTrait` and generalizes the code in `QueryCacher` to be able to cache any type of passed query.

The code inside query was rather generic as it only dealt with getting results and decorating them with one or multiple special decorators, so it was quite easy to extract without major modifications.

I'm working on a Elastic Search datasource and I've used successfully this code to build a working prototype. I was thinking in making it a cakephp official plugin, bad idea?