function ctools_plugin_load_function

Load a plugin and get a function name from it, returning success only if the function exists.

Parameters

$module: The module that owns the plugin type.

$type: The type of plugin.

$id: The id of the specific plugin to load.

$function_name: The identifier of the function. For example, 'settings form'.

Return value

string The actual name of the function to call, or NULL if the function does not exist.

8 calls to ctools_plugin_load_function()
CtoolsPluginsGetInfoTestCase::assertPluginFunction in tests/ctools.plugins.test
Assert helper to check that a specific plugin function exists.
CtoolsPluginsGetInfoTestCase::assertPluginMissingFunction in tests/ctools.plugins.test
Assert helper to check that a specific plugin function does NOT exist.
ctools_context_get_context_from_argument in includes/context.inc
Get a context from an argument.
ctools_context_get_context_from_relationship in includes/context.inc
Return a context from a relationship.
page_manager_delete_task_handler in page_manager/page_manager.module
Remove a task handler.

... See full list

File

includes/plugins.inc, line 842

Code

function ctools_plugin_load_function($module, $type, $id, $function_name) {
    $plugin = ctools_get_plugins($module, $type, $id);
    return ctools_plugin_get_function($plugin, $function_name);
}