Skip to content

Commit e677f4e

Browse files
author
Jon Acker
committed
Fix info in manual
1 parent 07d15dc commit e677f4e

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,7 @@ $container = Mage::helper('inviqa_symfonyContainer/containerProvider')->getConta
107107
### Test Environment
108108
The configuration builder reads the magento configuration node "global/environment" and uses this to switch the container generator to test environment. The string expected in "global/environment" node is "test". In this mode, the container generator will read addtiaional services_test.xml files, which will override services defined in services.xml if their id's match. In this way, you can use "mock" services for integration testing purposes. (see additional documentation in https://github.com/inviqa/symfony-container-generator)
109109

110-
### Providing Magento Store Config Values to Service Constructors (since version 0.5.0)
110+
### Providing Magento Store Config Values to Service Constructors
111111
If your service requires a value from the store config, something which would normaly require calling Mage::getStoreConfig('web/secure/base_url') for example, you can use the special tag mage.config in place of an <argument> node in your service definition. The "key" attribute is a regular magento store config key. This will simply add the value of requested store config to the list of service constructor arguments:
112112

113113
```xml
@@ -134,7 +134,7 @@ class Acme_Service
134134

135135
If the specified key does not exist, or is empty, the argument will be null or empty.
136136

137-
### Explicitly Providing Dependencies via __dependencies
137+
### Explicitly Providing Dependencies via __dependencies (since version 0.5.0)
138138

139139
Certain Magento classes, such as controllers, observers and blocks are instantiated by the system and therefore cannot be instantiated by the DI Container, nevertheless an additional service tag can make it easier to explicitly provide dependencies to these classes. Adding the mage.injectable tag to a service will allow you to provide this services dependencies *after* the service has been instantiated. The services arguments will be provided to the __dependencies method provided you call ServiceInjector::setupDependencies($class) after service instantiation, and your service has a __dependencies method that contains typehints that match the arguments type an order.
140140

0 commit comments

Comments
 (0)