class ViewsBundle

Views dependency injection container.

Hierarchy

Expanded class hierarchy of ViewsBundle

1 file declares its use of ViewsBundle
ViewUnitTestBase.php in drupal/core/modules/views/lib/Drupal/views/Tests/ViewUnitTestBase.php
Contains \Drupal\views\Tests\ViewUnitTestBase.

File

drupal/core/modules/views/lib/Drupal/views/ViewsBundle.php, line 17
Definition of Drupal\views\ViewsBundle.

Namespace

Drupal\views
View source
class ViewsBundle extends Bundle {

  /**
   * Overrides Symfony\Component\HttpKernel\Bundle\Bundle::build().
   */
  public function build(ContainerBuilder $container) {
    foreach (ViewExecutable::getPluginTypes() as $type) {
      if ($type == 'join') {
        $container
          ->register('plugin.manager.views.join', 'Drupal\\views\\Plugin\\Type\\JoinManager');
      }
      elseif ($type == 'wizard') {
        $container
          ->register('plugin.manager.views.wizard', 'Drupal\\views\\Plugin\\Type\\WizardManager');
      }
      else {
        $container
          ->register("plugin.manager.views.{$type}", 'Drupal\\views\\Plugin\\Type\\PluginManager')
          ->addArgument($type);
      }
    }
  }

}

Members

Namesort descending Modifiers Type Description Overrides
Bundle::$extension protected property
Bundle::$name protected property
Bundle::$reflected protected property
Bundle::boot public function Boots the Bundle. Overrides BundleInterface::boot
Bundle::getContainerExtension public function Returns the bundle's container extension. Overrides BundleInterface::getContainerExtension
Bundle::getName final public function Returns the bundle name (the class short name). Overrides BundleInterface::getName
Bundle::getNamespace public function Gets the Bundle namespace. Overrides BundleInterface::getNamespace
Bundle::getParent public function Returns the bundle parent name. Overrides BundleInterface::getParent
Bundle::getPath public function Gets the Bundle directory path. Overrides BundleInterface::getPath
Bundle::registerCommands public function Finds and registers Commands.
Bundle::shutdown public function Shutdowns the Bundle. Overrides BundleInterface::shutdown
ContainerAware::$container protected property @api
ContainerAware::setContainer public function Sets the Container associated with this Controller. Overrides ContainerAwareInterface::setContainer
ViewsBundle::build public function Overrides Symfony\Component\HttpKernel\Bundle\Bundle::build(). Overrides Bundle::build