From 1c57f1bdf05da078493b774c9e8d77ee8b46b4bb Mon Sep 17 00:00:00 2001 From: Matthew Weier O'Phinney Date: Wed, 17 Feb 2021 11:04:00 -0600 Subject: [PATCH] docs: minor changes in preparation for merging for 2.10.0 - one sentence per line - reference "since 2.10.0" for new features Signed-off-by: Matthew Weier O'Phinney --- docs/book/plugin-manager.md | 18 +++++++----------- 1 file changed, 7 insertions(+), 11 deletions(-) diff --git a/docs/book/plugin-manager.md b/docs/book/plugin-manager.md index 321cd86..c7e89fd 100644 --- a/docs/book/plugin-manager.md +++ b/docs/book/plugin-manager.md @@ -1,30 +1,26 @@ # Plugin Manager -The `AdapterPluginManager` extends the laminas-servicemanager -`AbstractPluginManager`, and has the following behaviors: +The `AdapterPluginManager` extends the laminas-servicemanager `AbstractPluginManager`, and has the following behaviors: - It will only return `Laminas\Serializer\Adapter\AdapterInterface` instances. -- It defines short-name aliases for all shipped serializers (the class name minus - the namespace), in a variety of casing combinations. +- **Since 2.10.0**: It defines short-name aliases for all shipped serializers (the class name minus the namespace), in a variety of casing combinations. - All services are shared by default; a new instance will only be created once and shared each time you call `get()`. ## Factory -`Laminas\Serializer\AdapterPluginManager` is mapped to the factory -`Laminas\Serializer\AdapterPluginManagerFactory` when wired to the dependency -injection container. +`Laminas\Serializer\AdapterPluginManager` is mapped to the factory. +`Laminas\Serializer\AdapterPluginManagerFactory` when wired to the dependency injection container. The factory will be automatically registered when loading/installing the `Laminas\Serializer` module in `laminas-mvc` and/or loading/installing the `ConfigProvider` into a Mezzio application. -The factory will look for the `config` service, and use the `serializers` -configuration key to seed it with additional services. This configuration key -should map to an array that follows [standard laminas-servicemanager configuration](https://docs.laminas.dev/laminas-servicemanager/configuring-the-service-manager/). +Since version 2.10.0, the factory will look for the `config` service, and use the `serializers` configuration key to seed it with additional services. +This configuration key should map to an array that follows [standard laminas-servicemanager configuration](https://docs.laminas.dev/laminas-servicemanager/configuring-the-service-manager/). To add your own serializer you can add the following configuration: ```php // config/autoload/serializers.global.php -return [ +return [ 'serializers' => [ 'factories' => [ \App\MyCustomSerializer::class => \App\Container\MyCustomSerializerFactory::class,