You are here

function translation_table_get_module_apis in Translation table 7

Same name and namespace in other branches
  1. 6 translation_table.module \translation_table_get_module_apis()

Get a list of modules that support the current translation_table API.

1 call to translation_table_get_module_apis()
translation_table_module_include in ./translation_table.module
Load translation table files on behalf of modules.

File

./translation_table.module, line 104
Translation table module

Code

function translation_table_get_module_apis() {
  static $cache = NULL;
  if (!isset($cache)) {
    $cache = array();
    foreach (module_implements('translation_table_api') as $module) {
      $function = $module . '_translation_table_api';
      $info = $function();
      if (isset($info['api']) && $info['api'] == 1.0) {
        if (!isset($info['path'])) {
          $info['path'] = drupal_get_path('module', $module);
        }
        $cache[$module] = $info;
      }
    }
  }
  return $cache;
}