Exemple #1
0
  public PageSpec read(
      String path,
      Page page,
      SectionFilter sectionFilter,
      Properties properties,
      Map<String, Object> jsVariables,
      Map<String, Locator> objects)
      throws IOException {

    String contextPath = GalenUtils.getParentForFile(path);
    if (contextPath == null) {
      contextPath = "./";
    }

    InputStream stream = GalenUtils.findFileOrResourceAsStream(path);
    if (stream == null) {
      throw new FileNotFoundException(path);
    }
    return read(stream, path, contextPath, page, sectionFilter, properties, jsVariables, objects);
  }