class BundleTestBundle

Test bundle class.

Hierarchy

Expanded class hierarchy of BundleTestBundle

File

drupal/core/modules/system/tests/modules/bundle_test/lib/Drupal/bundle_test/BundleTestBundle.php, line 18
Definition of Drupal\bundle_test\BundleTestBundle.

Namespace

Drupal\bundle_test
View source
class BundleTestBundle extends Bundle {
  public function build(ContainerBuilder $container) {
    $container
      ->register('bundle_test_class', 'Drupal\\bundle_test\\TestClass')
      ->addTag('event_subscriber');

    // Override a default bundle used by core to a dummy class.
    $container
      ->register('file.usage', 'Drupal\\bundle_test\\TestFileUsage');
  }

}

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
BundleTestBundle::build public function Builds the bundle. Overrides Bundle::build
ContainerAware::$container protected property @api
ContainerAware::setContainer public function Sets the Container associated with this Controller. Overrides ContainerAwareInterface::setContainer