You are here

function finder_load_multiple in Finder 7.2

Same name and namespace in other branches
  1. 6 finder.module \finder_load_multiple()
  2. 7 finder.module \finder_load_multiple()

Export CRUD callback to load multiple finders.

Parameters

$names: An array of finder names.

$reset: Whether to reset the internal cache for finder objects.

Return value

An array of loaded finder objects.

2 calls to finder_load_multiple()
finder_load in ./finder.module
Export CRUD callback to load a finder.
finder_load_all in ./finder.module
Export CRUD callback to load all finders.
1 string reference to 'finder_load_multiple'
finder_schema in ./finder.install
Implements hook_schema().

File

./finder.module, line 346
The finder module.

Code

function finder_load_multiple($names = NULL, $reset = FALSE) {
  ctools_include('export');
  if ($reset) {
    drupal_static_reset('ctools_export_load_object_all');
  }
  $type = $names ? 'names' : 'all';
  $results = ctools_export_load_object('finder', $type, $names);
  $results = array_filter($results);
  if (!empty($results)) {
    module_invoke_all('finder_load', $results);
  }
  return $results;
}