Flush all persistent and static caches.
This hook asks your module to clear all of its persistent (database) and static caches, in order to ensure a clean environment for subsequently invoked data rebuilds.
Do NOT use this hook for rebuilding information. Only use it to flush custom caches and return the names of additional cache bins to flush.
Static caches using drupal_static() do not need to be reset manually. However, all other static variables that do not use drupal_static() must be manually reset.
This hook is invoked by drupal_flush_all_caches(). It runs before module data is updated and before hook_rebuild().
array An array of cache bins to be flushed.
Note: this list is generated by pattern matching, so it may include some functions that are not actually implementations of this hook.
function hook_cache_flush() {
return array(
'example',
);
}