Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit759e9b2

Browse files
committed
last tweaks from feedback
1 parent45500b3 commit759e9b2

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

‎service_container.rst‎

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -142,9 +142,9 @@ the service container *how* to instantiate it:
142142
// app/config/services.php
143143
TODO
144144
145-
That's it! Thanks to the ``AppBundle\`` line and ``resource`` key below it,all
146-
classesin the ``src/AppBundle/Service`` directory (and a few other directories)
147-
will automatically be added to the container.
145+
That's it! Thanks to the ``AppBundle\`` line and ``resource`` key below it,a service
146+
will be registered for each classin the ``src/AppBundle/Service`` directory (and
147+
the other directories listed).
148148

149149
Each service's "key" is its class name. You can use it immediately inside your controller::
150150

@@ -210,11 +210,11 @@ and set it on a ``$logger`` property::
210210
}
211211

212212
That's it! The container will *automatically* know to pass the ``logger`` service
213-
when instantiating the ``MessageGenerator``? How does it know to do this?
213+
when instantiating the ``MessageGenerator``. How does it know to do this?
214214
:doc:`Autowiring</service_container/autowiring>`. The key is the ``LoggerInterface``
215215
type-hint in your ``__construct()`` method and the ``autowire: true`` config in
216216
``services.yml``. When you type-hint an argument, the container will automatically
217-
find the matching service. If it can't or there is anyambuiguity, you'll see a clear
217+
find the matching service. If it can't or there is anyambiguity, you'll see a clear
218218
exception suggesting how to fix it.
219219

220220
Be sure to read more about:doc:`autowiring</service_container/autowiring>`.

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp