You are here

public function FeedsSource::configDefaults in Feeds 7.2

Same name and namespace in other branches
  1. 6 includes/FeedsSource.inc \FeedsSource::configDefaults()
  2. 7 includes/FeedsSource.inc \FeedsSource::configDefaults()

Return defaults for feed configuration.

Return value

array The default feed configuration, keyed per Feeds plugin.

Overrides FeedsConfigurable::configDefaults

File

includes/FeedsSource.inc, line 1109
Definition of FeedsSourceInterface, FeedsState and FeedsSource class.

Class

FeedsSource
Holds the source of a feed to import.

Code

public function configDefaults() {

  // Collect information from plugins.
  $defaults = array();
  foreach ($this->importer->plugin_types as $type) {
    if ($this->importer->{$type}
      ->hasSourceConfig()) {
      $defaults[get_class($this->importer->{$type})] = $this->importer->{$type}
        ->sourceDefaults();
    }
  }
  return $defaults;
}