public static function checkAliasVersion(AssetTypeInterface $assetType, $dependency, $version)
    {
        $pos = strpos($version, '#');

        if ($pos > 0 && !preg_match('{[0-9a-f]{40}$}', $version)) {
            $dependency = substr($version, 0, $pos);
            $version = substr($version, $pos);
            $searchVerion = substr($version, 1);

            if (false === strpos($version, '*') && Validator::validateTag($searchVerion, $assetType)) {
                $dependency .= '-'.str_replace('#', '', $version);
            }
        }

        return array($dependency, $version);
    }
public static function checkAliasVersion(AssetTypeInterface $assetType, $dependency, $version)
    {
        $pos = strpos($version, '#');

        if ($pos > 0 && !preg_match('{[0-9a-f]{40}$}', $version)) {
            $dependency = substr($version, 0, $pos);
            $version = substr($version, $pos);
            $searchVerion = substr($version, 1);

            if (false === strpos($version, '*') && Validator::validateTag($searchVerion, $assetType)) {
                $dependency .= '-'.str_replace('#', '', $version);
            }
        }

        return array($dependency, $version);
    }
public static function checkAliasVersion ( AssetTypeInterface $ assetType , $ dependency , $ version ) { $ pos = strpos ( $ version , '#' ) ; if ( $ pos > 0 && ! preg_match ( '{[0-9a-f]{40}$}' , $ version ) ) { $ dependency = substr ( $ version , 0 , $ pos ) ; $ version = substr ( $ version , $ pos ) ; $ searchVerion = substr ( $ version , 1 ) ; if ( false === strpos ( $ version , '*' ) && Validator :: validateTag ( $ searchVerion , $ assetType ) ) { $ dependency .= '-' . str_replace ( '#' , '' , $ version ) ; } } return array ( $ dependency , $ version ) ; }
Checks if the version is a alias version.

@param AssetTypeInterface $assetType  The asset type
@param string             $dependency The dependency
@param string             $version    The version

@return string[] The new dependency and the new version
Checks if the version is a alias version .