source/Setup/Controller/ModuleStateMapGenerator.php
private function applyModuleStateMapFilterFunction($moduleStateMap, $helpFunction, $moduleStateMapUpdateFunction)
    {
        if (!$helpFunction) {
            return $moduleStateMap;
        }

        foreach ($this->iterateThroughModuleStateMap($moduleStateMap) as list($groupId, $moduleIndex, $moduleData)) {
            $moduleStateMap[$groupId][$moduleIndex] = $moduleStateMapUpdateFunction($moduleData, $helpFunction);
        }

        return $moduleStateMap;
    }
private function applyModuleStateMapFilterFunction($moduleStateMap, $helpFunction, $moduleStateMapUpdateFunction)
    {
        if (!$helpFunction) {
            return $moduleStateMap;
        }

        foreach ($this->iterateThroughModuleStateMap($moduleStateMap) as list($groupId, $moduleIndex, $moduleData)) {
            $moduleStateMap[$groupId][$moduleIndex] = $moduleStateMapUpdateFunction($moduleData, $helpFunction);
        }

        return $moduleStateMap;
    }
private function applyModuleStateMapFilterFunction ( $ moduleStateMap , $ helpFunction , $ moduleStateMapUpdateFunction ) { if ( ! $ helpFunction ) { return $ moduleStateMap ; } foreach ( $ this -> iterateThroughModuleStateMap ( $ moduleStateMap ) as list ( $ groupId , $ moduleIndex , $ moduleData ) ) { $ moduleStateMap [ $ groupId ] [ $ moduleIndex ] = $ moduleStateMapUpdateFunction ( $ moduleData , $ helpFunction ) ; } return $ moduleStateMap ; }
Apply filter function to update the contents of module state map.

@param array    $moduleStateMap               An array of format described in `getModuleStateMap`.
@param \Closure $helpFunction                 Help function which will be passed to moduleStateMapUpdateFunction
as 2nd argument.
@param \Closure $moduleStateMapUpdateFunction Function which will be used to modify contents of module state map.

@return array An array of format described in `getModuleStateMap`.
Apply filter function to update the contents of module state map .