I am trying to get the values that are in braces as below:
{{{{{{{{{{{{{{{{{{value1 here!}}}}}}}}}}}{value2 here!}}}}}}}}}{value3 here!}}}}}}
I would like you to be selected as a group:
{value1 here!} {value2 here!} {value3 here!}
I'm doing the expression on the site Regex101 and applying it to my Java project.
Pattern p = Pattern.compile("\\\\{.*\\\\}");
Matcher m = p.matcher("{{{{{{{{{{{{{{{{{{value1 here!}}}}}}}}}}}{value2 here!}}}}}}}}}{value3 here!}}}}}}");
if (m.find()){
String value1 = m.group(1);
String value2 = m.group(2);
String value3 = m.group(3);
}
How can I solve this problem?