You are here

class ProjectExtension in Service Container 7.2

Same name and namespace in other branches
  1. 7 modules/providers/service_container_symfony/lib/Symfony/Component/DependencyInjection/Tests/Fixtures/includes/ProjectExtension.php \ProjectExtension

Hierarchy

Expanded class hierarchy of ProjectExtension

File

modules/providers/service_container_symfony/lib/Symfony/Component/DependencyInjection/Tests/Fixtures/includes/ProjectExtension.php, line 7

View source
class ProjectExtension implements ExtensionInterface {
  public function load(array $configs, ContainerBuilder $configuration) {
    $config = call_user_func_array('array_merge', $configs);
    $configuration
      ->setDefinition('project.service.bar', new Definition('FooClass'));
    $configuration
      ->setParameter('project.parameter.bar', isset($config['foo']) ? $config['foo'] : 'foobar');
    $configuration
      ->setDefinition('project.service.foo', new Definition('FooClass'));
    $configuration
      ->setParameter('project.parameter.foo', isset($config['foo']) ? $config['foo'] : 'foobar');
    return $configuration;
  }
  public function getXsdValidationBasePath() {
    return false;
  }
  public function getNamespace() {
    return 'http://www.example.com/schema/project';
  }
  public function getAlias() {
    return 'project';
  }
  public function getConfiguration(array $config, ContainerBuilder $container) {
  }

}

Members

Namesort descending Modifiers Type Description Overrides
ProjectExtension::getAlias public function Returns the recommended alias to use in XML. Overrides ExtensionInterface::getAlias 1
ProjectExtension::getConfiguration public function
ProjectExtension::getNamespace public function Returns the namespace to be used for this extension (XML namespace). Overrides ExtensionInterface::getNamespace 1
ProjectExtension::getXsdValidationBasePath public function Returns the base path for the XSD files. Overrides ExtensionInterface::getXsdValidationBasePath 1
ProjectExtension::load public function Loads a specific configuration. Overrides ExtensionInterface::load