src/Admin/Model/DoctrineRestServiceModel.php
/**
     * Merge entity and collection class into metadata, if found
     *
     * @param string $controllerServiceName
     * @param DoctrineRestServiceEntity $metadata
     * @param array $config
     */
Merge entity and collection class into metadata, if found
@param string $controllerServiceName
@param DoctrineRestServiceEntity $metadata
@param array $config
Merge entity and collection class into metadata if found @param string $controllerServiceName @param DoctrineRestServiceEntity $metadata @param array $config
protected function mergeHalConfig($controllerServiceName, DoctrineRestServiceEntity $metadata, array $config)
    {
        if (! isset($config['zf-hal']['metadata_map'])) {
            return;
        }
        $config = $config['zf-hal']['metadata_map'];
        $entityClass     = $this->deriveEntityClass($controllerServiceName, $metadata, $config);
        $collectionClass = $this->deriveCollectionClass($controllerServiceName, $metadata, $config);
        $merge           = [];
        if (isset($config[$entityClass])) {
            $merge['entity_class'] = $entityClass;
        }
        if (isset($config[$collectionClass])) {
            $merge['collection_class'] = $collectionClass;
        }
        $metadata->exchangeArray($merge);
    }
protected function mergeHalConfig ( $ controllerServiceName , DoctrineRestServiceEntity $ metadata , array $ config ) { if ( ! isset ( $ config [ 'zf-hal' ] [ 'metadata_map' ] ) ) { return ; } $ config = $ config [ 'zf-hal' ] [ 'metadata_map' ] ; $ entityClass = $ this -> deriveEntityClass ( $ controllerServiceName , $ metadata , $ config ) ; $ collectionClass = $ this -> deriveCollectionClass ( $ controllerServiceName , $ metadata , $ config ) ; $ merge = [ ] ; if ( isset ( $ config [ $ entityClass ] ) ) { $ merge [ 'entity_class' ] = $ entityClass ; } if ( isset ( $ config [ $ collectionClass ] ) ) { $ merge [ 'collection_class' ] = $ collectionClass ; } $ metadata -> exchangeArray ( $ merge ) ; }
Merge entity and collection class into metadata, if found
 @param string $controllerServiceName
 @param DoctrineRestServiceEntity $metadata
 @param array $config
Merge entity and collection class into metadata if found @param string $controllerServiceName @param DoctrineRestServiceEntity $metadata @param array $config