public static function FeedsConfigurable::instance in Feeds 8.2
Instantiate a FeedsConfigurable object.
Don't use directly, use feeds_importer() or feeds_plugin() instead.
2 calls to FeedsConfigurable::instance()
- feeds_importer in ./
feeds.module - Gets an importer instance.
- feeds_plugin in ./
feeds.module - Gets an instance of a class for a given plugin and id.
1 method overrides FeedsConfigurable::instance()
- FeedsSource::instance in lib/
Drupal/ feeds/ FeedsSource.php - Instantiate a unique object per class/id/feed_nid. Don't use directly, use feeds_source() instead.
File
- lib/
Drupal/ feeds/ Plugin/ FeedsConfigurable.php, line 58 - FeedsConfigurable and helper functions.
Class
- FeedsConfigurable
- Base class for configurable classes. Captures configuration handling, form handling and distinguishes between in-memory configuration and persistent configuration.
Namespace
Drupal\feeds\PluginCode
public static function instance($class, $id) {
// This is useful at least as long as we're developing.
if (empty($id)) {
throw new Exception(t('Empty configuration identifier.'));
}
if (!isset(static::$instances[$class][$id])) {
static::$instances[$class][$id] = new $class($id);
}
return static::$instances[$class][$id];
}