namespace Symfony\Component\HttpKernel\Bundle;
+use Symfony\Component\Console\Application;
+use Symfony\Component\DependencyInjection\Container;
use Symfony\Component\DependencyInjection\ContainerAwareTrait;
use Symfony\Component\DependencyInjection\ContainerBuilder;
-use Symfony\Component\DependencyInjection\Container;
-use Symfony\Component\Console\Application;
-use Symfony\Component\Finder\Finder;
use Symfony\Component\DependencyInjection\Extension\ExtensionInterface;
+use Symfony\Component\Finder\Finder;
/**
* An implementation of BundleInterface that adds a few conventions
private $namespace;
/**
- * Boots the Bundle.
+ * {@inheritdoc}
*/
public function boot()
{
}
/**
- * Shutdowns the Bundle.
+ * {@inheritdoc}
*/
public function shutdown()
{
}
/**
- * Builds the bundle.
- *
- * It is only ever called once when the cache is empty.
+ * {@inheritdoc}
*
* This method can be overridden to register compilation passes,
* other extensions, ...
if (null !== $extension) {
if (!$extension instanceof ExtensionInterface) {
- throw new \LogicException(sprintf('Extension %s must implement Symfony\Component\DependencyInjection\Extension\ExtensionInterface.', get_class($extension)));
+ throw new \LogicException(sprintf('Extension %s must implement Symfony\Component\DependencyInjection\Extension\ExtensionInterface.', \get_class($extension)));
}
// check naming convention
$expectedAlias = Container::underscore($basename);
if ($expectedAlias != $extension->getAlias()) {
- throw new \LogicException(sprintf(
- 'Users will expect the alias of the default extension of a bundle to be the underscored version of the bundle name ("%s"). You can override "Bundle::getContainerExtension()" if you want to use "%s" or another alias.',
- $expectedAlias, $extension->getAlias()
- ));
+ throw new \LogicException(sprintf('Users will expect the alias of the default extension of a bundle to be the underscored version of the bundle name ("%s"). You can override "Bundle::getContainerExtension()" if you want to use "%s" or another alias.', $expectedAlias, $extension->getAlias()));
}
$this->extension = $extension;
}
/**
- * Gets the Bundle namespace.
- *
- * @return string The Bundle namespace
+ * {@inheritdoc}
*/
public function getNamespace()
{
}
/**
- * Gets the Bundle directory path.
- *
- * @return string The Bundle absolute path
+ * {@inheritdoc}
*/
public function getPath()
{
if (null === $this->path) {
$reflected = new \ReflectionObject($this);
- $this->path = dirname($reflected->getFileName());
+ $this->path = \dirname($reflected->getFileName());
}
return $this->path;
}
/**
- * Returns the bundle parent name.
- *
- * @return string|null The Bundle parent name it overrides or null if no parent
+ * {@inheritdoc}
*/
public function getParent()
{
}
/**
- * Returns the bundle name (the class short name).
- *
- * @return string The Bundle name
+ * {@inheritdoc}
*/
final public function getName()
{