Symfony\Component\DependencyInjection\Definition::__construct PHP Method

__construct() public method

public __construct ( string | null $class = null, array $arguments = [] )
$class string | null The service class
$arguments array An array of arguments to pass to the service constructor
    public function __construct($class = null, array $arguments = array())
    {
        $this->class = $class;
        $this->arguments = $arguments;
    }

Usage Example

Example #1
0
    /**
     * Constructor.
     *
     * @param string $parent The id of Definition instance to decorate.
     *
     * @api
     */
    public function __construct($parent)
    {
        parent::__construct();

        $this->parent = $parent;
        $this->changes = array();
    }
All Usage Examples Of Symfony\Component\DependencyInjection\Definition::__construct