vendor/2amigos/yii2-usuario/src/User/Bootstrap.php
/**
     * Builds class map according to user configuration.
     *
     * @param array $userClassMap user configuration on the module
     *
     * @throws Exception
     * @return array
     */
Builds class map according to user configuration.
@param array $userClassMap user configuration on the module

@throws Exception
@return array
Builds class map according to user configuration . @param array $userClassMap user configuration on the module @throws Exception @return array
protected function buildClassMap(array $userClassMap)
    {
        $map = [];
        $defaults = [
            'User' => 'Da\User\Model\User',
            'SocialNetworkAccount' => 'Da\User\Model\SocialNetworkAccount',
            'Profile' => 'Da\User\Model\Profile',
            'Token' => 'Da\User\Model\Token',
            'Assignment' => 'Da\User\Model\Assignment',
            'Permission' => 'Da\User\Model\Permission',
            'Role' => 'Da\User\Model\Role',
            'UserSearch' => 'Da\User\Search\UserSearch',
            'PermissionSearch' => 'Da\User\Search\PermissionSearch',
            'RoleSearch' => 'Da\User\Search\RoleSearch',
            'RegistrationForm' => 'Da\User\Form\RegistrationForm',
            'ResendForm' => 'Da\User\Form\ResendForm',
            'LoginForm' => 'Da\User\Form\LoginForm',
            'SettingsForm' => 'Da\User\Form\SettingsForm',
            'RecoveryForm' => 'Da\User\Form\RecoveryForm',
        ];
        $routes = [
            'Da\User\Model' => [
                'User',
                'SocialNetworkAccount',
                'Profile',
                'Token',
                'Assignment',
                'Permission',
                'Role',
            ],
            'Da\User\Search' => [
                'UserSearch',
                'PermissionSearch',
                'RoleSearch',
            ],
            'Da\User\Form' => [
                'RegistrationForm',
                'ResendForm',
                'LoginForm',
                'SettingsForm',
                'RecoveryForm',
            ],
        ];
        $mapping = array_merge($defaults, $userClassMap);
        foreach ($mapping as $name => $definition) {
            $map[$this->getRoute($routes, $name) . "\\$name"] = $definition;
        }
        return $map;
    }
protected function buildClassMap ( array $ userClassMap ) { $ map = [ ] ; $ defaults = [ 'User' => 'Da\User\Model\User' , 'SocialNetworkAccount' => 'Da\User\Model\SocialNetworkAccount' , 'Profile' => 'Da\User\Model\Profile' , 'Token' => 'Da\User\Model\Token' , 'Assignment' => 'Da\User\Model\Assignment' , 'Permission' => 'Da\User\Model\Permission' , 'Role' => 'Da\User\Model\Role' , 'UserSearch' => 'Da\User\Search\UserSearch' , 'PermissionSearch' => 'Da\User\Search\PermissionSearch' , 'RoleSearch' => 'Da\User\Search\RoleSearch' , 'RegistrationForm' => 'Da\User\Form\RegistrationForm' , 'ResendForm' => 'Da\User\Form\ResendForm' , 'LoginForm' => 'Da\User\Form\LoginForm' , 'SettingsForm' => 'Da\User\Form\SettingsForm' , 'RecoveryForm' => 'Da\User\Form\RecoveryForm' , ] ; $ routes = [ 'Da\User\Model' => [ 'User' , 'SocialNetworkAccount' , 'Profile' , 'Token' , 'Assignment' , 'Permission' , 'Role' , ] , 'Da\User\Search' => [ 'UserSearch' , 'PermissionSearch' , 'RoleSearch' , ] , 'Da\User\Form' => [ 'RegistrationForm' , 'ResendForm' , 'LoginForm' , 'SettingsForm' , 'RecoveryForm' , ] , ] ; $ mapping = array_merge ( $ defaults , $ userClassMap ) ; foreach ( $ mapping as $ name => $ definition ) { $ map [ $ this -> getRoute ( $ routes , $ name ) . " \\ $ name " ] = $ definition ; } return $ map ; }
Builds class map according to user configuration.
Builds class map according to user configuration .
// --- models // --- search // --- forms