ContainerBuilder::prependExtensionConfig()

prependExtensionConfig(string $name, array $config) Prepends a config array to the configs of the given extension. Parameters string $name The name of the extension array $config The config to set

ContainerBuilder::register()

Definition register(string $id, string $class = null) Registers a service definition. This methods allows for simple registration of service definition with a fluid interface. Parameters string $id The service identifier string $class The service class Return Value Definition A Definition instance

ContainerBuilder::removeAlias()

removeAlias(string $alias) Removes an alias. Parameters string $alias The alias to remove

ContainerBuilder::removeDefinition()

removeDefinition(string $id) Removes a service definition. Parameters string $id The service identifier

ContainerBuilder::resolveServices()

mixed resolveServices(mixed $value) Replaces service references by the real service instance and evaluates expressions. Parameters mixed $value A value Return Value mixed The same value with all service references replaced by the real service instances and all expressions evaluated

ContainerBuilder::registerExtension()

registerExtension(ExtensionInterface $extension) Registers an extension. Parameters ExtensionInterface $extension An extension instance

ContainerBuilder::loadFromExtension()

ContainerBuilder loadFromExtension(string $extension, array $values = array()) Loads the configuration for an extension. Parameters string $extension The extension alias or namespace array $values An array of values that customizes the extension Return Value ContainerBuilder The current instance Exceptions BadMethodCallException When this ContainerBuilder is frozen LogicException if the container is frozen

ContainerBuilder::isTrackingResources()

bool isTrackingResources() Checks if resources are tracked. Return Value bool true if resources are tracked, false otherwise

ContainerBuilder::hasDefinition()

bool hasDefinition(string $id) Returns true if a service definition exists under the given identifier. Parameters string $id The service identifier Return Value bool true if the service definition exists, false otherwise

ContainerBuilder::merge()

merge(ContainerBuilder $container) Merges a ContainerBuilder with the current ContainerBuilder configuration. Service definitions overrides the current defined ones. But for parameters, they are overridden by the current ones. It allows the parameters passed to the container constructor to have precedence over the loaded ones. $container = new ContainerBuilder(array('foo' => 'bar')); $loader = new LoaderXXX($container); $loader->load('resource_name'); $container->register('f