Note:

If you want to create a new page for developers, you should create it on the Moodle Developer Resource site.

Talk:Cache API: Difference between revisions

From MoodleDocs
(Created page with "==Some comments== from Tim. 1. In the "Using your cache object" section, you have get and delete returning a status. Surely it is better to have them throw an exception on erro...")
 
No edit summary
Line 6: Line 6:


2. make_with_params is not a great method name. Sadly, I can't do better. make_ad_hoc? make_one_off? make_custom?
2. make_with_params is not a great method name. Sadly, I can't do better. make_ad_hoc? make_one_off? make_custom?
3. I took the liberty of correcting one thing on [[Cache_API_-_Quick_reference]] to match [[Cache API]] (make -> make_with_params in Getting an ad-hoc cache instance section). However there are other things that need to be corrected that I am not sure about. I will leave them for you.

Revision as of 07:08, 30 August 2012

Some comments

from Tim.

1. In the "Using your cache object" section, you have get and delete returning a status. Surely it is better to have them throw an exception on error, and just return on success (like the DB API).

2. make_with_params is not a great method name. Sadly, I can't do better. make_ad_hoc? make_one_off? make_custom?

3. I took the liberty of correcting one thing on Cache_API_-_Quick_reference to match Cache API (make -> make_with_params in Getting an ad-hoc cache instance section). However there are other things that need to be corrected that I am not sure about. I will leave them for you.