src/phpDocumentor/Descriptor/ServiceProvider.php
protected function addBuilder(Application $app)
    {
        if (extension_loaded('igbinary')) {
            $app['descriptor.builder.serializer'] = 'IgBinary';
        } else {
            $app['descriptor.builder.serializer'] = 'PhpSerialize';
        }

        $app['descriptor.builder'] = $app->share(
            function ($container) {
                $builder = new ProjectDescriptorBuilder(
                    $container['descriptor.builder.assembler.factory'],
                    $container['descriptor.filter'],
                    $container['validator']
                );
                $builder->setTranslator($container['translator']);

                return $builder;
            }
        );
    }
protected function addBuilder(Application $app)
    {
        if (extension_loaded('igbinary')) {
            $app['descriptor.builder.serializer'] = 'IgBinary';
        } else {
            $app['descriptor.builder.serializer'] = 'PhpSerialize';
        }

        $app['descriptor.builder'] = $app->share(
            function ($container) {
                $builder = new ProjectDescriptorBuilder(
                    $container['descriptor.builder.assembler.factory'],
                    $container['descriptor.filter'],
                    $container['validator']
                );
                $builder->setTranslator($container['translator']);

                return $builder;
            }
        );
    }
protected function addBuilder ( Application $ app ) { if ( extension_loaded ( 'igbinary' ) ) { $ app [ 'descriptor.builder.serializer' ] = 'IgBinary' ; } else { $ app [ 'descriptor.builder.serializer' ] = 'PhpSerialize' ; } $ app [ 'descriptor.builder' ] = $ app -> share ( function ( $ container ) { $ builder = new ProjectDescriptorBuilder ( $ container [ 'descriptor.builder.assembler.factory' ] , $ container [ 'descriptor.filter' ] , $ container [ 'validator' ] ) ; $ builder -> setTranslator ( $ container [ 'translator' ] ) ; return $ builder ; } ) ; }
Adds the Building mechanism using the key 'descriptor.builder'.

Please note that the type of serializer can be configured using the parameter 'descriptor.builder.serializer'; it
accepts any parameter that Zend\Serializer supports.

@param Application $app

@return void
Adds the Building mechanism using the key descriptor . builder .