private String artifactPath;
+ private List mailingLists;
+
public String artifact()
throws ConfigurationStoreException, IOException, XmlPullParserException, ProjectBuildingException,
ResourceDoesNotExistException, ProxyException, ArtifactResolutionException
return SUCCESS;
}
+ public String mailingLists()
+ throws ConfigurationStoreException, IOException, XmlPullParserException, ProjectBuildingException
+ {
+ if ( !checkParameters() )
+ {
+ return ERROR;
+ }
+
+ MavenProject project = readProject();
+
+ model = project.getModel();
+
+ this.mailingLists = project.getMailingLists();
+
+ return SUCCESS;
+ }
+
public String dependees()
throws ConfigurationStoreException, IOException, XmlPullParserException, ProjectBuildingException,
RepositoryIndexException, RepositoryIndexSearchException
{
return repositoryId;
}
+
+ public List getMailingLists()
+ {
+ return mailingLists;
+ }
}
return BROWSE_PREFIX + params.remove( "groupId" ) + "/" + params.remove( "artifactId" ) + "/" +
params.remove( "version" ) + "/dependencies";
}
+ else if ( "showArtifactMailingLists".equals( actionMapping.getName() ) )
+ {
+ return BROWSE_PREFIX + params.remove( "groupId" ) + "/" + params.remove( "artifactId" ) + "/" +
+ params.remove( "version" ) + "/mailingLists";
+ }
else if ( "showArtifactDependees".equals( actionMapping.getName() ) )
{
return BROWSE_PREFIX + params.remove( "groupId" ) + "/" + params.remove( "artifactId" ) + "/" +
{
return new ActionMapping( "showArtifactDependencies", "/", "", params );
}
+ else if ( "mailingLists".equals( parts[3] ) )
+ {
+ return new ActionMapping( "showArtifactMailingLists", "/", "", params );
+ }
else if ( "usedby".equals( parts[3] ) )
{
return new ActionMapping( "showArtifactDependees", "/", "", params );
<result>/WEB-INF/jsp/showArtifact.jsp</result>
</action>
+ <action name="showArtifactMailingLists" class="showArtifactAction" method="mailingLists">
+ <result>/WEB-INF/jsp/showArtifact.jsp</result>
+ </action>
+
<action name="showArtifactDependencies" class="showArtifactAction" method="dependencies">
<result>/WEB-INF/jsp/showArtifact.jsp</result>
</action>
--- /dev/null
+<%--
+ ~ Licensed to the Apache Software Foundation (ASF) under one
+ ~ or more contributor license agreements. See the NOTICE file
+ ~ distributed with this work for additional information
+ ~ regarding copyright ownership. The ASF licenses this file
+ ~ to you under the Apache License, Version 2.0 (the
+ ~ "License"); you may not use this file except in compliance
+ ~ with the License. You may obtain a copy of the License at
+ ~
+ ~ http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing,
+ ~ software distributed under the License is distributed on an
+ ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ ~ KIND, either express or implied. See the License for the
+ ~ specific language governing permissions and limitations
+ ~ under the License.
+ --%>
+
+<%@ taglib prefix="ww" uri="/webwork" %>
+<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
+<%@ taglib prefix="my" tagdir="/WEB-INF/tags" %>
+
+<c:forEach items="${mailingLists}" var="mailingList">
+ <h3>
+ ${mailingList.name}
+ </h3>
+ <%-- TODO: description
+ <p>
+ Description blah blah blah
+ </p>
+ --%>
+ <ul>
+ <c:if test="${!empty(mailingList.subscribe)}">
+ <li>
+ <b>Subscribe:</b>
+ <a href="mailto:${mailingList.subscribe}">${mailingList.subscribe}</a>
+ </li>
+ </c:if>
+ <c:if test="${!empty(mailingList.post)}">
+ <li>
+ <b>Post:</b>
+ <a href="mailto:${mailingList.post}">${mailingList.post}</a>
+ </li>
+ </c:if>
+ <c:if test="${!empty(mailingList.unsubscribe)}">
+ <li>
+ <b>Unsubscribe:</b>
+ <a href="mailto:${mailingList.unsubscribe}">${mailingList.unsubscribe}</a>
+ </li>
+ </c:if>
+ <%-- TODO: not in the POM yet
+ <li>
+ <b>List owner:</b>
+ <a href="mailto:${mailingList.owner}">${mailingList.owner}</a>
+ </li>
+ --%>
+ <c:if test="${!empty(mailingList.archive)}">
+ <li>
+ <b>Archive:</b>
+ <ul>
+ <li>
+ <a href="${mailingList.archive}">${mailingList.archive}</a>
+ </li>
+ </ul>
+ </li>
+ </c:if>
+ <c:if test="${!empty(mailingList.otherArchives)}">
+ <li>
+ <b>Other Archives:</b>
+ <ul>
+ <c:forEach items="${mailingList.otherArchives}" var="archive">
+ <li>
+ <a href="${archive}">${archive}</a>
+ </li>
+ </c:forEach>
+ </ul>
+ </li>
+ </c:if>
+ </ul>
+</c:forEach>
+<c:if test="${empty(mailingLists)}">
+ <strong>No mailing lists</strong>
+</c:if>
</ww:url>
</c:set>
<my:currentWWUrl url="${url}">Used By</my:currentWWUrl>
- <%-- TODO:
- <a href="TODO">Mailing Lists</a>
- --%>
+ <c:set var="url">
+ <ww:url action="showArtifactMailingLists">
+ <ww:param name="groupId" value="%{groupId}"/>
+ <ww:param name="artifactId" value="%{artifactId}"/>
+ <ww:param name="version" value="%{version}"/>
+ </ww:url>
+ </c:set>
+ <my:currentWWUrl url="${url}">Mailing Lists</my:currentWWUrl>
</span>
</div>
<c:when test="${dependencyTree != null}">
<%@ include file="/WEB-INF/jsp/include/dependencyTree.jspf" %>
</c:when>
+ <c:when test="${mailingLists != null}">
+ <%@ include file="/WEB-INF/jsp/include/mailingLists.jspf" %>
+ </c:when>
<c:otherwise>
<%@ include file="/WEB-INF/jsp/include/artifactInfo.jspf" %>
</c:otherwise>