Author: wrzep Date: 2005-11-09 20:17:01 -0500 (Wed, 09 Nov 2005) New Revision: 1549 Added: trunk/forge/portal-extensions/forge-status/ trunk/forge/portal-extensions/forge-status/maven.xml trunk/forge/portal-extensions/forge-status/project.properties trunk/forge/portal-extensions/forge-status/project.xml trunk/forge/portal-extensions/forge-status/src/ trunk/forge/portal-extensions/forge-status/src/java/ trunk/forge/portal-extensions/forge-status/src/java/org/ trunk/forge/portal-extensions/forge-status/src/java/org/jboss/ trunk/forge/portal-extensions/forge-status/src/java/org/jboss/forge/ trunk/forge/portal-extensions/forge-status/src/java/org/jboss/forge/status/ trunk/forge/portal-extensions/forge-status/src/java/org/jboss/forge/status/Status.java trunk/forge/portal-extensions/forge-status/src/java/org/jboss/forge/status/StatusDescriptor.java trunk/forge/portal-extensions/forge-status/src/java/org/jboss/forge/status/StatusNodeWatcher.java trunk/forge/portal-extensions/forge-status/src/java/org/jboss/forge/status/StatusPortlet.java trunk/forge/portal-extensions/forge-status/src/java/org/jboss/forge/status/StatusTools.java trunk/forge/portal-extensions/forge-status/src/web/ trunk/forge/portal-extensions/forge-status/src/web/WEB-INF/ trunk/forge/portal-extensions/forge-status/src/web/WEB-INF/jboss-app.xml trunk/forge/portal-extensions/forge-status/src/web/WEB-INF/jboss-portlet.xml trunk/forge/portal-extensions/forge-status/src/web/WEB-INF/jboss-service.xml trunk/forge/portal-extensions/forge-status/src/web/WEB-INF/portlet-instances.xml trunk/forge/portal-extensions/forge-status/src/web/WEB-INF/portlet.xml trunk/forge/portal-extensions/forge-status/src/web/WEB-INF/tld/ trunk/forge/portal-extensions/forge-status/src/web/WEB-INF/tld/forge.tld trunk/forge/portal-extensions/forge-status/src/web/WEB-INF/tld/portlet.tld trunk/forge/portal-extensions/forge-status/src/web/WEB-INF/web.xml Modified: trunk/forge/portal-extensions/forge-ear/src/META-INF/application.xml trunk/forge/portal-extensions/portal-default/src/web/WEB-INF/default-portal.xml Log: project status portlet basic clasess Pawel Modified: trunk/forge/portal-extensions/forge-ear/src/META-INF/application.xml =================================================================== --- trunk/forge/portal-extensions/forge-ear/src/META-INF/application.xml 2005-11-09 22:23:15 UTC (rev 1548) +++ trunk/forge/portal-extensions/forge-ear/src/META-INF/application.xml 2005-11-10 01:17:01 UTC (rev 1549) @@ -82,5 +82,10 @@ <web> <web-uri>forgeLogin.war</web-uri> </web> - </module> + </module> + <module> + <web> + <web-uri>forge-status.war</web-uri> + </web> + </module> </application> Added: trunk/forge/portal-extensions/forge-status/maven.xml =================================================================== --- trunk/forge/portal-extensions/forge-status/maven.xml 2005-11-09 22:23:15 UTC (rev 1548) +++ trunk/forge/portal-extensions/forge-status/maven.xml 2005-11-10 01:17:01 UTC (rev 1549) @@ -0,0 +1,24 @@ +<!-- + JBoss, the OpenSource J2EE webOS + Distributable under LGPL license. + See terms of license at gnu.org. + --> +<project xmlns:j="jelly:core" xmlns:ant="jelly:ant" xmlns:u="jelly:util"> + <!-- Default war-project goals --> + + <goal name="all"> + <attainGoal name="prj-all" /> + </goal> + + <goal name="build"> + <attainGoal name="prj-war-build" /> + </goal> + + <goal name="deploy"> + <attainGoal name="prj-war-deploy" /> + </goal> + + <goal name="clean"> + <attainGoal name="prj-clean" /> + </goal> +</project> Added: trunk/forge/portal-extensions/forge-status/project.properties =================================================================== --- trunk/forge/portal-extensions/forge-status/project.properties 2005-11-09 22:23:15 UTC (rev 1548) +++ trunk/forge/portal-extensions/forge-status/project.properties 2005-11-10 01:17:01 UTC (rev 1549) @@ -0,0 +1,3 @@ +maven.repo.remote=http://repository.atlassian.com,http://www.ibiblio.org/maven,http://dist.codehaus.org/ +maven.junit.fork=yes +maven.war.src=${basedir}/src/web Added: trunk/forge/portal-extensions/forge-status/project.xml =================================================================== --- trunk/forge/portal-extensions/forge-status/project.xml 2005-11-09 22:23:15 UTC (rev 1548) +++ trunk/forge/portal-extensions/forge-status/project.xml 2005-11-10 01:17:01 UTC (rev 1549) @@ -0,0 +1,55 @@ +<?xml version='1.0' encoding='ISO-8859-1'?> +<!-- + JBoss, the OpenSource J2EE webOS + Distributable under LGPL license. + See terms of license at gnu.org. + --> +<project> + <pomVersion>3</pomVersion> + <extend>../common.xml</extend> + <id>forge-status</id> + <name>Dashboard status portlet</name> + <currentVersion>1.0</currentVersion> + <organization> + <name>Pawel Wrzeszcz</name> + <url></url> + </organization> + <description></description> + + <dependencies> + <dependency> + <groupId>tmate</groupId> + <artifactId>javasvn</artifactId> + <version>1.0</version> + <jar>javasvn.jar</jar> + </dependency> + + <dependency> + <groupId>tmate</groupId> + <artifactId>jsch</artifactId> + <version>1.0</version> + <jar>jsch.jar</jar> + </dependency> + + <dependency> + <groupId>jboss-forge</groupId> + <artifactId>forge-common</artifactId> + <version>1.0</version> + </dependency> + + <dependency> + <groupId>aslibs</groupId> + <artifactId>javax.servlet</artifactId> + <version>1.0</version> + <jar>javax.servlet.jar</jar> + </dependency> + + <dependency> + <id>jdom</id> + <version>1.0</version> + <properties> + <war.bundle>true</war.bundle> + </properties> + </dependency> + </dependencies> +</project> Added: trunk/forge/portal-extensions/forge-status/src/java/org/jboss/forge/status/Status.java =================================================================== --- trunk/forge/portal-extensions/forge-status/src/java/org/jboss/forge/status/Status.java 2005-11-09 22:23:15 UTC (rev 1548) +++ trunk/forge/portal-extensions/forge-status/src/java/org/jboss/forge/status/Status.java 2005-11-10 01:17:01 UTC (rev 1549) @@ -0,0 +1,143 @@ +/* + * JBoss, Home of Professional Open Source + * Copyright 2005, JBoss Inc., and individual contributors as indicated + * by the @authors tag. See the copyright.txt in the distribution for a + * full listing of individual contributors. + * + * This is free software; you can redistribute it and/or modify it + * under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation; either version 2.1 of + * the License, or (at your option) any later version. + * + * This software is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this software; if not, write to the Free + * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA + * 02110-1301 USA, or see the FSF site: http://www.fsf.org. + */ + +package org.jboss.forge.status; + +import java.util.Iterator; +import java.util.Map; +import java.util.HashMap; +import java.util.Set; +import java.util.HashSet; + +import org.jboss.forge.common.XmlTools; +import org.jboss.forge.common.projects.AbstractDescriptor; +import org.jboss.forge.common.projects.permissions.PermissionsChecker; +import org.jboss.forge.common.projects.permissions.RenderRequestPermissionsChecker; +import org.jboss.forge.common.projects.DomToXmlTransformer; + +import org.jboss.portal.common.context.DelegateContext; +import org.jboss.shotoku.ContentManager; + +import org.apache.xerces.parsers.DOMParser; +import org.xml.sax.InputSource; + +import org.w3c.dom.Document; +import org.w3c.dom.Node; +import org.w3c.dom.NodeList; +import org.w3c.dom.NamedNodeMap; + +/** +* @author Pawel Wrzeszcz +*/ +public class Status extends AbstractDescriptor { + + private final static String PROJECT_ELEMENT = "project"; + + private String portalName; + + /** + * <code>allItemsArr</code> - Array if ItemIF objects, containing items from all feeds. + */ + private HashSet<String> projects; + + Status(String portalName, Node root) { + this.portalName = portalName; + + // Get the projects nodes + projects = new HashSet<String>(); + + HashSet<String> projectNodes = new HashSet(); + projectNodes.add(PROJECT_ELEMENT); + + Set<Node> prjNodes; + prjNodes = getChildNodesSet(root, projectNodes); + + for (Iterator iter = prjNodes.iterator(); iter.hasNext();) { + Node n = (Node) iter.next(); + projects.add(XmlTools.unmarshallText(n)); + } + } + + /** + * Fills the given context with podcast information. + * + * @param context Context to fill. + */ + public void fillContext(DelegateContext context) { + + int i = 1; + for (Iterator iter = projects.iterator(); iter.hasNext(); i++) { + String projectName = (String) iter.next(); + + DelegateContext projectContext = context.next("project"); + + projectContext.put("name", projectName); + projectContext.put("position", i); + } + } + + + /** + * For the given Node, computes Set of it's child Nodes. + * Only child Nodes with names included in <code>nodesNames</code> Set + * appear in computed Set. + * + * @param root + * @param nodesNames + * @return Set containing <code>root</code>'s child Nodes, + * but only those with names included in <code>nodeNames</code> Set + */ + private Set getChildNodesSet(Node root, Set<String> nodesNames) { + HashSet ret = new HashSet<Node>(); + NodeList list = root.getChildNodes(); + + for (int i = 0; i < list.getLength(); i++) { + Node n = list.item(i); + if ((n.getNodeType() == Node.ELEMENT_NODE) + && (nodesNames.contains(n.getNodeName()))) { + ret.add(n); + } + } + + return ret; + } + + /** + * Similar to <code>getChildNodesSet(Node,Set)</code>. + * Map binds child Nodes names with appropriate Nodes. + */ + private Map getChildNodesMap(Node root, Set<String> nodesNames) { + HashMap ret = new HashMap<String,Node>(); + NodeList list = root.getChildNodes(); + + for (int i = 0; i < list.getLength(); i++) { + Node n = list.item(i); + if ((n.getNodeType() == Node.ELEMENT_NODE) + && (nodesNames.contains(n.getNodeName()))) { + ret.put(n.getNodeName(),n); + } + } + + return ret; + } + +} Added: trunk/forge/portal-extensions/forge-status/src/java/org/jboss/forge/status/StatusDescriptor.java =================================================================== --- trunk/forge/portal-extensions/forge-status/src/java/org/jboss/forge/status/StatusDescriptor.java 2005-11-09 22:23:15 UTC (rev 1548) +++ trunk/forge/portal-extensions/forge-status/src/java/org/jboss/forge/status/StatusDescriptor.java 2005-11-10 01:17:01 UTC (rev 1549) @@ -0,0 +1,82 @@ +/* + * JBoss, Home of Professional Open Source + * Copyright 2005, JBoss Inc., and individual contributors as indicated + * by the @authors tag. See the copyright.txt in the distribution for a + * full listing of individual contributors. + * + * This is free software; you can redistribute it and/or modify it + * under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation; either version 2.1 of + * the License, or (at your option) any later version. + * + * This software is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this software; if not, write to the Free + * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA + * 02110-1301 USA, or see the FSF site: http://www.fsf.org. + */ + +package org.jboss.forge.status; + +import java.io.IOException; +import java.util.Set; +import java.util.HashSet; + +import org.apache.xerces.parsers.DOMParser; +import org.jboss.forge.common.ForgeHelper; +import org.jboss.forge.common.projects.ProjectsHelper; +import org.jboss.portal.common.context.DelegateContext; +import org.jboss.portlet.JBossRenderRequest; +import org.jboss.shotoku.ContentManager; +import org.w3c.dom.Document; +import org.w3c.dom.Node; +import org.w3c.dom.NodeList; +import org.xml.sax.InputSource; +import org.xml.sax.SAXException; +import org.jboss.logging.Logger; + +/** + * @author Pawel Wrzeszcz + * A class which handles xml parsing and accessing parsed feeds information. + */ +public class StatusDescriptor { + + private static final Logger log = Logger.getLogger(StatusDescriptor.class); + + private DelegateContext context; + private Status status; + + public StatusDescriptor(String portalName, ContentManager cm) { + try { + + DOMParser parser = new DOMParser(); + parser.parse(new InputSource(cm.getNode(StatusTools + .getPrjXmlCmPath(portalName)).getContentInputStream())); + + Node root = parser.getDocument().getDocumentElement(); + + if ((root.getNodeType() == Node.ELEMENT_NODE) + && (root.getNodeName().equals("projects"))) { + status = new Status(portalName, root); + } + + fillContext(); + + } catch (Exception e) { + e.printStackTrace(); + } + } + + private void fillContext() { + context = new DelegateContext(); + status.fillContext(context); + } + + public DelegateContext getContext(JBossRenderRequest request) { + return context; + } +} Added: trunk/forge/portal-extensions/forge-status/src/java/org/jboss/forge/status/StatusNodeWatcher.java =================================================================== --- trunk/forge/portal-extensions/forge-status/src/java/org/jboss/forge/status/StatusNodeWatcher.java 2005-11-09 22:23:15 UTC (rev 1548) +++ trunk/forge/portal-extensions/forge-status/src/java/org/jboss/forge/status/StatusNodeWatcher.java 2005-11-10 01:17:01 UTC (rev 1549) @@ -0,0 +1,55 @@ +/* + * JBoss, Home of Professional Open Source + * Copyright 2005, JBoss Inc., and individual contributors as indicated + * by the @authors tag. See the copyright.txt in the distribution for a + * full listing of individual contributors. + * + * This is free software; you can redistribute it and/or modify it + * under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation; either version 2.1 of + * the License, or (at your option) any later version. + * + * This software is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this software; if not, write to the Free + * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA + * 02110-1301 USA, or see the FSF site: http://www.fsf.org. + */ +package org.jboss.forge.status; + +import org.jboss.forge.common.service.NodeWatcher; +import org.jboss.forge.common.service.ResourceWatcher; +import org.jboss.shotoku.ContentManager; + +public class StatusNodeWatcher implements NodeWatcher { + private ResourceWatcher rw; + private ContentManager cm; + + public StatusNodeWatcher(ContentManager cm) { + this.cm = cm; + } + + private StatusDescriptor getDesc(String portalName) { + StatusDescriptor desc = new StatusDescriptor(portalName, cm); + + rw = new ResourceWatcher(cm); + rw.watchResource(StatusTools.getPrjXmlCmPath(portalName)); + + return desc; + } + + public Object init(String portalName) { + return getDesc(portalName); + } + + public Object nodeUpdate(String portalName, Object currentValue) { + if ((currentValue == null) || (rw.checkResources())) + return getDesc(portalName); + else + return null; + } +} Added: trunk/forge/portal-extensions/forge-status/src/java/org/jboss/forge/status/StatusPortlet.java =================================================================== --- trunk/forge/portal-extensions/forge-status/src/java/org/jboss/forge/status/StatusPortlet.java 2005-11-09 22:23:15 UTC (rev 1548) +++ trunk/forge/portal-extensions/forge-status/src/java/org/jboss/forge/status/StatusPortlet.java 2005-11-10 01:17:01 UTC (rev 1549) @@ -0,0 +1,67 @@ + /* + * JBoss, Home of Professional Open Source + * Copyright 2005, JBoss Inc., and individual contributors as indicated + * by the @authors tag. See the copyright.txt in the distribution for a + * full listing of individual contributors. + * + * This is free software; you can redistribute it and/or modify it + * under the terms of the GNU Lesser General Public License as + * published by the Free Software Foundation; either version 2.1 of + * the License, or (at your option) any later version. + * + * This software is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this software; if not, write to the Free + * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA + * 02110-1301 USA, or see the FSF site: http://www.fsf.org. + */ + +package org.jboss.forge.status; + +import java.io.IOException; + +import javax.portlet.PortletException; +import javax.portlet.PortletRequestDispatcher; + +import org.jboss.forge.common.ForgeHelper; +import org.jboss.forge.common.projects.Projects; +import org.jboss.forge.common.projects.ProjectsHelper; +import org.jboss.forge.common.projects.permissions.PermissionsChecker; +import org.jboss.forge.common.projects.permissions.RenderRequestPermissionsChecker; + +import org.jboss.portal.common.context.DelegateContext; +import org.jboss.portal.core.servlet.jsp.PortalJsp; + +import org.jboss.portlet.JBossPortlet; +import org.jboss.portlet.JBossRenderRequest; +import org.jboss.portlet.JBossRenderResponse; + +/** + * Podcast portlet. + * @author Pawel Wrzeszcz + */ +public class StatusPortlet extends JBossPortlet { + + public void doView(JBossRenderRequest request, JBossRenderResponse response) + throws IOException, PortletException { + response.setContentType("text/html"); + + String portalName = ForgeHelper.getPortalName(request); + + // Getting the podcast context + DelegateContext context = StatusTools.getDesc(portalName).getContext(request); + + // Displaying the JSP + request.setAttribute(PortalJsp.CTX_REQUEST, context); + + PortletRequestDispatcher rd = getPortletContext().getRequestDispatcher( + ForgeHelper.createRepoAccessPath(portalName, StatusTools + .getJspCmPath())); + rd.include(request, response); + + } +} Added: trunk/forge/portal-extensions/forge-status/src/java/org/jboss/forge/status/StatusTools.java =================================================================== --- trunk/forge/portal-extensions/forge-status/src/java/org/jboss/forge/status/StatusTools.java 2005-11-09 22:23:15 UTC (rev 1548) +++ trunk/forge/portal-extensions/forge-status/src/java/org/jboss/forge/status/StatusTools.java 2005-11-10 01:17:01 UTC (rev 1549) @@ -0,0 +1,61 @@ +package org.jboss.forge.status; + +import org.jboss.forge.common.ForgeHelper; + +import org.jboss.shotoku.ContentManager; +import org.jboss.shotoku.aop.Inject; + +/** + * Common constants and functions. + * @author Pawel Wrzeszcz + */ +public class StatusTools { + + /** + * <code>STATUS_XML<code> - file defining the list of watched feeds + */ + private final static String STATUS_XML = "status.xml"; + + /** + * <code>STATUS_DIR</code> - directory in which file <code>PODCAST_XML<code> is stored. + */ + private final static String STATUS_DIR = "status"; + + private final static String STATUS_JSP = "status.jsp"; + private final static String STATUS_JSP_DIR = "status"; + + private final static String MEMBERS_DIR = "members"; + private final static String PROJECTS_XML = "projects.xml"; + + @Inject + private static ContentManager cm; + + /** + * Path to the xml file defining list of watched feeds. + */ + public static String getPrjXmlCmPath(String portalName) { + return portalName + "/" + MEMBERS_DIR + "/" + PROJECTS_XML; + } + + /** + * Path to the file displaying the podcast feeds. + */ + public static String getJspCmPath() { + return STATUS_JSP_DIR + "/" + STATUS_JSP; + } + + public static synchronized StatusDescriptor getDesc(final String portalName) { + String cacheKey = StatusDescriptor.class.getName(); + + StatusDescriptor desc = (StatusDescriptor) ForgeHelper + .getForgeManagement().getFromCache(portalName, cacheKey); + + if (desc == null) + desc = (StatusDescriptor) ForgeHelper.getForgeManagement() + .addNodeWatcher(portalName, + cacheKey, + new StatusNodeWatcher(cm)); + + return desc; + } +} Added: trunk/forge/portal-extensions/forge-status/src/web/WEB-INF/jboss-app.xml =================================================================== --- trunk/forge/portal-extensions/forge-status/src/web/WEB-INF/jboss-app.xml 2005-11-09 22:23:15 UTC (rev 1548) +++ trunk/forge/portal-extensions/forge-status/src/web/WEB-INF/jboss-app.xml 2005-11-10 01:17:01 UTC (rev 1549) @@ -0,0 +1,3 @@ +<jboss-app> + <app-name>status</app-name> +</jboss-app> Added: trunk/forge/portal-extensions/forge-status/src/web/WEB-INF/jboss-portlet.xml =================================================================== --- trunk/forge/portal-extensions/forge-status/src/web/WEB-INF/jboss-portlet.xml 2005-11-09 22:23:15 UTC (rev 1548) +++ trunk/forge/portal-extensions/forge-status/src/web/WEB-INF/jboss-portlet.xml 2005-11-10 01:17:01 UTC (rev 1549) @@ -0,0 +1,6 @@ +<portlet-app> + <portlet> + <portlet-name>StatusPortlet</portlet-name> + <security></security> + </portlet> +</portlet-app> \ No newline at end of file Added: trunk/forge/portal-extensions/forge-status/src/web/WEB-INF/jboss-service.xml =================================================================== --- trunk/forge/portal-extensions/forge-status/src/web/WEB-INF/jboss-service.xml 2005-11-09 22:23:15 UTC (rev 1548) +++ trunk/forge/portal-extensions/forge-status/src/web/WEB-INF/jboss-service.xml 2005-11-10 01:17:01 UTC (rev 1549) @@ -0,0 +1 @@ +<server></server> \ No newline at end of file Added: trunk/forge/portal-extensions/forge-status/src/web/WEB-INF/portlet-instances.xml =================================================================== --- trunk/forge/portal-extensions/forge-status/src/web/WEB-INF/portlet-instances.xml 2005-11-09 22:23:15 UTC (rev 1548) +++ trunk/forge/portal-extensions/forge-status/src/web/WEB-INF/portlet-instances.xml 2005-11-10 01:17:01 UTC (rev 1549) @@ -0,0 +1,7 @@ +<?xml version="1.0" standalone="yes"?> +<instances> + <instance> + <instance-name>StatusPortletInstance</instance-name> + <component-ref>StatusPortlet</component-ref> + </instance> +</instances> Added: trunk/forge/portal-extensions/forge-status/src/web/WEB-INF/portlet.xml =================================================================== --- trunk/forge/portal-extensions/forge-status/src/web/WEB-INF/portlet.xml 2005-11-09 22:23:15 UTC (rev 1548) +++ trunk/forge/portal-extensions/forge-status/src/web/WEB-INF/portlet.xml 2005-11-10 01:17:01 UTC (rev 1549) @@ -0,0 +1,18 @@ +<?xml version="1.0" encoding="UTF-8"?> +<portlet-app xmlns="http://java.sun.com/xml/ns/portlet/portlet-app_1_0.xsd" + version="1.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xsi:schemaLocation="http://java.sun.com/xml/ns/portlet/portlet-app_1_0.xsd http://java.sun.com/xml/ns/portlet/portlet-app_1_0.xsd"> + <portlet> + <description>Status Portlet</description> + <portlet-name>StatusPortlet</portlet-name> + <display-name>Status</display-name> + <portlet-class>org.jboss.forge.status.StatusPortlet</portlet-class> + <supports> + <mime-type>text/html</mime-type> + <portlet-mode>VIEW</portlet-mode> + </supports> + <portlet-info> + <title>Status</title> + </portlet-info> + </portlet> + </portlet-app> Added: trunk/forge/portal-extensions/forge-status/src/web/WEB-INF/tld/forge.tld =================================================================== --- trunk/forge/portal-extensions/forge-status/src/web/WEB-INF/tld/forge.tld 2005-11-09 22:23:15 UTC (rev 1548) +++ trunk/forge/portal-extensions/forge-status/src/web/WEB-INF/tld/forge.tld 2005-11-10 01:17:01 UTC (rev 1549) @@ -0,0 +1,139 @@ +<taglib xmlns="http://java.sun.com/xml/ns/j2ee" + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee web-jsptaglibrary_2_0.xsd" + version="2.0"> + <!-- + JBoss, the OpenSource J2EE webOS + Distributable under LGPL license. + See terms of license at gnu.org. + --> + <tlib-version>1.1</tlib-version> + <jsp-version>2.0</jsp-version> + <shortname>forge</shortname> + <info>Forge tags</info> + + <tag> + <name>pageURL</name> + <tagclass>org.jboss.forge.common.taglib.PageURLTag</tagclass> + <attribute> + <name>page</name> + <required>true</required> + <rtexprvalue>true</rtexprvalue> + </attribute> + <attribute> + <name>form</name> + <required>false</required> + <rtexprvalue>true</rtexprvalue> + </attribute> + </tag> + + <tag> + <name>param</name> + <tagclass>org.jboss.forge.common.taglib.ParamTag</tagclass> + <attribute> + <name>name</name> + <required>true</required> + <rtexprvalue>true</rtexprvalue> + </attribute> + <attribute> + <name>value</name> + <required>true</required> + <rtexprvalue>true</rtexprvalue> + </attribute> + </tag> + + <tag> + <name>wikiURL</name> + <tagclass>org.jboss.forge.common.taglib.WikiURLTag</tagclass> + <attribute> + <name>page</name> + <required>true</required> + <rtexprvalue>true</rtexprvalue> + </attribute> + </tag> + + <tag> + <name>freezoneURL</name> + <tagclass>org.jboss.forge.common.taglib.FreezoneURLTag</tagclass> + <attribute> + <name>page</name> + <required>true</required> + <rtexprvalue>true</rtexprvalue> + </attribute> + </tag> + + <tag> + <name>projectURL</name> + <tagclass>org.jboss.forge.common.taglib.ProjectURLTag</tagclass> + <attribute> + <name>project</name> + <required>true</required> + <rtexprvalue>true</rtexprvalue> + </attribute> + <attribute> + <name>page</name> + <required>false</required> + <rtexprvalue>true</rtexprvalue> + </attribute> + <attribute> + <name>form</name> + <required>false</required> + <rtexprvalue>true</rtexprvalue> + </attribute> + </tag> + + <tag> + <name>categoryURL</name> + <tagclass>org.jboss.forge.common.taglib.CategoryURLTag</tagclass> + <attribute> + <name>category</name> + <required>true</required> + <rtexprvalue>true</rtexprvalue> + </attribute> + <attribute> + <name>form</name> + <required>false</required> + <rtexprvalue>true</rtexprvalue> + </attribute> + </tag> + + <tag> + <name>selectedProject</name> + <tagclass>org.jboss.forge.common.taglib.SelectedProjectTag</tagclass> + </tag> + + <tag> + <name>imagePath</name> + <tagclass>org.jboss.forge.common.taglib.ImagePathTag</tagclass> + <attribute> + <name>src</name> + <required>true</required> + <rtexprvalue>true</rtexprvalue> + </attribute> + <attribute> + <name>project</name> + <required>false</required> + <rtexprvalue>true</rtexprvalue> + </attribute> + </tag> + + <tag> + <name>attrValue</name> + <tagclass>org.jboss.forge.common.taglib.AttrValueTag</tagclass> + <attribute> + <name>name</name> + <required>true</required> + <rtexprvalue>true</rtexprvalue> + </attribute> + </tag> + + <tag> + <name>attrIf</name> + <tagclass>org.jboss.forge.common.taglib.AttrIfTag</tagclass> + <attribute> + <name>name</name> + <required>true</required> + <rtexprvalue>true</rtexprvalue> + </attribute> + </tag> +</taglib> Added: trunk/forge/portal-extensions/forge-status/src/web/WEB-INF/tld/portlet.tld =================================================================== --- trunk/forge/portal-extensions/forge-status/src/web/WEB-INF/tld/portlet.tld 2005-11-09 22:23:15 UTC (rev 1548) +++ trunk/forge/portal-extensions/forge-status/src/web/WEB-INF/tld/portlet.tld 2005-11-10 01:17:01 UTC (rev 1549) @@ -0,0 +1,77 @@ +<taglib xmlns="http://java.sun.com/xml/ns/j2ee" + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee web-jsptaglibrary_2_0.xsd" + version="2.0"> + <tlib-version>1.1</tlib-version> + <jsp-version>2.0</jsp-version> + <shortname>JBoss Portal tags</shortname> + <info>JBoss Portal tags</info> + + <function> + <name>i18n</name> + <function-class>org.jboss.portal.core.servlet.jsp.taglib.PortalLib</function-class> + <function-signature>java.lang.String getMessage(java.lang.String)</function-signature> + </function> + + <function> + <name>out</name> + <function-class>org.jboss.portal.core.servlet.jsp.taglib.PortalLib</function-class> + <function-signature>java.lang.String out(java.lang.String)</function-signature> + </function> + + <function> + <name>i18nout</name> + <function-class>org.jboss.portal.core.servlet.jsp.taglib.PortalLib</function-class> + <function-signature>java.lang.String i18nOut(java.lang.String)</function-signature> + </function> + + <tag> + <name>if</name> + <tagclass>org.jboss.portal.core.servlet.jsp.taglib.IfTag</tagclass> + <attribute> + <name>ctx</name> + <required>true</required> + <rtexprvalue>true</rtexprvalue> + </attribute> + </tag> + + <tag> + <name>iterate</name> + <tagclass>org.jboss.portal.core.servlet.jsp.taglib.IterateTag</tagclass> + <attribute> + <name>ctx</name> + <required>true</required> + <rtexprvalue>true</rtexprvalue> + </attribute> + </tag> + + <tag> + <name>include</name> + <tagclass>org.jboss.portal.core.servlet.jsp.taglib.IncludeTag</tagclass> + <attribute> + <name>page</name> + <required>true</required> + <rtexprvalue>true</rtexprvalue> + </attribute> + </tag> + + <tag> + <name>error</name> + <tagclass>org.jboss.portal.core.servlet.jsp.taglib.ErrorTag</tagclass> + <attribute> + <name>key</name> + <required>true</required> + <rtexprvalue>true</rtexprvalue> + </attribute> + </tag> + + <tag> + <name>errors</name> + <tagclass>org.jboss.portal.core.servlet.jsp.taglib.ErrorsTag</tagclass> + </tag> + + <tag> + <name>success</name> + <tagclass>org.jboss.portal.core.servlet.jsp.taglib.SuccessTag</tagclass> + </tag> +</taglib> Added: trunk/forge/portal-extensions/forge-status/src/web/WEB-INF/web.xml =================================================================== --- trunk/forge/portal-extensions/forge-status/src/web/WEB-INF/web.xml 2005-11-09 22:23:15 UTC (rev 1548) +++ trunk/forge/portal-extensions/forge-status/src/web/WEB-INF/web.xml 2005-11-10 01:17:01 UTC (rev 1549) @@ -0,0 +1,16 @@ +<?xml version="1.0"?> +<!DOCTYPE web-app PUBLIC + "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN" + "http://java.sun.com/dtd/web-app_2_3.dtd"> +<web-app> + <filter> + <filter-name>filesFromRepoFilter</filter-name> + <filter-class>org.jboss.forge.common.FilesFromRepoFilter</filter-class> + </filter> + + <filter-mapping> + <filter-name>filesFromRepoFilter</filter-name> + <url-pattern>/repo-access/*</url-pattern> + <dispatcher>INCLUDE</dispatcher> + </filter-mapping> +</web-app> \ No newline at end of file Modified: trunk/forge/portal-extensions/portal-default/src/web/WEB-INF/default-portal.xml =================================================================== --- trunk/forge/portal-extensions/portal-default/src/web/WEB-INF/default-portal.xml 2005-11-09 22:23:15 UTC (rev 1548) +++ trunk/forge/portal-extensions/portal-default/src/web/WEB-INF/default-portal.xml 2005-11-10 01:17:01 UTC (rev 1549) @@ -384,6 +384,34 @@ </window> </page> + + <page> + <page-name>status</page-name> + + <window> + <window-name>NavigationPortletWindowDefaultStatus</window-name> + <instance-ref>navigation.NavigationPortlet.NavigationPortletInstance</instance-ref> + <region>left</region> + <height>0</height> + <window-state>normal</window-state> + </window> + + <window> + <window-name>AdsPortletWindowDefaultStatus</window-name> + <instance-ref>ads.AdsPortlet.AdsPortletInstance</instance-ref> + <region>left</region> + <height>2</height> + <window-state>normal</window-state> + </window> + + <window> + <window-name>StatusPortletWindowDefaultStatus</window-name> + <instance-ref>status.StatusPortlet.StatusPortletInstance</instance-ref> + <region>center</region> + <height>0</height> + </window> + + </page> </pages> </portal> |