File tree Expand file tree Collapse file tree 1 file changed +4
-2
lines changed
Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -18,15 +18,16 @@ Please read the docs of [lib-country](https://github.com/phine/lib-country) firs
1818### Using Services
1919``` php
2020// From ServiceManager
21- /** @var Phine\Country\Loader\Loader */
21+ /** @var Phine\Country\Loader\Loader $countryLoader */
2222$countryLoader = $serviceManager->get('CountryLoader');
2323```
2424
2525### Using hydrator strategy
2626``` php
2727$strategy = new HtCountryModule\Hydrator\Strategy\CountryStrategy;
28+ // or $strategy = $serviceManager->get('HtCountryModule\Hydrator\Strategy\CountryStrategy');
2829
29- /** @var Phine\Country\Country */
30+ /** @var Phine\Country\Country $country */
3031$country = $strategy->hydrate('US');
3132
3233echo $strategy->extract($country); // will print US
@@ -35,6 +36,7 @@ echo $strategy->extract($country); // will print US
3536### Using country validator
3637``` php
3738$validator = new HtCountryModule\Validator\CountryValidator;
39+ // or $validator = $serviceManager->get('ValidatorManager')->get('CountryValidator');
3840var_dump($validator->isValid('asdfasfd')); // bool(false)
3941var_dump($validator->isValid('US')); // bool(true)
4042```
You can’t perform that action at this time.
0 commit comments