public function createAlias($name, $config){
        $handle = fopen(vibius_BASEPATH.$this->aliasCache.$name.'.php','w+');
        if(!$handle){
            throw new Exception('Unable to create alias, fopen not successful');
        }
        $template = $this->getAliasTemplate();
        $template = str_replace('{$className}', $name, $template);
        $template = str_replace('{$providerName}', $config['provider'], $template);
        
        fwrite($handle, $template);
        fclose($handle);
        $this->aliases[$name] = true;
        return true;
    }
public function createAlias($name, $config){
        $handle = fopen(vibius_BASEPATH.$this->aliasCache.$name.'.php','w+');
        if(!$handle){
            throw new Exception('Unable to create alias, fopen not successful');
        }
        $template = $this->getAliasTemplate();
        $template = str_replace('{$className}', $name, $template);
        $template = str_replace('{$providerName}', $config['provider'], $template);
        
        fwrite($handle, $template);
        fclose($handle);
        $this->aliases[$name] = true;
        return true;
    }
public function createAlias ( $ name , $ config ) { $ handle = fopen ( vibius_BASEPATH . $ this -> aliasCache . $ name . '.php' , 'w+' ) ; if ( ! $ handle ) { throw new Exception ( 'Unable to create alias, fopen not successful' ) ; } $ template = $ this -> getAliasTemplate ( ) ; $ template = str_replace ( '{$className}' , $ name , $ template ) ; $ template = str_replace ( '{$providerName}' , $ config [ 'provider' ] , $ template ) ; fwrite ( $ handle , $ template ) ; fclose ( $ handle ) ; $ this -> aliases [ $ name ] = true ; return true ; }
Method is used to create an alias, from specified parameters.
@param string $name Name of the alias to be created
@param string $config Configuration array of created alias
Method is used to create an alias from specified parameters .