Map<String, Object> mapValues = (Map<String, Object>) _mapValues;
StringBuilder sb = new StringBuilder();
// Find all template variables
template = new UriTemplateParser(template).getNormalizedTemplate();
final Matcher m = TEMPLATE_NAMES_PATTERN.matcher(template);
int i = 0;
while (m.find()) {
sb.append(template, i, m.start());