@Override protected boolean finishConfigure(List<Object> args) { log(Level.TRACE, "Configuring collect xpath with %s", args); CollectResolver<XPathExpression> cr = new XmlProvider.XmlResolver(); collectKeys = new HashMap<>(getPd().getCollectMapping().size()); for(Map.Entry<String, String> e: getPd().getCollectMapping().entrySet()) { String solved = Util.parseTemplate(String.format(e.getKey(), args != null ? args.toArray() : null), this, args); XPathExpression xpath = cr.resolve(solved); if (xpath == null) { log(Level.DEBUG, "unparsed xpath: %s", e.getKey()); continue; } else { collectKeys.put(xpath, solved); } } collectKeys = Collections.unmodifiableMap(collectKeys); log(Level.TRACE, "collect xpath mapping %s", collectKeys); return super.finishConfigure(args); }