list.jsp revision 1390
0N/ASee LICENSE.txt included in this distribution for the specific
0N/Afile and include the License file at LICENSE.txt.
1281N/A if (request.getCharacterEncoding() == null) {
1281N/A request.setCharacterEncoding("UTF-8");
1281N/A cfg = PageConfig.get(request);
1281N/A Annotation annotation = cfg.getAnnotation();
1354N/A float r = annotation.getWidestRevision() * 1.15f;
1354N/A float a = annotation.getWidestAuthor() * 1.15f;
1281N/A cfg = PageConfig.get(request);
1281N/A String rev = cfg.getRequestedRevision();
1281N/A File resourceFile = cfg.getResourceFile();
1281N/A String path = cfg.getPath();
1281N/A String basename = resourceFile.getName();
1281N/A // see cfg.resourceNotAvailable()
1281N/A Project activeProject = Project.getProject(resourceFile);
1281N/A String cookieValue = cfg.getRequestedProjectsAsString();
1281N/A Set<String> projects = cfg.getRequestedProjects();
1281N/A cookieValue = cookieValue.length() == 0
1281N/A : activeProject.getDescription() + '/' + cookieValue;
1281N/A // TODO hmmm, projects.jspf doesn't set a path
1281N/A response.addCookie(cookie);
1281N/A List<String> files = cfg.getResourceFileList();
1281N/A if (!files.isEmpty()) {
1325N/A long now = System.currentTimeMillis();
1325N/A EftarFileReader.FNode parentFNode = null;
1325N/A EftarFileReader desc = cfg.getEftarReader();
1325N/A parentFNode = desc.getNode(path);
1325N/A offset = parentFNode.childOffset;
1325N/A IgnoredNames ignoredNames = cfg.getIgnoredNames();
1325N/A if (path.length() != 0) {
1325N/A long lastm = resourceFile.getParentFile().lastModified();
1325N/A <td><%= now-lastm < 86400000 ? "Today" : dateFormatter.format(lastm) %></td>
1368N/A if (ignoredNames.ignore(file)) {
1368N/A readMes.add(file);
1368N/A boolean isDir = child.isDirectory();
1325N/A long lastm = child.lastModified();
1325N/A <td><a href="<%= Util.URIEncodePath(file) %>"><%= isDir ? "<b>" + file + "</b>" : file %></a></td>
1325N/A <td><%= now-lastm < 86400000 ? "Today" : dateFormatter.format(lastm) %></td>
1325N/A String briefDesc = desc.getChildTag(parentFNode, file); %>
1368N/A if (readMes.size() != 0) {
1368N/A File[] xrefs = cfg.findDataFiles(readMes);
1368N/A for (int i=0; i < xrefs.length; i++) {
1368N/A readme = new File(resourceFile, readMes.get(i));
1368N/A g = AnalyzerGuru.getGenre(in);
1368N/A IOUtils.close(in);
1368N/A if (g == Genre.IMAGE) {
1370N/A<h3><%= readMes.get(i) %></h3><%
1384N/A XrefInputStream.dump(xrefs[i], out, false);
1368N/A<img src="<%= Util.URIEncodePath(rawPath + '/' + image) %>"/><%
1281N/A } else if (rev.length() != 0) {
1281N/A FileAnalyzerFactory a = AnalyzerGuru.find(basename);
1281N/A Genre g = AnalyzerGuru.getGenre(a);
1281N/A in = HistoryGuru.getInstance()
1281N/A error = e.getMessage();
1281N/A a = AnalyzerGuru.find(in);
1281N/A g = AnalyzerGuru.getGenre(a);
1368N/A Binary file [Click <a href="<%= Util.URIEncodePath(rawPath) %>?<%= rev
1370N/A rev.substring(2) %></span><%
1281N/A if (g == Genre.PLAIN) {
1281N/A Annotation annotation = cfg.getAnnotation();
1384N/A AnalyzerGuru.writeXref(a, r, xout , defs,
1281N/A annotation, Project.getProject(resourceFile));
1281N/A } else if (g == Genre.IMAGE) {
1370N/A <img src="<%= Util.URIEncodePath(rawPath) %>?<%= rev %>"/><%
1281N/A } else if (g == Genre.HTML) {
1368N/A %> Click <a href="<%= Util.URIEncodePath(rawPath) %>?<%=
1281N/A error = e.getMessage();
1384N/A IOUtils.close(in);
1384N/A IOUtils.close(xout);
1281N/A } else if (g == Genre.IMAGE) {
1368N/A <img src="<%= Util.URIEncodePath(rawPath) %>?<%= rev %>"/>
1368N/A Binary file [Click <a href="<%= Util.URIEncodePath(rawPath) %>?<%= rev
1281N/A if (!cfg.annotate()) {
1281N/A xrefFile = cfg.findDataFile();
1384N/A XrefInputStream.dump(xrefFile, out, true);
1281N/A FileAnalyzerFactory a = AnalyzerGuru.find(basename);
1281N/A Genre g = AnalyzerGuru.getGenre(a);
1281N/A a = AnalyzerGuru.find(bin);
1281N/A g = AnalyzerGuru.getGenre(a);
1281N/A if (g == Genre.IMAGE) {
1368N/A <img src="<%= Util.URIEncodePath(rawPath) %>"/>
1384N/A } else if (g == Genre.HTML) {
1281N/A } else if (g == Genre.PLAIN) {
1281N/A Definitions defs = IndexDatabase.getDefinitions(resourceFile);
1281N/A Annotation annotation = cfg.getAnnotation();
1384N/A AnalyzerGuru.writeXref(a, r, xout, defs, annotation,
1281N/A Project.getProject(resourceFile));
1368N/AClick <a href="<%= Util.URIEncodePath(rawPath) %>">download <%= basename %></a><%
1384N/A IOUtils.close(bin);
1384N/A IOUtils.close(xout);