<?xml version="1.0" ?>

<container xmlns="http://symfony.com/schema/dic/services"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="http://symfony.com/schema/dic/services http://symfony.com/schema/dic/services/services-1.0.xsd">

    <parameters>
    	<parameter key="office_brain_company.company_manager">OfficeBrain\Bundle\CompanyBundle\Manager\Service\CompanyService</parameter>
    </parameters>
    <services>
    	<!-- to create once instance static Factory method -->
    	 <service id="office_brain_company_factory" class="%office_brain_company.company_manager%"></service>
	    
    	<service id="office_brain_company_manager" class="%office_brain_company.company_manager%" scope="request">
    		<factory service="office_brain_company_factory" method="initFactory"></factory>
            <argument type="service" id="doctrine.orm.entity_manager" />
            <argument type="service" id="request" />
            <argument type="service" id="office_brain_session_manager"/>
            <argument type="service" id="knp_paginator"/>
            <argument>%company_absolute_path%</argument>
            <argument>%company_relative_path%</argument>
    	</service>
    	
    </services>
</container>
