List<Integer> (String s) { List<Integer> singleBraces = null; int i = -1; while ((i = getAVTEndOffset(s, i)) != -1) { if (singleBraces == null) { singleBraces = new SmartList<>(); } if (i == 0 || s.charAt(i - 1) != '{') { singleBraces.add(i); } } return singleBraces; } private static int getAVTEndOffset(String value, int i) { while (true) { i = value.indexOf('}', i + 1); if (i != -1 && i == value.indexOf("}}