| | |
| | | Map attributes = exchange.getHttpContext().getAttributes(); |
| | | String fileBase = helper.getAttrStr(attributes, FileHandler.ATTR_FILE_BASE, STR_EMPTY); |
| | | File fileRoot = new File(fileBase); |
| | | logger.fine("fileRoot: " + fileRoot.getAbsolutePath()); |
| | | String template = helper.getAttrStr(attributes, ATTR_TEMPLATE, STR_EMPTY); |
| | | File templateFile = new File(fileRoot, template); |
| | | if(templateFile.exists()) { |
| | | logger.fine("using template " + templateFile.getAbsolutePath()); |
| | | mf = new NeonMustacheFactory(fileRoot); |
| | | m = mf.compile(template); |
| | | } else { |
| | | logger.fine("template " + templateFile.getAbsolutePath() + " not found"); |
| | | mf = new NeonMustacheFactory(); |
| | | m = mf.compile(template); |
| | | } |