function hook_panels_cache_get in Panels 7.3
Allow modules to provide their own caching mechanism for the display editor.
Parameters
string $argument: The second half of the cache key. Full key module:TASK_NAME:HANDLER_NAME passed part: TASK_NAME:HANDLER_NAME
Return value
stdClass|NULL The cached display or NULL if the cache wasn't hit.
4 functions implement hook_panels_cache_get()
Note: this list is generated by pattern matching, so it may include some functions that are not actually implementations of this hook.
- panels_mini_panels_cache_get in panels_mini/
panels_mini.module - Get display edit cache for the panels mini export UI.
- panels_node_panels_cache_get in panels_node/
panels_node.module - Get display edit cache for a panel node being edited.
- panels_page_wizard_panels_cache_get in ./
panels.module - Get display edit cache for the panels mini export UI.
- panel_context_panels_cache_get in ./
panels.module - Get display edit cache on behalf of panel context.
1 invocation of hook_panels_cache_get()
- panels_edit_cache_get in ./
panels.module - Panels Editor Cache Get.
File
- ./
panels.api.php, line 33 - Hooks provided by Panels.
Code
function hook_panels_cache_get($argument) {
ctools_include('common', 'panels');
list($handler, $item) = _panels_mini_panels_cache_get($argument);
if (isset($item->mini_panels_display_cache)) {
return $item->mini_panels_display_cache;
}
$cache = new stdClass();
$cache->display = $item->display;
$cache->display->context = ctools_context_load_contexts($item);
$cache->display->cache_key = 'panels_mini:' . $argument;
$cache->content_types = panels_common_get_allowed_types('panels_mini', $cache->display->context);
$cache->display_title = TRUE;
// @TODO support locking.
$cache->locked = FALSE;
return $cache;
}