tedivm/Stash — pull request #21 by vicb (2012-02-23 15:54:51+00:00)
Title: [WIP] Cleanup, fixes, questions

This PR contains some cleanup and fixes and raises some questions.

Open items:

* It seems to me that the HandlerInterface could not be type hinted (as I started to do) because of sub-handlers, could we find a better way to do this ? Are sub-handlers necessary at-all (this could be handled by the configuration (i.e. DIC or whatever system you use) ?
* I don't like the Exception management. When an invalid argument is passed we should throw an exception of (derived) class `InvalidArgumentException` / `RuntimeException` / `LogicException` according to what fit best.
* I don't like XCache inheriting from APC this is convenience not good design (they live independently),
* the same goes for Memcache extending Memcached

I did not intend so many changes at the beginning, everything is open to discussion.