Skip to content

Instantly share code, notes, and snippets.

@wowo
Created Sep 11, 2020
Embed
What would you like to do?
<container xmlns="http://symfony.com/schema/dic/services"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="[..]">
<parameters>
<parameter key="example.foo.repository.class">
Example\FooBundle\Repository\FooRepository</parameter>
<parameter key="example.foo.service.class">
Example\FooBundle\Service\FooService</parameter>
</parameters>
<services>
<service id="example.foo.repository"
class="%example.foo.repository.class%"
factory-service="doctrine.orm.entity_manager"
factory-method="getRepository">
<argument>ExampleFooBundle:Foo</argument>
</service>
<service id="example.foo.service"
class="%example.foo.service.class%">
<argument type="service" id="example.foo.repository" />
<argument type="service" id="logger" />
</service>
</services>
</container>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment