function hook_feeds_plugins in Feeds 7.2
Same name and namespace in other branches
- 8.2 feeds.api.php \hook_feeds_plugins()
- 6 feeds.api.php \hook_feeds_plugins()
- 7 feeds.api.php \hook_feeds_plugins()
Declare Feeds plugins.
Implement this hook to declare Fetcher, Parser or Processor plugins for Feeds. For a working example implementation, see feeds_feeds_plugin(). In order for this hook to be invoked, you MUST implement hook_ctools_plugin_api() as well.
See also
feeds_feeds_plugin()
Related topics
1 function implements hook_feeds_plugins()
Note: this list is generated by pattern matching, so it may include some functions that are not actually implementations of this hook.
- feeds_feeds_plugins in ./
feeds.module - Implements hook_feeds_plugins().
1 invocation of hook_feeds_plugins()
- feeds_system_info_alter in ./
feeds.module - Implements hook_system_info_alter().
File
- ./
feeds.api.php, line 45 - Documentation of Feeds hooks.
Code
function hook_feeds_plugins() {
$info = array();
$info['MyFetcher'] = array(
'name' => 'My Fetcher',
'description' => 'Fetches my stuff.',
'help' => 'More verbose description here. Will be displayed on fetcher selection menu.',
'handler' => array(
'parent' => 'FeedsFetcher',
'class' => 'MyFetcher',
'file' => 'MyFetcher.inc',
// Feeds will look for MyFetcher.inc in the my_module directory.
'path' => drupal_get_path('module', 'my_module'),
),
);
$info['MyParser'] = array(
'name' => 'ODK parser',
'description' => 'Parse my stuff.',
'help' => 'More verbose description here. Will be displayed on parser selection menu.',
'handler' => array(
// Being directly or indirectly an extension of FeedsParser makes a plugin
// a parser plugin.
'parent' => 'FeedsParser',
'class' => 'MyParser',
'file' => 'MyParser.inc',
'path' => drupal_get_path('module', 'my_module'),
),
);
$info['MyProcessor'] = array(
'name' => 'ODK parser',
'description' => 'Process my stuff.',
'help' => 'More verbose description here. Will be displayed on processor selection menu.',
'handler' => array(
'parent' => 'FeedsProcessor',
'class' => 'MyProcessor',
'file' => 'MyProcessor.inc',
'path' => drupal_get_path('module', 'my_module'),
),
);
return $info;
}