You are here

public static function ConfigSyncImportForm::create in Configuration Synchronizer 8.2

Instantiates a new instance of this class.

This is a factory method that returns a new instance of this class. The factory should pass any needed dependencies into the constructor of this class, but not the container itself. Every call to this method must return a new instance of this class; that is, it may not implement a singleton.

Parameters

\Symfony\Component\DependencyInjection\ContainerInterface $container: The service container this instance should use.

Overrides ConfigDistroImportForm::create

File

src/Form/ConfigSyncImportForm.php, line 59

Class

ConfigSyncImportForm

Namespace

Drupal\config_sync\Form

Code

public static function create(ContainerInterface $container) {
  $class = parent::create($container);
  $class->configSyncLister = $container
    ->get('config_sync.lister');
  $class->configUpdateLister = $container
    ->get('config_update.config_list');
  $class->moduleHandler = $container
    ->get('module_handler');
  $class->themeHandler = $container
    ->get('theme_handler');
  $class->state = $container
    ->get('state');
  $class->configFilterManager = $container
    ->get('plugin.manager.config_filter');
  return $class;
}