tbn / getsetforeignnormalizer-bundle
This package is abandoned and no longer maintained.
No replacement package was suggested.
There is no license information available for the latest version (v2.0.1) of this package.
Add the getsetforeignnormalizer service
v2.0.1
2015-10-06 22:01 UTC
Requires (Dev)
- php: >=5.3.0
- doctrine/data-fixtures: ^1.1
- doctrine/doctrine-bundle: >=1.4
- doctrine/orm: ~2.2,>=2.2.3,<2.5
- nelmio/alice: >=2.1
- phpunit/phpunit: ~4.4
- sensio/distribution-bundle: >=4.0
- sensio/framework-extra-bundle: ~3.0,>=3.0.2
- symfony/class-loader: 2.3.*
- symfony/symfony: >=2.7
- twig/extensions: >=1.0
README
DEPRECATED: This bundle is not usefull anymore, use Symfony serializer/normalizer instead
This bundle gives a service that permits to normalize a doctrine entity.
The entity is normalized and the ids of the foreign entities of the entity are also normalized.
Install
composer require "tbn/getsetforeignnormalizer-bundle"
Usage
Get the service in your controller
$normalizer = $this->get('get_set_foreign_normalizer');
If you do not want to normalize some attributes, use the setIgnoredAttributes parameter
$normalizer->normalize($entities, true, false, array('allImages'));//avoid the getAllImages function
The foreign entities are not fully normalized by default
You can normalize all entities using
$normalizer->normalize($entities, true);