/** * This is like {@link #parseCommaSeparatedList(String)}, but is not confused by commas inside * {@code ?settings(...)} parts at the end of the items. */ static List parseCommaSeparatedTemplatePaths(String commaSepItems) { List listItems; listItems = new ArrayList(); while (commaSepItems.length() != 0) { int itemSettingAssignmentsStart = findTemplatePathSettingAssignmentsStart(commaSepItems); int pureItemEnd = itemSettingAssignmentsStart != -1 ? itemSettingAssignmentsStart : commaSepItems.length(); int prevComaIdx = commaSepItems.lastIndexOf(',', pureItemEnd - 1); int itemStart = prevComaIdx != -1 ? prevComaIdx + 1 : 0; final String item = commaSepItems.substring(itemStart).trim(); if (item.length() != 0) { listItems.add(0, item); } else if (listItems.size() > 0) { throw new TemplatePathParsingException("Missing list item before a comma"); } commaSepItems = prevComaIdx != -1 ? commaSepItems.substring(0, prevComaIdx).trim() : ""; } return listItems; }
throw new TemplatePathParsingException( StringUtil.jQuote(biName) + " is unexpected after the \"?\". " + "Expected \"" + TEMPLATE_PATH_SETTINGS_BI_NAME + "\".");
if (!pureTemplatePath.endsWith("]")) { throw new TemplatePathParsingException("Failed to parse template path; closing \"]\" is missing."); } else if (pureTemplatePath.startsWith("{") && cfg.getIncompatibleImprovements().intValue() >= _TemplateAPI.VERSION_INT_2_3_22) { throw new TemplatePathParsingException("Template paths starting with \"{\" are reseved for future purposes"); } else { templateLoader = new WebappTemplateLoader(srvCtx, pureTemplatePath); _SettingEvaluationEnvironment.getCurrent()); if (nextPos != templatePath.length()) { throw new TemplatePathParsingException("Template path should end after the setting list in: " + templatePath); throw new TemplatePathParsingException("Failed to set properties in: " + templatePath, e);
throw new TemplatePathParsingException( StringUtil.jQuote(biName) + " is unexpected after the \"?\". " + "Expected \"" + TEMPLATE_PATH_SETTINGS_BI_NAME + "\".");
if (!pureTemplatePath.endsWith("]")) { throw new TemplatePathParsingException("Failed to parse template path; closing \"]\" is missing."); } else if (pureTemplatePath.startsWith("{") && cfg.getIncompatibleImprovements().intValue() >= _TemplateAPI.VERSION_INT_2_3_22) { throw new TemplatePathParsingException("Template paths starting with \"{\" are reseved for future purposes"); } else { templateLoader = new WebappTemplateLoader(srvCtx, pureTemplatePath); _SettingEvaluationEnvironment.getCurrent()); if (nextPos != templatePath.length()) { throw new TemplatePathParsingException("Template path should end after the setting list in: " + templatePath); throw new TemplatePathParsingException("Failed to set properties in: " + templatePath, e);
throw new TemplatePathParsingException( StringUtil.jQuote(biName) + " is unexpected after the \"?\". " + "Expected \"" + TEMPLATE_PATH_SETTINGS_BI_NAME + "\".");
if (!pureTemplatePath.endsWith("]")) { throw new TemplatePathParsingException("Failed to parse template path; closing \"]\" is missing."); } else if (pureTemplatePath.startsWith("{") && cfg.getIncompatibleImprovements().intValue() >= _TemplateAPI.VERSION_INT_2_3_22) { throw new TemplatePathParsingException("Template paths starting with \"{\" are reseved for future purposes"); } else { templateLoader = new WebappTemplateLoader(srvCtx, pureTemplatePath); _SettingEvaluationEnvironment.getCurrent()); if (nextPos != templatePath.length()) { throw new TemplatePathParsingException("Template path should end after the setting list in: " + templatePath); throw new TemplatePathParsingException("Failed to set properties in: " + templatePath, e);
/** * This is like {@link #parseCommaSeparatedList(String)}, but is not confused by commas inside * {@code ?settings(...)} parts at the end of the items. */ static List parseCommaSeparatedTemplatePaths(String commaSepItems) { List listItems; listItems = new ArrayList(); while (commaSepItems.length() != 0) { int itemSettingAssignmentsStart = findTemplatePathSettingAssignmentsStart(commaSepItems); int pureItemEnd = itemSettingAssignmentsStart != -1 ? itemSettingAssignmentsStart : commaSepItems.length(); int prevComaIdx = commaSepItems.lastIndexOf(',', pureItemEnd - 1); int itemStart = prevComaIdx != -1 ? prevComaIdx + 1 : 0; final String item = commaSepItems.substring(itemStart).trim(); if (item.length() != 0) { listItems.add(0, item); } else if (listItems.size() > 0) { throw new TemplatePathParsingException("Missing list item before a comma"); } commaSepItems = prevComaIdx != -1 ? commaSepItems.substring(0, prevComaIdx).trim() : ""; } return listItems; }
/** * This is like {@link #parseCommaSeparatedList(String)}, but is not confused by commas inside * {@code ?settings(...)} parts at the end of the items. */ static List parseCommaSeparatedTemplatePaths(String commaSepItems) { List listItems; listItems = new ArrayList(); while (commaSepItems.length() != 0) { int itemSettingAssignmentsStart = findTemplatePathSettingAssignmentsStart(commaSepItems); int pureItemEnd = itemSettingAssignmentsStart != -1 ? itemSettingAssignmentsStart : commaSepItems.length(); int prevComaIdx = commaSepItems.lastIndexOf(',', pureItemEnd - 1); int itemStart = prevComaIdx != -1 ? prevComaIdx + 1 : 0; final String item = commaSepItems.substring(itemStart).trim(); if (item.length() != 0) { listItems.add(0, item); } else if (listItems.size() > 0) { throw new TemplatePathParsingException("Missing list item before a comma"); } commaSepItems = prevComaIdx != -1 ? commaSepItems.substring(0, prevComaIdx).trim() : ""; } return listItems; }