This repository has been archived on 2023-08-20. You can view files and clone it, but cannot push or open issues or pull requests.
symfony/src/Symfony/Component/DependencyInjection/ParameterBag/ParameterBagInterface.php

68 lines
1.5 KiB
PHP
Raw Normal View History

2010-06-27 17:28:29 +01:00
<?php
namespace Symfony\Component\DependencyInjection\ParameterBag;
2010-06-27 17:28:29 +01:00
/*
* This file is part of the Symfony framework.
*
* (c) Fabien Potencier <fabien.potencier@symfony-project.com>
*
* This source file is subject to the MIT license that is bundled
* with this source code in the file LICENSE.
*/
/**
* ParameterBagInterface.
*
* @author Fabien Potencier <fabien.potencier@symfony-project.com>
*/
interface ParameterBagInterface
{
/**
* Clears all parameters.
*/
public function clear();
/**
* Adds parameters to the service container parameters.
*
* @param array $parameters An array of parameters
*/
public function add(array $parameters);
/**
* Gets the service container parameters.
*
* @return array An array of parameters
*/
public function all();
/**
* Gets a service container parameter.
*
* @param string $name The parameter name
*
* @return mixed The parameter value
*
* @throws \InvalidArgumentException if the parameter is not defined
*/
public function get($name);
/**
* Sets a service container parameter.
*
* @param string $name The parameter name
* @param mixed $parameters The parameter value
*/
public function set($name, $value);
/**
* Returns true if a parameter name is defined.
*
* @param string $name The parameter name
*
* @return Boolean true if the parameter name is defined, false otherwise
*/
public function has($name);
}