class UriTemplateUtil {

    public static String retainVariablesValue(String requestPath,String matchingPatternPath,String[] variableNames){
        if (isNotNullOrEmpty(variableNames)){
            Map<String, String> opMap = extractUriTemplateVariables(requestPath, matchingPatternPath);
            return expand(matchingPatternPath, MapUtil.getSubMap(opMap, variableNames));
        }
        return expand(matchingPatternPath, Collections.<String, String> emptyMap());
    }

    private  UriTemplateUtil();

}