rss.jsp revision 17b343cecb69da82215b124f39fed80167a6f2bd
b4851fc75ef4634840dcbadec085d586d36b434dneil_a_wilsonCDDL HEADER START
b4851fc75ef4634840dcbadec085d586d36b434dneil_a_wilsonThe contents of this file are subject to the terms of the
b4851fc75ef4634840dcbadec085d586d36b434dneil_a_wilsonCommon Development and Distribution License (the "License").
b4851fc75ef4634840dcbadec085d586d36b434dneil_a_wilsonYou may not use this file except in compliance with the License.
b4851fc75ef4634840dcbadec085d586d36b434dneil_a_wilsonSee LICENSE.txt included in this distribution for the specific
8cf870d281dc8c242f083d14dfef05f24aa5fceeJnRouvignaclanguage governing permissions and limitations under the License.
b4851fc75ef4634840dcbadec085d586d36b434dneil_a_wilsonWhen distributing Covered Code, include this CDDL HEADER in each
b4851fc75ef4634840dcbadec085d586d36b434dneil_a_wilsonfile and include the License file at LICENSE.txt.
b4851fc75ef4634840dcbadec085d586d36b434dneil_a_wilsonIf applicable, add the following below this CDDL HEADER, with the
b4851fc75ef4634840dcbadec085d586d36b434dneil_a_wilsonfields enclosed by brackets "[]" replaced with your own identifying
8cf870d281dc8c242f083d14dfef05f24aa5fceeJnRouvignacinformation: Portions Copyright [yyyy] [name of copyright owner]
8cf870d281dc8c242f083d14dfef05f24aa5fceeJnRouvignacCDDL HEADER END
b4851fc75ef4634840dcbadec085d586d36b434dneil_a_wilsonCopyright 2005 Sun Microsystems, Inc. All rights reserved.
b4851fc75ef4634840dcbadec085d586d36b434dneil_a_wilsonUse is subject to license terms.
b4851fc75ef4634840dcbadec085d586d36b434dneil_a_wilsonident "@(#)rss.jsp 1.2 05/12/02 SMI"
a395dd575518d9e5280fc5d5d5ef47c61b174647ludovicp--%><%@ page import = "javax.servlet.*,
8d7126a8f999e88851c7dd851a17c27cb6d2ec3fneil_a_wilson%><%@ page session="false" %><%@ page errorPage="error.jsp"%><%
8d7126a8f999e88851c7dd851a17c27cb6d2ec3fneil_a_wilsonString context = request.getContextPath();
8d7126a8f999e88851c7dd851a17c27cb6d2ec3fneil_a_wilsonString servlet = request.getServletPath();
8d7126a8f999e88851c7dd851a17c27cb6d2ec3fneil_a_wilsonString reqURI = request.getRequestURI();
b4851fc75ef4634840dcbadec085d586d36b434dneil_a_wilsonif(path == null) path = "";
b4851fc75ef4634840dcbadec085d586d36b434dneil_a_wilsonRuntimeEnvironment env = RuntimeEnvironment.getInstance();
b4851fc75ef4634840dcbadec085d586d36b434dneil_a_wilsonenv.setUrlPrefix(context + Constants.searchR+"?");
b4851fc75ef4634840dcbadec085d586d36b434dneil_a_wilsonString rawSource = env.getSourceRootPath();
b4851fc75ef4634840dcbadec085d586d36b434dneil_a_wilsonString resourcePath = rawSource + path;
b4851fc75ef4634840dcbadec085d586d36b434dneil_a_wilsonFile resourceFile = new File(resourcePath);
b4851fc75ef4634840dcbadec085d586d36b434dneil_a_wilsonboolean valid;
b4851fc75ef4634840dcbadec085d586d36b434dneil_a_wilsonString basename = resourceFile.getName();
b4851fc75ef4634840dcbadec085d586d36b434dneil_a_wilsonif("/".equals(path)) {
b4851fc75ef4634840dcbadec085d586d36b434dneil_a_wilson basename = "Cross Reference";
b4851fc75ef4634840dcbadec085d586d36b434dneil_a_wilsonboolean isDir = false;
b4851fc75ef4634840dcbadec085d586d36b434dneil_a_wilsonString parent = null;
b4851fc75ef4634840dcbadec085d586d36b434dneil_a_wilsonString parentBasename = resourceFile.getParentFile().getName();
b4851fc75ef4634840dcbadec085d586d36b434dneil_a_wilsonIgnoredNames ignoredNames = env.getIgnoredNames();
7185b49f58c4cdb16d035ecc45e38ec9b1cd9bd0matthew_swift|| ignoredNames.ignore(basename) || ignoredNames.ignore(parentBasename)) {
b4851fc75ef4634840dcbadec085d586d36b434dneil_a_wilson valid = false;
b4851fc75ef4634840dcbadec085d586d36b434dneil_a_wilson valid = true;
b4851fc75ef4634840dcbadec085d586d36b434dneil_a_wilson path = resourcePath.substring(rawSource.length());
b4851fc75ef4634840dcbadec085d586d36b434dneil_a_wilson path = path.replace('\\','/');
b4851fc75ef4634840dcbadec085d586d36b434dneil_a_wilson if (isDir && !reqURI.endsWith("/")) {
b4851fc75ef4634840dcbadec085d586d36b434dneil_a_wilson response.sendRedirect(context + servlet + path +"/");
b4851fc75ef4634840dcbadec085d586d36b434dneil_a_wilson String dtag = "";
b4851fc75ef4634840dcbadec085d586d36b434dneil_a_wilson EftarFileReader ef = new EftarFileReader(env.getDataRootPath() + "/index/dtags.eftar");
7185b49f58c4cdb16d035ecc45e38ec9b1cd9bd0matthew_swift dtag = ef.get(path);
b4851fc75ef4634840dcbadec085d586d36b434dneil_a_wilson } catch (Exception e) {
int lastSlash = path.lastIndexOf('/');
parent = (lastSlash != -1) ? path.substring(0, lastSlash) : "";
int pLastSlash = parent.lastIndexOf('/');
parentBasename = pLastSlash != -1 ? parent.substring(pLastSlash+1) : parent;
<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/">
<title>Changes in <%=Util.htmlize(basename)%></title>
<description><%=Util.htmlize(dtag)%></description>
String[] apaths = request.getParameterValues("also");
if (apaths!= null && apaths.length>0) {
for(int i=0; i< apaths.length; i++) {
paths.append(' ');
paths.append(apaths[i]);
apath = paths.toString();
hist = HistoryGuru.getInstance().getHistory(f);
for (HistoryEntry entry : hist.getHistoryEntries()) {
String rev = entry.getRevision();
if (entry.isActive()) {
Set<String> files = entry.getFiles();
%><%=Util.htmlize(ifile)%>