Skip to content

Instantly share code, notes, and snippets.

@wowo
Created September 11, 2020 07:18
Show Gist options
  • Save wowo/069ff05cc057fb797ff29e7780ac8742 to your computer and use it in GitHub Desktop.
Save wowo/069ff05cc057fb797ff29e7780ac8742 to your computer and use it in GitHub Desktop.
<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