You are here

public static function WorkspaceSwitcherBlock::create in Drupal 10

Same name and namespace in other branches
  1. 8 core/modules/workspaces/src/Plugin/Block/WorkspaceSwitcherBlock.php \Drupal\workspaces\Plugin\Block\WorkspaceSwitcherBlock::create()
  2. 9 core/modules/workspaces/src/Plugin/Block/WorkspaceSwitcherBlock.php \Drupal\workspaces\Plugin\Block\WorkspaceSwitcherBlock::create()

File

core/modules/workspaces/src/Plugin/Block/WorkspaceSwitcherBlock.php, line 60

Class

WorkspaceSwitcherBlock
Provides a 'Workspace switcher' block.

Namespace

Drupal\workspaces\Plugin\Block

Code

public static function create(ContainerInterface $container, array $configuration, $plugin_id, $plugin_definition) {
  return new static($configuration, $plugin_id, $plugin_definition, $container
    ->get('form_builder'), $container
    ->get('entity_type.manager'));
}