JBoss Portal SVN: r10177 - in modules/portlet/trunk: portlet/src/main/java/org/jboss/portal/portlet/impl/jsr168 and 8 other directories.
by portal-commits@lists.jboss.org
Author: julien(a)jboss.com
Date: 2008-03-03 04:51:51 -0500 (Mon, 03 Mar 2008)
New Revision: 10177
Added:
modules/portlet/trunk/portlet/src/test/java/org/jboss/portal/test/portlet/jsr286/tck/userinformation/
modules/portlet/trunk/portlet/src/test/java/org/jboss/portal/test/portlet/jsr286/tck/userinformation/NullProfileForUnauthenticatedIdentityTestCase.java
modules/portlet/trunk/test/src/test/resources/jsr286/tck/userinformation-war/
modules/portlet/trunk/test/src/test/resources/jsr286/tck/userinformation-war/WEB-INF/
modules/portlet/trunk/test/src/test/resources/jsr286/tck/userinformation-war/WEB-INF/portlet.xml
modules/portlet/trunk/test/src/test/resources/jsr286/tck/userinformation-war/WEB-INF/web.xml
Modified:
modules/portlet/trunk/pom.xml
modules/portlet/trunk/portlet/src/main/java/org/jboss/portal/portlet/impl/jsr168/PortletRequestAttributes.java
modules/portlet/trunk/portlet/src/main/java/org/jboss/portal/portlet/impl/jsr168/api/PortletRequestImpl.java
modules/portlet/trunk/test/src/test/build.xml
modules/portlet/trunk/test/src/test/resources/test/remote-jboss-unit.xml
Log:
- added test case to assert that the user profile is not present when the user is not authenticated
- added maven profiles for portlet module
Modified: modules/portlet/trunk/pom.xml
===================================================================
--- modules/portlet/trunk/pom.xml 2008-03-02 23:21:50 UTC (rev 10176)
+++ modules/portlet/trunk/pom.xml 2008-03-03 09:51:51 UTC (rev 10177)
@@ -32,6 +32,39 @@
<module>docs</module>
</modules>
</profile>
+ <profile>
+ <id>test</id>
+ <modules>
+ <module>build</module>
+ <module>portlet</module>
+ <module>controller</module>
+ <module>mc</module>
+ <module>test</module>
+ </modules>
+ </profile>
+ <profile>
+ <id>simple-portal</id>
+ <modules>
+ <module>build</module>
+ <module>portlet</module>
+ <module>controller</module>
+ <module>mc</module>
+ <module>portal</module>
+ <module>samples</module>
+ </modules>
+ </profile>
+ <profile>
+ <id>release</id>
+ <modules>
+ <module>build</module>
+ <module>portlet</module>
+ <module>controller</module>
+ <module>mc</module>
+ <module>portal</module>
+ <module>samples</module>
+ <module>docs</module>
+ </modules>
+ </profile>
</profiles>
<modules>
Modified: modules/portlet/trunk/portlet/src/main/java/org/jboss/portal/portlet/impl/jsr168/PortletRequestAttributes.java
===================================================================
--- modules/portlet/trunk/portlet/src/main/java/org/jboss/portal/portlet/impl/jsr168/PortletRequestAttributes.java 2008-03-02 23:21:50 UTC (rev 10176)
+++ modules/portlet/trunk/portlet/src/main/java/org/jboss/portal/portlet/impl/jsr168/PortletRequestAttributes.java 2008-03-03 09:51:51 UTC (rev 10177)
@@ -23,7 +23,9 @@
package org.jboss.portal.portlet.impl.jsr168;
import org.jboss.portal.portlet.impl.info.ContainerUserInfo;
+import org.jboss.portal.portlet.impl.jsr168.api.PortletRequestImpl;
import org.jboss.portal.portlet.spi.UserContext;
+import org.jboss.portal.portlet.spi.SecurityContext;
import org.jboss.portal.portlet.container.PortletContainer;
import javax.portlet.PortletRequest;
@@ -56,6 +58,9 @@
protected static final Object REMOVED_ATTRIBUTE = new Object();
/** . */
+ private final SecurityContext securityContext;
+
+ /** . */
private final PortletContainer container;
/** . */
@@ -68,10 +73,15 @@
private Map<String, Object> attributes;
public PortletRequestAttributes(
+ SecurityContext securityContext,
PortletContainer container,
UserContext userContext,
HttpServletRequestWrapper wreq)
{
+ if (securityContext == null)
+ {
+ throw new IllegalArgumentException("No null portlet request allowed");
+ }
if (container == null)
{
throw new IllegalArgumentException("No null container allowed");
@@ -85,6 +95,8 @@
throw new IllegalArgumentException("No null wrapped request allowed");
}
+ //
+ this.securityContext = securityContext;
this.container = container;
this.userContext = userContext;
this.wreq = wreq;
@@ -98,6 +110,12 @@
}
if (PortletRequest.USER_INFO.equals(name))
{
+ if (!securityContext.isAuthenticated())
+ {
+ return null;
+ }
+
+ //
Map<String, String> infos = userContext.getInformations();
//
@@ -116,6 +134,10 @@
// Make it immutable
infos = Collections.unmodifiableMap(infos);
}
+ else
+ {
+ infos = Collections.emptyMap();
+ }
//
return infos;
@@ -170,9 +192,14 @@
}
}
}
- names.add(PortletRequest.USER_INFO);
//
+ if (securityContext.isAuthenticated())
+ {
+ names.add(PortletRequest.USER_INFO);
+ }
+
+ //
return names.iterator();
}
Modified: modules/portlet/trunk/portlet/src/main/java/org/jboss/portal/portlet/impl/jsr168/api/PortletRequestImpl.java
===================================================================
--- modules/portlet/trunk/portlet/src/main/java/org/jboss/portal/portlet/impl/jsr168/api/PortletRequestImpl.java 2008-03-02 23:21:50 UTC (rev 10176)
+++ modules/portlet/trunk/portlet/src/main/java/org/jboss/portal/portlet/impl/jsr168/api/PortletRequestImpl.java 2008-03-03 09:51:51 UTC (rev 10177)
@@ -149,7 +149,7 @@
HttpServletRequestWrapper realReq = new HttpServletRequestWrapper(invocation.getDispatchedRequest());
//
- PortletRequestAttributes attributes = new PortletRequestAttributes(container, userContext, realReq);
+ PortletRequestAttributes attributes = new PortletRequestAttributes(invocation.getSecurityContext(), container, userContext, realReq);
if (invocation.getAttributes() != null)
{
attributes.setAttributeMap(invocation.getAttributes());
Added: modules/portlet/trunk/portlet/src/test/java/org/jboss/portal/test/portlet/jsr286/tck/userinformation/NullProfileForUnauthenticatedIdentityTestCase.java
===================================================================
--- modules/portlet/trunk/portlet/src/test/java/org/jboss/portal/test/portlet/jsr286/tck/userinformation/NullProfileForUnauthenticatedIdentityTestCase.java (rev 0)
+++ modules/portlet/trunk/portlet/src/test/java/org/jboss/portal/test/portlet/jsr286/tck/userinformation/NullProfileForUnauthenticatedIdentityTestCase.java 2008-03-03 09:51:51 UTC (rev 10177)
@@ -0,0 +1,73 @@
+/******************************************************************************
+ * JBoss, a division of Red Hat *
+ * Copyright 2008, Red Hat Middleware, LLC, 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.portal.test.portlet.jsr286.tck.userinformation;
+
+import org.jboss.portal.unit.PortletTestCase;
+import org.jboss.portal.unit.PortletTestContext;
+import org.jboss.portal.unit.Assertion;
+import org.jboss.portal.unit.annotations.TestCase;
+import org.jboss.portal.unit.actions.PortletRenderTestAction;
+import org.jboss.portal.test.portlet.framework.UTP1;
+import org.jboss.portal.common.util.Tools;
+import org.jboss.unit.driver.DriverResponse;
+import org.jboss.unit.driver.response.EndTestResponse;
+import static org.jboss.unit.api.Assert.*;
+
+import javax.portlet.Portlet;
+import javax.portlet.RenderRequest;
+import javax.portlet.RenderResponse;
+import javax.portlet.PortletException;
+import javax.portlet.PortletRequest;
+import java.io.IOException;
+import java.util.Set;
+
+/**
+ * @author <a href="mailto:julien@jboss.org">Julien Viet</a>
+ * @version $Revision: 630 $
+ */
+(a)TestCase(/*Assertion.JSR286_302*/)
+public class NullProfileForUnauthenticatedIdentityTestCase
+{
+
+ public NullProfileForUnauthenticatedIdentityTestCase(PortletTestCase seq)
+ {
+ seq.bindAction(0, UTP1.RENDER_JOIN_POINT, new PortletRenderTestAction()
+ {
+ protected DriverResponse run(Portlet portlet, RenderRequest request, RenderResponse response, PortletTestContext context) throws PortletException, IOException
+ {
+ assertNull(request.getUserPrincipal());
+
+ //
+ Object info = request.getAttribute(PortletRequest.USER_INFO);
+ assertNull("Was not expecting a profile", info);
+
+ //
+ Set<String> names = Tools.toSet(request.getAttributeNames());
+ assertFalse(names.contains(PortletRequest.USER_INFO));
+
+ //
+ return new EndTestResponse();
+ }
+ });
+ }
+}
Modified: modules/portlet/trunk/test/src/test/build.xml
===================================================================
--- modules/portlet/trunk/test/src/test/build.xml 2008-03-02 23:21:50 UTC (rev 10176)
+++ modules/portlet/trunk/test/src/test/build.xml 2008-03-03 09:51:51 UTC (rev 10177)
@@ -79,15 +79,7 @@
<pathelement path="${dependency.jbossxb.jar}"/>
</path>
<path id="mc.jboss_aop">
- <!--<pathelement path="${dependency.jboss-aop-as4-deployer.jar}"/>-->
- <!--<pathelement path="${dependency.jboss-aop-deployer-jdk50.jar}"/>-->
- <!--<pathelement path="${dependency.jboss-aop-jdk50.jar}"/>-->
- <!--<pathelement path="${dependency.jboss-aop-jdk50-client.jar}"/>-->
- <!--<pathelement path="${dependency.jboss-standalone-aspect-library-jdk50.jar}"/>-->
- <!--<pathelement path="${dependency.jrockit-pluggable-instrumentor.jar}"/>-->
- <!--<pathelement path="${dependency.pluggable-instrumentor.jar}"/>-->
<pathelement path="${dependency.jboss-aop.jar}"/>
-
</path>
<path id="mc.jboss_microcontainer">
<pathelement path="${dependency.jboss-aop-mc-int.jar}"/>
@@ -377,6 +369,7 @@
<package-jsr286-tck-test test="portleturl"/>
<package-jsr286-tck-test test="portletfilter"/>
<package-jsr286-tck-test test="taglib"/>
+ <package-jsr286-tck-test test="userinformation"/>
<package-jsr286-api-test test="event"/>
<package-jsr286-api-test test="portleturl"/>
<package-jsr286-ext-test test="portletrequests"/>
@@ -848,69 +841,4 @@
</target>
-<!--
- <target name="__package-demo-portlets" depends="prepare_env">
-
- <property name="samples.target.dir" value="${portal.dir}/samples"/>
- <property name="samples.tmp.dir" value="${test.temp.dir}/portal"/>
-
- <mkdir dir="${samples.tmp.dir}"/>
- <mkdir dir="${samples.target.dir}"/>
-
- <copy todir="${samples.tmp.dir}/samples-google-map-portlet-war">
- <fileset dir="src/test/resources/portal/samples/google-map-portlet-war"/>
- </copy>
- <copy todir="${samples.tmp.dir}/samples-google-map-portlet-war/WEB-INF/classes">
- <fileset dir="${target}/classes"
- includes="org/jboss/portal/portlet/portal/samples/GoogleClippingPortlet.class"/>
- </copy>
- <jar jarfile="${samples.target.dir}/samples-google-map-portlet.war">
- <fileset dir="${samples.tmp.dir}/samples-google-map-portlet-war"/>
- </jar>
-
- <copy todir="${samples.tmp.dir}/samples-google-weather-portlet-war">
- <fileset dir="src/test/resources/portal/samples/google-weather-portlet-war"/>
- </copy>
- <copy todir="${samples.tmp.dir}/samples-google-weather-portlet-war/WEB-INF/classes">
- <fileset dir="${target}/classes" includes="org/jboss/portal/portlet/portal/samples/*.class"
- excludes="org/jboss/portal/portlet/portal/samples/RemoteControlResourcePortlet.class"/>
- </copy>
- <jar jarfile="${samples.target.dir}/samples-google-weather-portlet.war">
- <fileset dir="${samples.tmp.dir}/samples-google-weather-portlet-war"/>
- </jar>
-
- <copy todir="${samples.tmp.dir}/samples-remotecontrol-portlet-war">
- <fileset dir="src/test/resources/portal/samples/remotecontrol-portlet-war"/>
- </copy>
- <copy todir="${samples.tmp.dir}/samples-remotecontrol-portlet-war/WEB-INF/classes">
- <fileset dir="${target}/classes"
- includes="org/jboss/portal/portlet/portal/samples/RemoteControlResourcePortlet.class"/>
- </copy>
- <jar jarfile="${samples.target.dir}/samples-remotecontrol-portlet.war">
- <fileset dir="${samples.tmp.dir}/samples-remotecontrol-portlet-war"/>
- </jar>
-
- <copy todir="${samples.tmp.dir}/samples-cart-event-portlet-war">
- <fileset dir="src/test/resources/portal/samples/cart-event-portlet-war"/>
- </copy>
- <copy todir="${samples.tmp.dir}/samples-cart-event-portlet-war/WEB-INF/classes">
- <fileset dir="${target}/classes" includes="org/jboss/portal/portlet/portal/samples/event/*.class"/>
- </copy>
- <jar jarfile="${samples.target.dir}/samples-cart-event-portlet.war">
- <fileset dir="${samples.tmp.dir}/samples-cart-event-portlet-war"/>
- </jar>
-
- <copy todir="${samples.tmp.dir}/samples-basic-war">
- <fileset dir="src/test/resources/portal/samples/basic-war"/>
- </copy>
- <copy todir="${samples.tmp.dir}/samples-basic-war/WEB-INF/classes">
- <fileset dir="${target}/classes" includes="org/jboss/portal/portlet/portal/samples/basic/**"/>
- </copy>
- <jar jarfile="${samples.target.dir}/samples-basic.war">
- <fileset dir="${samples.tmp.dir}/samples-basic-war"/>
- </jar>
-
- </target>
--->
-
</project>
\ No newline at end of file
Added: modules/portlet/trunk/test/src/test/resources/jsr286/tck/userinformation-war/WEB-INF/portlet.xml
===================================================================
--- modules/portlet/trunk/test/src/test/resources/jsr286/tck/userinformation-war/WEB-INF/portlet.xml (rev 0)
+++ modules/portlet/trunk/test/src/test/resources/jsr286/tck/userinformation-war/WEB-INF/portlet.xml 2008-03-03 09:51:51 UTC (rev 10177)
@@ -0,0 +1,42 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ ~ JBoss, a division of Red Hat ~
+ ~ Copyright 2006, Red Hat Middleware, LLC, 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. ~
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~-->
+
+<portlet-app xmlns="http://java.sun.com/xml/ns/portlet/portlet-app_2_0.xsd"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:schemaLocation="http://java.sun.com/xml/ns/portlet/portlet-app_2_0.xsd http://java.sun.com/xml/ns/portlet/portlet-app_2_0.xsd"
+ version="2.0">
+
+ <portlet>
+ <portlet-name>UniversalTestPortletA</portlet-name>
+ <portlet-class>org.jboss.portal.test.portlet.framework.UTP1</portlet-class>
+ <supports>
+ <mime-type>text/html</mime-type>
+ </supports>
+ </portlet>
+
+ <user-attribute>
+ <name>user.name.given</name>
+ </user-attribute>
+
+</portlet-app>
Added: modules/portlet/trunk/test/src/test/resources/jsr286/tck/userinformation-war/WEB-INF/web.xml
===================================================================
--- modules/portlet/trunk/test/src/test/resources/jsr286/tck/userinformation-war/WEB-INF/web.xml (rev 0)
+++ modules/portlet/trunk/test/src/test/resources/jsr286/tck/userinformation-war/WEB-INF/web.xml 2008-03-03 09:51:51 UTC (rev 10177)
@@ -0,0 +1,32 @@
+<?xml version="1.0"?>
+<!--~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ ~ JBoss, a division of Red Hat ~
+ ~ Copyright 2006, Red Hat Middleware, LLC, 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. ~
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~-->
+
+<!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>
+ <listener>
+ <listener-class>org.jboss.portal.unit.PortletTestSuite</listener-class>
+ </listener>
+</web-app>
Modified: modules/portlet/trunk/test/src/test/resources/test/remote-jboss-unit.xml
===================================================================
--- modules/portlet/trunk/test/src/test/resources/test/remote-jboss-unit.xml 2008-03-02 23:21:50 UTC (rev 10176)
+++ modules/portlet/trunk/test/src/test/resources/test/remote-jboss-unit.xml 2008-03-03 09:51:51 UTC (rev 10177)
@@ -191,6 +191,10 @@
<class name="org.jboss.unit.remote.driver.RemoteTestDriverClient"/>
<property name="archiveId" value="test-jsr286-tck-taglib.war"/>
</generic>
+ <generic>
+ <class name="org.jboss.unit.remote.driver.RemoteTestDriverClient"/>
+ <property name="archiveId" value="test-jsr286-tck-userinformation.war"/>
+ </generic>
<!--Spec API Assertions tests-->
<generic>
16 years, 3 months
JBoss Portal SVN: r10176 - in modules/portlet/trunk: build/distrib/jboss-4.2/server/default/deploy/jboss-web.deployer/conf and 10 other directories.
by portal-commits@lists.jboss.org
Author: julien(a)jboss.com
Date: 2008-03-02 18:21:50 -0500 (Sun, 02 Mar 2008)
New Revision: 10176
Added:
modules/portlet/trunk/samples/src/assemble/samples-jsp-portlet.xml
modules/portlet/trunk/samples/src/main/artifacts/jsp-portlet-war/
modules/portlet/trunk/samples/src/main/artifacts/jsp-portlet-war/WEB-INF/
modules/portlet/trunk/samples/src/main/artifacts/jsp-portlet-war/WEB-INF/jsp/
modules/portlet/trunk/samples/src/main/artifacts/jsp-portlet-war/WEB-INF/jsp/view.jsp
modules/portlet/trunk/samples/src/main/artifacts/jsp-portlet-war/WEB-INF/portlet.xml
modules/portlet/trunk/samples/src/main/artifacts/jsp-portlet-war/WEB-INF/web.xml
modules/portlet/trunk/samples/src/main/artifacts/jsp-portlet-war/images/
modules/portlet/trunk/samples/src/main/artifacts/jsp-portlet-war/images/accessorize.gif
modules/portlet/trunk/samples/src/main/artifacts/jsp-portlet-war/images/dodemo.gif
modules/portlet/trunk/samples/src/main/artifacts/jsp-portlet-war/images/getcode.gif
modules/portlet/trunk/samples/src/main/java/org/jboss/portal/portlet/samples/jsp/
modules/portlet/trunk/samples/src/main/java/org/jboss/portal/portlet/samples/jsp/JSPPortlet.java
Modified:
modules/portlet/trunk/build/distrib/distrib.xml
modules/portlet/trunk/build/distrib/jboss-4.2/server/default/deploy/jboss-web.deployer/conf/web.xml
modules/portlet/trunk/portal/src/main/resources/simple-portal-war/demo/demo.jsp
modules/portlet/trunk/samples/pom.xml
Log:
- added JSP sample coming from 2.6.4 GA
- added configuration of global tld for jboss 4.2
Modified: modules/portlet/trunk/build/distrib/distrib.xml
===================================================================
--- modules/portlet/trunk/build/distrib/distrib.xml 2008-03-02 22:25:32 UTC (rev 10175)
+++ modules/portlet/trunk/build/distrib/distrib.xml 2008-03-02 23:21:50 UTC (rev 10176)
@@ -139,6 +139,7 @@
<copy file="${source.dir}/samples/target/portlet-samples-${maven.version}-samples-google-portlet.war" tofile="${bin.dir}/samples/samples-google-portlet.war"/>
<copy file="${source.dir}/samples/target/portlet-samples-${maven.version}-samples-remotecontroller-portlet.war" tofile="${bin.dir}/samples/samples-remotecontroller-portlet.war"/>
<copy file="${source.dir}/samples/target/portlet-samples-${maven.version}-samples-shoppingcart-portlet.war" tofile="${bin.dir}/samples/samples-shoppingcart-portlet.war"/>
+ <copy file="${source.dir}/samples/target/portlet-samples-${maven.version}-samples-jsp-portlet.war" tofile="${bin.dir}/samples/samples-jsp-portlet.war"/>
</target>
<target name="__package-bundled-binary" unless="bin-alone">
@@ -146,6 +147,7 @@
<copy file="${source.dir}/samples/target/portlet-samples-${maven.version}-samples-google-portlet.war" tofile="${deploy.dir}/samples-google-portlet.war"/>
<copy file="${source.dir}/samples/target/portlet-samples-${maven.version}-samples-remotecontroller-portlet.war" tofile="${deploy.dir}/samples-remotecontroller-portlet.war"/>
<copy file="${source.dir}/samples/target/portlet-samples-${maven.version}-samples-shoppingcart-portlet.war" tofile="${deploy.dir}/samples-shoppingcart-portlet.war"/>
+ <copy file="${source.dir}/samples/target/portlet-samples-${maven.version}-samples-jsp-portlet.war" tofile="${deploy.dir}/samples-jsp-portlet.war"/>
</target>
<target name="__package-distrib">
Modified: modules/portlet/trunk/build/distrib/jboss-4.2/server/default/deploy/jboss-web.deployer/conf/web.xml
===================================================================
--- modules/portlet/trunk/build/distrib/jboss-4.2/server/default/deploy/jboss-web.deployer/conf/web.xml 2008-03-02 22:25:32 UTC (rev 10175)
+++ modules/portlet/trunk/build/distrib/jboss-4.2/server/default/deploy/jboss-web.deployer/conf/web.xml 2008-03-02 23:21:50 UTC (rev 10176)
@@ -306,7 +306,7 @@
<init-param>
<description>Portlet standard tlds</description>
<param-name>tagLibJar2</param-name>
- <param-value>../simple-portal/portlet-portlet-2.0-SNAPSHOT.jar</param-value>
+ <param-value>../simple-portal/lib/portlet-portlet-2.0-SNAPSHOT.jar</param-value>
</init-param>
<load-on-startup>3</load-on-startup>
Modified: modules/portlet/trunk/portal/src/main/resources/simple-portal-war/demo/demo.jsp
===================================================================
--- modules/portlet/trunk/portal/src/main/resources/simple-portal-war/demo/demo.jsp 2008-03-02 22:25:32 UTC (rev 10175)
+++ modules/portlet/trunk/portal/src/main/resources/simple-portal-war/demo/demo.jsp 2008-03-02 23:21:50 UTC (rev 10176)
@@ -19,6 +19,7 @@
<jbp:portlet name="GoogleMap" applicationName="samples-google-portlet"/>
<jbp:portlet name="GoogleWeather" applicationName="samples-google-portlet"/>
<jbp:portlet name="Catalog" applicationName="samples-shoppincart-portlet"/>
+ <jbp:portlet name="JSPPortlet" applicationName="samples-jsp-portlet"/>
</jsp:attribute>
</jbp:layout1>
</portal:page>
Modified: modules/portlet/trunk/samples/pom.xml
===================================================================
--- modules/portlet/trunk/samples/pom.xml 2008-03-02 22:25:32 UTC (rev 10175)
+++ modules/portlet/trunk/samples/pom.xml 2008-03-02 23:21:50 UTC (rev 10176)
@@ -32,6 +32,7 @@
<descriptor>src/assemble/samples-shoppingcart-portlet.xml</descriptor>
<descriptor>src/assemble/samples-google-portlet.xml</descriptor>
<descriptor>src/assemble/samples-remotecontroller-portlet.xml</descriptor>
+ <descriptor>src/assemble/samples-jsp-portlet.xml</descriptor>
</descriptors>
</configuration>
</plugin>
Copied: modules/portlet/trunk/samples/src/assemble/samples-jsp-portlet.xml (from rev 10175, modules/portlet/trunk/samples/src/assemble/samples-basic-portlet.xml)
===================================================================
--- modules/portlet/trunk/samples/src/assemble/samples-jsp-portlet.xml (rev 0)
+++ modules/portlet/trunk/samples/src/assemble/samples-jsp-portlet.xml 2008-03-02 23:21:50 UTC (rev 10176)
@@ -0,0 +1,22 @@
+<assembly>
+ <id>samples-jsp-portlet</id>
+ <formats>
+ <format>war</format>
+ </formats>
+ <includeBaseDirectory>false</includeBaseDirectory>
+
+ <fileSets>
+ <fileSet>
+ <directory>src/main/artifacts/jsp-portlet-war</directory>
+ <outputDirectory></outputDirectory>
+ </fileSet>
+ <fileSet>
+ <directory>target/classes</directory>
+ <outputDirectory>WEB-INF/classes</outputDirectory>
+ <includes>
+ <include>org/jboss/portal/portlet/samples/jsp/**</include>
+ </includes>
+ </fileSet>
+ </fileSets>
+
+</assembly>
\ No newline at end of file
Added: modules/portlet/trunk/samples/src/main/artifacts/jsp-portlet-war/WEB-INF/jsp/view.jsp
===================================================================
--- modules/portlet/trunk/samples/src/main/artifacts/jsp-portlet-war/WEB-INF/jsp/view.jsp (rev 0)
+++ modules/portlet/trunk/samples/src/main/artifacts/jsp-portlet-war/WEB-INF/jsp/view.jsp 2008-03-02 23:21:50 UTC (rev 10176)
@@ -0,0 +1,64 @@
+<%@ page %>
+<%--~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+~ JBoss, a division of Red Hat ~
+~ Copyright 2006, Red Hat Middleware, LLC, 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. ~
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~--%>
+
+<%@ taglib uri="http://java.sun.com/portlet" prefix="portlet" %>
+<%@ page isELIgnored="false" %>
+
+<portlet:defineObjects/>
+
+<table border="0" cellspacing="2" cellpadding="2">
+ <tr>
+ <td align="center"><a href="http://portal.demo.jboss.com" target="_blank"><img
+ src="<%= renderRequest.getContextPath() %>/images/dodemo.gif" border="0"
+ alt="Try the latest release of JBoss Portal, live and online."></a>
+ <a href="http://labs.jboss.com/portal/jbossportal/download/index.html" target="_blank"><img
+ src="<%= renderRequest.getContextPath() %>/images/getcode.gif" border="0"
+ alt="Download JBoss Portal and have it up and running in minutes."></a>
+ <a href="http://www.portletswap.com" target="_blank"><img
+ src="<%= renderRequest.getContextPath() %>/images/accessorize.gif" border="0"
+ alt="Download portlets and layouts for your new JBoss Portal installation."></a></td>
+ </tr>
+ <tr>
+ <td></td>
+ </tr>
+ <tr>
+ <td class="portlet-section-alternate">
+ <font class="portlet-font">This is an installation of <b>JBoss Portlet Container 2.0
+ </b>. You may
+ log in at any time, using the <i>Login</i> link at the top-right of this page, with the following
+ credentials:</font>
+ </td>
+ </tr>
+ <tr>
+ <td class="portlet-section-alternate" align="center">
+ <b>user/user</b> or <b>admin/admin</b>
+ </td>
+ </tr>
+ <tr>
+ <td align="center">
+ If you are in need of guidance with regards to navigating, configuring, or operating the portal, please view
+ our <a href="http://labs.jboss.com/portal/jbossportal/docs/index.html" target="_blank">online documentation</a>.
+ </td>
+ </tr>
+</table>
Added: modules/portlet/trunk/samples/src/main/artifacts/jsp-portlet-war/WEB-INF/portlet.xml
===================================================================
--- modules/portlet/trunk/samples/src/main/artifacts/jsp-portlet-war/WEB-INF/portlet.xml (rev 0)
+++ modules/portlet/trunk/samples/src/main/artifacts/jsp-portlet-war/WEB-INF/portlet.xml 2008-03-02 23:21:50 UTC (rev 10176)
@@ -0,0 +1,44 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ ~ JBoss, a division of Red Hat ~
+ ~ Copyright 2006, Red Hat Middleware, LLC, 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. ~
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~-->
+
+<portlet-app
+ xmlns="http://java.sun.com/xml/ns/portlet/portlet-app_1_0.xsd"
+ 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"
+ version="1.0">
+ <portlet>
+ <description>Simple JSP portlet</description>
+ <portlet-name>JSPPortlet</portlet-name>
+ <display-name>JSP Portlet</display-name>
+ <portlet-class>org.jboss.portal.portlet.samples.jsp.JSPPortlet</portlet-class>
+ <supports>
+ <mime-type>text/html</mime-type>
+ <portlet-mode>VIEW</portlet-mode>
+ </supports>
+ <portlet-info>
+ <title>Greetings!</title>
+ <keywords>sample,test</keywords>
+ </portlet-info>
+ </portlet>
+</portlet-app>
Added: modules/portlet/trunk/samples/src/main/artifacts/jsp-portlet-war/WEB-INF/web.xml
===================================================================
--- modules/portlet/trunk/samples/src/main/artifacts/jsp-portlet-war/WEB-INF/web.xml (rev 0)
+++ modules/portlet/trunk/samples/src/main/artifacts/jsp-portlet-war/WEB-INF/web.xml 2008-03-02 23:21:50 UTC (rev 10176)
@@ -0,0 +1,27 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ ~ JBoss, a division of Red Hat ~
+ ~ Copyright 2008, Red Hat Middleware, LLC, 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. ~
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~-->
+<!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/>
+
Added: modules/portlet/trunk/samples/src/main/artifacts/jsp-portlet-war/images/accessorize.gif
===================================================================
(Binary files differ)
Property changes on: modules/portlet/trunk/samples/src/main/artifacts/jsp-portlet-war/images/accessorize.gif
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Added: modules/portlet/trunk/samples/src/main/artifacts/jsp-portlet-war/images/dodemo.gif
===================================================================
(Binary files differ)
Property changes on: modules/portlet/trunk/samples/src/main/artifacts/jsp-portlet-war/images/dodemo.gif
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Added: modules/portlet/trunk/samples/src/main/artifacts/jsp-portlet-war/images/getcode.gif
===================================================================
(Binary files differ)
Property changes on: modules/portlet/trunk/samples/src/main/artifacts/jsp-portlet-war/images/getcode.gif
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Added: modules/portlet/trunk/samples/src/main/java/org/jboss/portal/portlet/samples/jsp/JSPPortlet.java
===================================================================
--- modules/portlet/trunk/samples/src/main/java/org/jboss/portal/portlet/samples/jsp/JSPPortlet.java (rev 0)
+++ modules/portlet/trunk/samples/src/main/java/org/jboss/portal/portlet/samples/jsp/JSPPortlet.java 2008-03-02 23:21:50 UTC (rev 10176)
@@ -0,0 +1,45 @@
+/******************************************************************************
+ * JBoss, a division of Red Hat *
+ * Copyright 2008, Red Hat Middleware, LLC, 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.portal.portlet.samples.jsp;
+
+import javax.portlet.PortletException;
+import javax.portlet.RenderResponse;
+import javax.portlet.RenderRequest;
+import javax.portlet.UnavailableException;
+import javax.portlet.GenericPortlet;
+import java.io.IOException;
+
+/**
+ * @author <a href="mailto:roy@jboss.org">Roy Russo</a>
+ */
+public class JSPPortlet extends GenericPortlet
+{
+ private static final String JSP_PATH = "/WEB-INF/jsp";
+
+ protected void doView(RenderRequest rRequest, RenderResponse rResponse) throws PortletException, IOException, UnavailableException
+ {
+ rResponse.setContentType("text/html");
+ javax.portlet.PortletRequestDispatcher pRD = this.getPortletContext().getRequestDispatcher(JSP_PATH + "/view.jsp");
+ pRD.include(rRequest, rResponse);
+ }
+}
\ No newline at end of file
16 years, 3 months
JBoss Portal SVN: r10175 - modules/portlet/trunk/samples/src/assemble.
by portal-commits@lists.jboss.org
Author: julien(a)jboss.com
Date: 2008-03-02 17:25:32 -0500 (Sun, 02 Mar 2008)
New Revision: 10175
Added:
modules/portlet/trunk/samples/src/assemble/samples-basic-portlet.xml
Log:
missing file
Added: modules/portlet/trunk/samples/src/assemble/samples-basic-portlet.xml
===================================================================
--- modules/portlet/trunk/samples/src/assemble/samples-basic-portlet.xml (rev 0)
+++ modules/portlet/trunk/samples/src/assemble/samples-basic-portlet.xml 2008-03-02 22:25:32 UTC (rev 10175)
@@ -0,0 +1,22 @@
+<assembly>
+ <id>samples-basic-portlet</id>
+ <formats>
+ <format>war</format>
+ </formats>
+ <includeBaseDirectory>false</includeBaseDirectory>
+
+ <fileSets>
+ <fileSet>
+ <directory>src/main/artifacts/basic-portlet-war</directory>
+ <outputDirectory></outputDirectory>
+ </fileSet>
+ <fileSet>
+ <directory>target/classes</directory>
+ <outputDirectory>WEB-INF/classes</outputDirectory>
+ <includes>
+ <include>org/jboss/portal/portlet/samples/basic/**</include>
+ </includes>
+ </fileSet>
+ </fileSets>
+
+</assembly>
\ No newline at end of file
16 years, 3 months
JBoss Portal SVN: r10174 - modules/portlet/trunk/samples/src/main/java/org/jboss/portal/portlet/samples/shoppingcart.
by portal-commits@lists.jboss.org
Author: julien(a)jboss.com
Date: 2008-03-02 17:24:18 -0500 (Sun, 02 Mar 2008)
New Revision: 10174
Added:
modules/portlet/trunk/samples/src/main/java/org/jboss/portal/portlet/samples/shoppingcart/CartEvent.java
modules/portlet/trunk/samples/src/main/java/org/jboss/portal/portlet/samples/shoppingcart/CartPortlet.java
modules/portlet/trunk/samples/src/main/java/org/jboss/portal/portlet/samples/shoppingcart/Catalog.java
modules/portlet/trunk/samples/src/main/java/org/jboss/portal/portlet/samples/shoppingcart/CatalogItem.java
modules/portlet/trunk/samples/src/main/java/org/jboss/portal/portlet/samples/shoppingcart/CatalogPortlet.java
Log:
adding shopping cart portelts
Added: modules/portlet/trunk/samples/src/main/java/org/jboss/portal/portlet/samples/shoppingcart/CartEvent.java
===================================================================
--- modules/portlet/trunk/samples/src/main/java/org/jboss/portal/portlet/samples/shoppingcart/CartEvent.java (rev 0)
+++ modules/portlet/trunk/samples/src/main/java/org/jboss/portal/portlet/samples/shoppingcart/CartEvent.java 2008-03-02 22:24:18 UTC (rev 10174)
@@ -0,0 +1,50 @@
+/******************************************************************************
+ * JBoss, a division of Red Hat *
+ * Copyright 2008, Red Hat Middleware, LLC, 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.portal.portlet.samples.shoppingcart;
+
+import javax.xml.bind.annotation.XmlRootElement;
+import javax.xml.namespace.QName;
+import java.io.Serializable;
+
+/**
+ * @author <a href="mailto:chris.laprun@jboss.com">Chris Laprun</a>
+ * @version $Revision: 9912 $
+ */
+@XmlRootElement
+public class CartEvent implements Serializable
+{
+ private String id;
+
+ public static final QName QNAME = new QName("urn:jboss:portal:samples:event", "CartEvent");
+
+ public CartEvent(String id)
+ {
+ this.id = id;
+ }
+
+ public String getId()
+ {
+ return id;
+ }
+}
Added: modules/portlet/trunk/samples/src/main/java/org/jboss/portal/portlet/samples/shoppingcart/CartPortlet.java
===================================================================
--- modules/portlet/trunk/samples/src/main/java/org/jboss/portal/portlet/samples/shoppingcart/CartPortlet.java (rev 0)
+++ modules/portlet/trunk/samples/src/main/java/org/jboss/portal/portlet/samples/shoppingcart/CartPortlet.java 2008-03-02 22:24:18 UTC (rev 10174)
@@ -0,0 +1,83 @@
+/******************************************************************************
+ * JBoss, a division of Red Hat *
+ * Copyright 2008, Red Hat Middleware, LLC, 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.portal.portlet.samples.shoppingcart;
+
+import javax.portlet.Event;
+import javax.portlet.EventRequest;
+import javax.portlet.EventResponse;
+import javax.portlet.GenericPortlet;
+import javax.portlet.PortletException;
+import javax.portlet.RenderRequest;
+import javax.portlet.RenderResponse;
+import java.io.IOException;
+import java.io.Writer;
+import java.util.ArrayList;
+import java.util.List;
+
+/**
+ * @author <a href="mailto:chris.laprun@jboss.com">Chris Laprun</a>
+ * @version $Revision: 9932 $
+ */
+public class CartPortlet extends GenericPortlet
+{
+ List<CatalogItem> items = new ArrayList<CatalogItem>(7);
+
+ @Override
+ protected void doView(RenderRequest renderRequest, RenderResponse renderResponse) throws PortletException, IOException
+ {
+ renderResponse.setContentType("text/html");
+ Writer writer = renderResponse.getWriter();
+
+
+ if (!items.isEmpty())
+ {
+ writer.append("<table width='95%' id=\"cart-table\"><thead><tr align='left'><th width='66%'>Description</th><th align='right'>Price</th></tr></thead><tbody>");
+ int total = 0;
+ for (CatalogItem item : items)
+ {
+ int price = item.getPrice();
+ total += price;
+ writer.append("<tr><td>").append(item.getDescription()).append("</td><td align='right'>$").append("" + price)
+ .append("</td></tr>");
+ }
+ writer.append("<tr><td><b>Total:</b></td><td align='right' style='border-top: 2px solid #000;'>")
+ .append("$" + total).append("</td></tr></tbody></table>");
+ }
+ else
+ {
+ writer.append("Cart is empty.");
+ }
+ }
+
+ @Override
+ public void processEvent(EventRequest eventRequest, EventResponse eventResponse) throws PortletException, IOException
+ {
+ Event event = eventRequest.getEvent();
+ if (event.getName().equals("CartEvent"))
+ {
+ CartEvent cartEvent = (CartEvent)event.getValue();
+ items.add(Catalog.get(cartEvent.getId()));
+ }
+ }
+}
Added: modules/portlet/trunk/samples/src/main/java/org/jboss/portal/portlet/samples/shoppingcart/Catalog.java
===================================================================
--- modules/portlet/trunk/samples/src/main/java/org/jboss/portal/portlet/samples/shoppingcart/Catalog.java (rev 0)
+++ modules/portlet/trunk/samples/src/main/java/org/jboss/portal/portlet/samples/shoppingcart/Catalog.java 2008-03-02 22:24:18 UTC (rev 10174)
@@ -0,0 +1,63 @@
+/******************************************************************************
+ * JBoss, a division of Red Hat *
+ * Copyright 2008, Red Hat Middleware, LLC, 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.portal.portlet.samples.shoppingcart;
+
+import java.util.Collection;
+import java.util.HashMap;
+import java.util.Map;
+
+/**
+ * @author <a href="mailto:chris.laprun@jboss.com">Chris Laprun</a>
+ * @version $Revision: 9912 $
+ */
+public class Catalog
+{
+ private static Map<String, CatalogItem> items;
+
+ static
+ {
+ items = new HashMap<String, CatalogItem>(7);
+ items.put("1", new CatalogItem("1", 800, "Bike"));
+ items.put("2", new CatalogItem("2", 450, "Snowboard"));
+ items.put("3", new CatalogItem("3", 225, "Tent"));
+ items.put("4", new CatalogItem("4", 75, "Backpack"));
+ items.put("5", new CatalogItem("5", 119, "Skateboard"));
+ items.put("6", new CatalogItem("6", 333, "Surfboard"));
+ items.put("7", new CatalogItem("7", 90, "Sneakers"));
+ }
+
+ private Catalog()
+ {
+ }
+
+ public static CatalogItem get(String id)
+ {
+ return items.get(id);
+ }
+
+ public static Collection<CatalogItem> getAll()
+ {
+ return items.values();
+ }
+}
Added: modules/portlet/trunk/samples/src/main/java/org/jboss/portal/portlet/samples/shoppingcart/CatalogItem.java
===================================================================
--- modules/portlet/trunk/samples/src/main/java/org/jboss/portal/portlet/samples/shoppingcart/CatalogItem.java (rev 0)
+++ modules/portlet/trunk/samples/src/main/java/org/jboss/portal/portlet/samples/shoppingcart/CatalogItem.java 2008-03-02 22:24:18 UTC (rev 10174)
@@ -0,0 +1,57 @@
+/******************************************************************************
+ * JBoss, a division of Red Hat *
+ * Copyright 2008, Red Hat Middleware, LLC, 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.portal.portlet.samples.shoppingcart;
+
+/**
+ * @author <a href="mailto:chris.laprun@jboss.com">Chris Laprun</a>
+ * @version $Revision: 9912 $
+ */
+public class CatalogItem
+{
+ private String id;
+ private int price;
+ private String description;
+
+ public CatalogItem(String id, int price, String description)
+ {
+ this.id = id;
+ this.price = price;
+ this.description = description;
+ }
+
+ public String getId()
+ {
+ return id;
+ }
+
+ public int getPrice()
+ {
+ return price;
+ }
+
+ public String getDescription()
+ {
+ return description;
+ }
+}
Added: modules/portlet/trunk/samples/src/main/java/org/jboss/portal/portlet/samples/shoppingcart/CatalogPortlet.java
===================================================================
--- modules/portlet/trunk/samples/src/main/java/org/jboss/portal/portlet/samples/shoppingcart/CatalogPortlet.java (rev 0)
+++ modules/portlet/trunk/samples/src/main/java/org/jboss/portal/portlet/samples/shoppingcart/CatalogPortlet.java 2008-03-02 22:24:18 UTC (rev 10174)
@@ -0,0 +1,71 @@
+/******************************************************************************
+ * JBoss, a division of Red Hat *
+ * Copyright 2008, Red Hat Middleware, LLC, 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.portal.portlet.samples.shoppingcart;
+
+import javax.portlet.ActionRequest;
+import javax.portlet.ActionResponse;
+import javax.portlet.GenericPortlet;
+import javax.portlet.PortletException;
+import javax.portlet.PortletURL;
+import javax.portlet.RenderRequest;
+import javax.portlet.RenderResponse;
+import java.io.IOException;
+import java.io.Writer;
+import java.util.Collection;
+
+/**
+ * @author <a href="mailto:chris.laprun@jboss.com">Chris Laprun</a>
+ * @version $Revision: 9932 $
+ */
+public class CatalogPortlet extends GenericPortlet
+{
+ @Override
+ protected void doView(RenderRequest renderRequest, RenderResponse renderResponse) throws PortletException, IOException
+ {
+ renderResponse.setContentType("text/html");
+ Writer writer = renderResponse.getWriter();
+
+ writer.append("<table width='95%'><thead><tr align='left'><th width='50%'>Description</th><th width='25%'>Price</th><th>Actions</th></tr></thead><tbody>");
+
+ PortletURL addURL = renderResponse.createActionURL();
+ addURL.setParameter("op", "add");
+
+ Collection<CatalogItem> items = Catalog.getAll();
+ for (CatalogItem item : items)
+ {
+ addURL.setParameter("id", item.getId());
+ writer.append("<tr><td>").append(item.getDescription()).append("</td><td>$").append("" + item.getPrice())
+ .append("</td><td><a href='").append(addURL.toString()).append("' onclick=\"new Effect.Highlight(document.getElementById('cart-table'))\">Add to cart</a></td></tr>");
+ }
+
+ writer.append("</tbody></table>");
+ }
+
+ @Override
+ public void processAction(ActionRequest actionRequest, ActionResponse actionResponse) throws PortletException, IOException
+ {
+ String value = actionRequest.getParameter("id");
+ actionResponse.setEvent(CartEvent.QNAME, new CartEvent(value));
+ }
+}
16 years, 3 months
JBoss Portal SVN: r10173 - modules/portlet/trunk/samples/src/main/artifacts/shoppingcart-portlet-war/WEB-INF.
by portal-commits@lists.jboss.org
Author: julien(a)jboss.com
Date: 2008-03-02 17:19:59 -0500 (Sun, 02 Mar 2008)
New Revision: 10173
Added:
modules/portlet/trunk/samples/src/main/artifacts/shoppingcart-portlet-war/WEB-INF/web.xml
Log:
adding stuff
Added: modules/portlet/trunk/samples/src/main/artifacts/shoppingcart-portlet-war/WEB-INF/web.xml
===================================================================
--- modules/portlet/trunk/samples/src/main/artifacts/shoppingcart-portlet-war/WEB-INF/web.xml (rev 0)
+++ modules/portlet/trunk/samples/src/main/artifacts/shoppingcart-portlet-war/WEB-INF/web.xml 2008-03-02 22:19:59 UTC (rev 10173)
@@ -0,0 +1,27 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ ~ JBoss, a division of Red Hat ~
+ ~ Copyright 2008, Red Hat Middleware, LLC, 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. ~
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~-->
+<!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/>
+
16 years, 3 months
JBoss Portal SVN: r10172 - in modules/portlet/trunk/samples/src/main/java/org/jboss/portal/portlet/samples: basic and 2 other directories.
by portal-commits@lists.jboss.org
Author: julien(a)jboss.com
Date: 2008-03-02 17:18:57 -0500 (Sun, 02 Mar 2008)
New Revision: 10172
Added:
modules/portlet/trunk/samples/src/main/java/org/jboss/portal/portlet/samples/basic/
modules/portlet/trunk/samples/src/main/java/org/jboss/portal/portlet/samples/basic/ExceptionPortlet.java
modules/portlet/trunk/samples/src/main/java/org/jboss/portal/portlet/samples/basic/FailDuringInitPortlet.java
modules/portlet/trunk/samples/src/main/java/org/jboss/portal/portlet/samples/basic/HeaderPortlet.java
modules/portlet/trunk/samples/src/main/java/org/jboss/portal/portlet/samples/basic/NullFilter.java
modules/portlet/trunk/samples/src/main/java/org/jboss/portal/portlet/samples/google/GoogleClippingPortlet.java
modules/portlet/trunk/samples/src/main/java/org/jboss/portal/portlet/samples/remotecontroller/
modules/portlet/trunk/samples/src/main/java/org/jboss/portal/portlet/samples/remotecontroller/RemoteControllerPortlet.java
modules/portlet/trunk/samples/src/main/java/org/jboss/portal/portlet/samples/shoppingcart/
Log:
adding stuff
Added: modules/portlet/trunk/samples/src/main/java/org/jboss/portal/portlet/samples/basic/ExceptionPortlet.java
===================================================================
--- modules/portlet/trunk/samples/src/main/java/org/jboss/portal/portlet/samples/basic/ExceptionPortlet.java (rev 0)
+++ modules/portlet/trunk/samples/src/main/java/org/jboss/portal/portlet/samples/basic/ExceptionPortlet.java 2008-03-02 22:18:57 UTC (rev 10172)
@@ -0,0 +1,113 @@
+/******************************************************************************
+ * JBoss, a division of Red Hat *
+ * Copyright 2008, Red Hat Middleware, LLC, 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.portal.portlet.samples.basic;
+
+import javax.portlet.GenericPortlet;
+import javax.portlet.RenderRequest;
+import javax.portlet.RenderResponse;
+import javax.portlet.PortletException;
+import javax.portlet.PortletURL;
+import javax.portlet.PortletRequest;
+import javax.portlet.ActionRequest;
+import javax.portlet.PortletSecurityException;
+import javax.portlet.ActionResponse;
+import java.io.IOException;
+import java.io.PrintWriter;
+
+/**
+ * @author <a href="mailto:julien@jboss.org">Julien Viet</a>
+ * @version $Revision: 630 $
+ */
+public class ExceptionPortlet extends GenericPortlet
+{
+
+ public void processAction(ActionRequest req, ActionResponse resp) throws PortletException, PortletSecurityException, IOException
+ {
+ throwException(req);
+ }
+
+ protected void doView(RenderRequest req, RenderResponse resp) throws PortletException, PortletSecurityException, IOException
+ {
+ throwException(req);
+
+ //
+ resp.setContentType("text/html");
+ PrintWriter writer = resp.getWriter();
+ PortletURL renderURL = resp.createRenderURL();
+ PortletURL actionURL = resp.createActionURL();
+
+ //
+ writer.write("<p>");
+ writer.write("<div class=\"portlet-section-header\">Throw :</div>");
+ writer.write("<div class=\"portlet-section-body\">");
+ renderURL.setParameter("op", "portletexception");
+ writer.write("<div><a href=\"" + renderURL + "\">render PortletException</a></div>");
+ renderURL.setParameter("op", "portletsecurityexception");
+ writer.write("<div><a href=\"" + renderURL + "\">render PortletSecurityException</a></div>");
+ renderURL.setParameter("op", "ioexception");
+ writer.write("<div><a href=\"" + renderURL + "\">render IOException</a></div>");
+ renderURL.setParameter("op", "runtimeexception");
+ writer.write("<div><a href=\"" + renderURL + "\">render RuntimeException</a></div>");
+ actionURL.setParameter("op", "error");
+ writer.write("<div><a href=\"" + renderURL + "\">render Error</a></div>");
+ actionURL.setParameter("op", "portletexception");
+ writer.write("<div><a href=\"" + actionURL + "\">action PortletException</a></div>");
+ actionURL.setParameter("op", "portletsecurityexception");
+ writer.write("<div><a href=\"" + actionURL + "\">action PortletSecurityException</a></div>");
+ actionURL.setParameter("op", "ioexception");
+ writer.write("<div><a href=\"" + actionURL + "\">action IOException</a></div>");
+ actionURL.setParameter("op", "runtimeexception");
+ writer.write("<div><a href=\"" + actionURL + "\">action RuntimeException</a></div>");
+ actionURL.setParameter("op", "error");
+ writer.write("<div><a href=\"" + actionURL + "\">action Error</a></div>");
+ writer.write("</div>");
+ writer.write("</p>");
+ }
+
+ private void throwException(PortletRequest req) throws PortletException, IOException
+ {
+ String op = req.getParameter("op");
+
+ // Throw any required exception
+ if ("portletexception".equals(op))
+ {
+ throw new PortletException();
+ }
+ if ("portletsecurityexception".equals(op))
+ {
+ throw new PortletSecurityException("");
+ }
+ if ("ioexception".equals(op))
+ {
+ throw new IOException();
+ }
+ if ("runtimeexception".equals(op))
+ {
+ throw new RuntimeException();
+ }
+ if ("error".equals(op))
+ {
+ throw new Error();
+ }
+ }
+}
Added: modules/portlet/trunk/samples/src/main/java/org/jboss/portal/portlet/samples/basic/FailDuringInitPortlet.java
===================================================================
--- modules/portlet/trunk/samples/src/main/java/org/jboss/portal/portlet/samples/basic/FailDuringInitPortlet.java (rev 0)
+++ modules/portlet/trunk/samples/src/main/java/org/jboss/portal/portlet/samples/basic/FailDuringInitPortlet.java 2008-03-02 22:18:57 UTC (rev 10172)
@@ -0,0 +1,65 @@
+/******************************************************************************
+ * JBoss, a division of Red Hat *
+ * Copyright 2008, Red Hat Middleware, LLC, 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.portal.portlet.samples.basic;
+
+import javax.portlet.GenericPortlet;
+import javax.portlet.PortletException;
+import javax.portlet.RenderRequest;
+import javax.portlet.RenderResponse;
+import java.io.IOException;
+import java.io.PrintWriter;
+
+/**
+ * A portlet that will fail only one time during startup (so it is possible to restart it).
+ *
+ * @author <a href="mailto:julien@jboss.org">Julien Viet</a>
+ * @version $Revision: 630 $
+ */
+public class FailDuringInitPortlet extends GenericPortlet
+{
+
+ private static int initCount = 0;
+
+ public void init() throws PortletException
+ {
+ if (initCount == 0)
+ {
+ initCount = 1;
+
+ //
+ throw new PortletException();
+ }
+ else
+ {
+ // Nothing
+ }
+ }
+
+ protected void doView(RenderRequest renderRequest, RenderResponse renderResponse) throws PortletException, IOException
+ {
+ renderResponse.setContentType("text/html");
+ PrintWriter writer = renderResponse.getWriter();
+ writer.print("A portlet that may fail during init");
+ writer.close();
+ }
+}
Added: modules/portlet/trunk/samples/src/main/java/org/jboss/portal/portlet/samples/basic/HeaderPortlet.java
===================================================================
--- modules/portlet/trunk/samples/src/main/java/org/jboss/portal/portlet/samples/basic/HeaderPortlet.java (rev 0)
+++ modules/portlet/trunk/samples/src/main/java/org/jboss/portal/portlet/samples/basic/HeaderPortlet.java 2008-03-02 22:18:57 UTC (rev 10172)
@@ -0,0 +1,181 @@
+/******************************************************************************
+ * JBoss, a division of Red Hat *
+ * Copyright 2008, Red Hat Middleware, LLC, 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.portal.portlet.samples.basic;
+
+import javax.portlet.GenericPortlet;
+import javax.portlet.RenderRequest;
+import javax.portlet.RenderResponse;
+import javax.portlet.PortletException;
+import javax.portlet.ResourceRequest;
+import javax.portlet.ResourceResponse;
+import javax.portlet.ResourceURL;
+import javax.portlet.ActionRequest;
+import javax.portlet.ActionResponse;
+import javax.portlet.PortletSecurityException;
+import javax.portlet.PortletURL;
+import javax.portlet.PortletMode;
+import java.io.IOException;
+import java.io.PrintWriter;
+
+/**
+ * @author <a href="mailto:julien@jboss.org">Julien Viet</a>
+ * @version $Revision: 630 $
+ */
+public class HeaderPortlet extends GenericPortlet
+{
+ public final static int TITANIUM = 0;
+ public final static int PLATINUM = 1;
+ public final static int GOLD = 2;
+ public final static int SILVER = 3;
+ public final static int TIN = 4;
+
+ public void processAction(ActionRequest req, ActionResponse resp) throws PortletException, PortletSecurityException, IOException
+ {
+
+ String repeatText = req.getParameter("repeat");
+ // set zip as render parameter
+ if (repeatText != null){
+ resp.setRenderParameter("repeat", repeatText);
+ }
+ // request view
+ resp.setPortletMode(PortletMode.VIEW);
+
+ }
+ public void render(RenderRequest req, RenderResponse resp) throws PortletException, IOException
+ {
+ ResourceURL resourceURL = resp.createResourceURL();
+ PortletURL actionURL = resp.createActionURL();
+ //
+// Element elt = resp.createElement("script");
+// elt.setAttribute("type", "text/javascript");
+// elt.setAttribute("src", resourceURL.toString());
+// elt.appendChild(elt.getOwnerDocument().createTextNode(""));
+// resp.addProperty("script", elt);
+
+ //
+
+ resp.setContentType("text/html");
+ PrintWriter writer = resp.getWriter();
+ writer.print("" +
+ "<script type=\"text/javascript\">" +
+ "" +
+ // "function init(){\n" +
+ //" Event.observe('repeat', 'keyup', repeat(), false);\n" +
+ // "}" +
+ "" +
+ "function browse(id) {" +
+ "var url = id;\n" +
+ "var pars = 'foo=bar';\n" +
+ "var target = 'output-div';\n" +
+ "var myAjax = new Ajax.Updater(target, url, {method: 'GET', parameters: pars});" +
+ "}" +
+
+ "</script>");
+
+ writer.print("" +
+ "<div class='full-width' style='padding:5px'>" +
+ "<h4>Partial Refresh Repeater Demo</h4>");
+ writer.print("" +
+ " <div class='half-width float-left'>" +
+ " <form method='post' id=\"testrepeatform\" name=\"testrepeatform\" action=\"" + actionURL + "\" onsubmit=\"new Ajax.Updater('repeat-div', '" + resourceURL + "', {asynchronous:true, parameters:Form.serialize(this)}); return false;\">\n" +
+ " <font class='portlet-font'>Repeat Demo:</font><br/>\n" +
+ " <input class='portlet-form-input-field' type='text' value='' size='12' name=\"repeat\" id=\"repeat\" onkeyup=\"this.form.submit2.click();new Effect.Highlight(document.getElementById('repeat-div'));\"/>\n" +
+ " <input class='portlet-form-input-field hidden' type='submit' name='submit2' value='submit' style=\"display:hidden;\">\n" +
+ " </form>\n" +
+ "</div>" +
+ "");
+ writer.print("<div id=\"repeat-container\"><div id=\"repeat-div\" class='half-width float-left' style='height:50px'></div></div>");
+// "<input type=\"text\" id=\"hidden-input\" value=\"" + resourceURL.toString() + "\" />" +
+// "<a href='javascript:" + resp.getNamespace() + "_handle()'>Click me to trigger script</a>" +
+ writer.print("<br class='clear'/><br class='clear'/><hr/>" +
+ "<h4>Partial Refresh Product Catalog</h4>" +
+ "<div class='full-width'>" +
+ "");
+ writer.print("<div class='float-left third-width'>");
+ resourceURL.setParameter("prodId","1");
+ writer.print("<a href=\"javascript: browse(\'" + resourceURL + "\');\">Product 1</a><br/>");
+
+ resourceURL.setParameter("prodId","2");
+ writer.print("<a href=\"javascript: browse(\'" + resourceURL + "\');\">Product 2</a><br/>");
+
+ resourceURL.setParameter("prodId","3");
+ writer.print("<a href=\"javascript: browse(\'" + resourceURL + "\');\">Product 3</a><br/>");
+
+ writer.print("<br class='clear'/></div>");
+ writer.print("<div class='float-left two-third-width'>" +
+ "<h4 class='zero'>Product Details</h4>" +
+ "<div id=\"output-div\"></div>" +
+ "");
+ writer.print("<br class='clear'/></div>");
+ writer.print("<br class='clear'/></div>");
+ writer.print("<br class='clear'/></div>");
+
+
+
+ // writer.print("</div>");
+ }
+
+ public void serveResource(ResourceRequest req, ResourceResponse resp) throws PortletException, IOException
+ {
+ String repeatText = req.getParameter("repeat");
+ String prodId = req.getParameter("prodId");
+
+ String namespace =resp.getNamespace();
+ //resp.setContentType("application/json");
+ resp.setContentType("text/html");
+ PrintWriter writer = resp.getWriter();
+ if (repeatText != null){
+ writer.print("<div id=\"repeat-text\">"+ req.getPrivateParameterMap().get("repeat")[0] +"</div>");
+ }
+ if (prodId != null){
+ if (prodId.equals("1")){
+ writer.print("<div id=\"product-text\">Product ID: "+ prodId +"" +
+ "<br/>" +
+ " B BY BURTON ALPHA<br/>" +
+ "Sale Price: $314.96 " +
+ "</div>");
+ }
+ if (prodId.equals("2")){
+ writer.print("<div id=\"product-text\">Product ID: "+ prodId +"" +
+ "<br/>" +
+ "FORUM DESTROYER LTD<br/>" +
+ "$319.99 " +
+ "</div>");
+ }
+ if (prodId.equals("3")){
+ writer.print("<div id=\"product-text\">Product ID: "+ prodId +"" +
+ "<br/>" +
+ "\n" +
+ "SANTA CRUZ ALLSTAR<br/>" +
+ "$256.00 " +
+ "</div>");
+ }
+
+ }
+
+
+
+
+ writer.close();
+ }
+}
Added: modules/portlet/trunk/samples/src/main/java/org/jboss/portal/portlet/samples/basic/NullFilter.java
===================================================================
--- modules/portlet/trunk/samples/src/main/java/org/jboss/portal/portlet/samples/basic/NullFilter.java (rev 0)
+++ modules/portlet/trunk/samples/src/main/java/org/jboss/portal/portlet/samples/basic/NullFilter.java 2008-03-02 22:18:57 UTC (rev 10172)
@@ -0,0 +1,75 @@
+/******************************************************************************
+ * JBoss, a division of Red Hat *
+ * Copyright 2008, Red Hat Middleware, LLC, 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.portal.portlet.samples.basic;
+
+import javax.portlet.filter.RenderFilter;
+import javax.portlet.filter.ActionFilter;
+import javax.portlet.filter.EventFilter;
+import javax.portlet.filter.ResourceFilter;
+import javax.portlet.filter.FilterChain;
+import javax.portlet.filter.FilterConfig;
+import javax.portlet.RenderRequest;
+import javax.portlet.RenderResponse;
+import javax.portlet.PortletException;
+import javax.portlet.ActionRequest;
+import javax.portlet.ActionResponse;
+import javax.portlet.EventRequest;
+import javax.portlet.EventResponse;
+import javax.portlet.ResourceRequest;
+import javax.portlet.ResourceResponse;
+import java.io.IOException;
+
+/**
+ * @author <a href="mailto:julien@jboss.org">Julien Viet</a>
+ * @version $Revision: 630 $
+ */
+public class NullFilter implements RenderFilter, ActionFilter, EventFilter, ResourceFilter
+{
+ public void init(FilterConfig config) throws PortletException
+ {
+ }
+
+ public void doFilter(RenderRequest req, RenderResponse resp, FilterChain chain) throws IOException, PortletException
+ {
+ chain.doFilter(req, resp);
+ }
+
+ public void doFilter(ActionRequest req, ActionResponse resp, FilterChain chain) throws IOException, PortletException
+ {
+ chain.doFilter(req, resp);
+ }
+
+ public void doFilter(EventRequest req, EventResponse resp, FilterChain chain) throws IOException, PortletException
+ {
+ chain.doFilter(req, resp);
+ }
+
+ public void doFilter(ResourceRequest req, ResourceResponse resp, FilterChain chain) throws IOException, PortletException
+ {
+ chain.doFilter(req, resp);
+ }
+
+ public void destroy()
+ {
+ }
+}
Added: modules/portlet/trunk/samples/src/main/java/org/jboss/portal/portlet/samples/google/GoogleClippingPortlet.java
===================================================================
--- modules/portlet/trunk/samples/src/main/java/org/jboss/portal/portlet/samples/google/GoogleClippingPortlet.java (rev 0)
+++ modules/portlet/trunk/samples/src/main/java/org/jboss/portal/portlet/samples/google/GoogleClippingPortlet.java 2008-03-02 22:18:57 UTC (rev 10172)
@@ -0,0 +1,178 @@
+/******************************************************************************
+ * JBoss, a division of Red Hat *
+ * Copyright 2008, Red Hat Middleware, LLC, 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.portal.portlet.samples.google;
+
+import javax.portlet.ActionRequest;
+import javax.portlet.ActionResponse;
+import javax.portlet.GenericPortlet;
+import javax.portlet.PortletException;
+import javax.portlet.PortletMode;
+import javax.portlet.PortletPreferences;
+import javax.portlet.RenderRequest;
+import javax.portlet.RenderResponse;
+import java.io.BufferedInputStream;
+import java.io.ByteArrayOutputStream;
+import java.io.IOException;
+import java.io.InputStream;
+import java.io.PrintWriter;
+import java.net.URL;
+import java.net.URLConnection;
+
+/**
+ * A simple portlet using Google's search services to extract interesting information (weather, map, ...) from first
+ * result.
+ *
+ * @author <a href="mailto:chris.laprun@jboss.com">Chris Laprun</a>
+ * @version $Revision: 9912 $
+ */
+public class GoogleClippingPortlet extends GenericPortlet
+{
+ protected static final String A = "<a";
+ private static final String A_TARGET_BLANK = "<a target='_blank'";
+ private static final String ZIP = "zipcode";
+ private static final String SAN_FRAN = "94102";
+ private static final String GOOGLE = "http://www.google.com/search?q=";
+
+ @Override
+ protected void doView(RenderRequest renderRequest, RenderResponse renderResponse) throws PortletException, IOException
+ {
+ String zip = getZipCode(renderRequest);
+
+ String query = getQueryString(zip);
+
+ URL url = new URL(query);
+
+ URLConnection connection = url.openConnection();
+ connection.setRequestProperty("User-Agent", "Mozilla/5.0");
+
+ BufferedInputStream in = new BufferedInputStream(connection.getInputStream());
+ String html = new String(getBytes(in, 16384), "UTF-8");
+ in.close();
+
+ String beg = "<div class=e>";
+ String end = "</table>";
+ int begIndex = html.indexOf(beg);
+ if (begIndex != -1)
+ {
+ // extract table containing specific first result
+ int endIndex = html.indexOf(end, begIndex);
+ html = html.substring(begIndex + beg.length(), endIndex + end.length());
+
+ html = postProcessHTML(html);
+
+ renderResponse.setContentType("text/html");
+ PrintWriter printWriter = renderResponse.getWriter();
+ printWriter.print(html);
+ }
+ }
+
+ protected String getZipCode(RenderRequest renderRequest)
+ {
+ String zip = renderRequest.getParameter(ZIP);
+ if (zip == null)
+ {
+ zip = renderRequest.getPreferences().getValue(ZIP, SAN_FRAN);
+ }
+ return zip;
+ }
+
+ @Override
+ protected void doEdit(RenderRequest renderRequest, RenderResponse renderResponse) throws PortletException, IOException
+ {
+ renderResponse.setContentType("text/html");
+ renderResponse.getWriter().print(
+ "<div align='center'>\n" +
+ " <br/>\n" +
+ " <font class='portlet-font'>Change Location:</font>\n" +
+ "\n" +
+ " <form method='post' action='" + renderResponse.createActionURL() + "'\n" +
+ " <font class='portlet-font'>Zip Code:</font><br/>\n" +
+ " <input class='portlet-form-input-field' type='text' value='' size='12' name='" + ZIP + "'/>\n" +
+ " <br/>\n" +
+ " <input class='portlet-form-input-field' type='submit' name='submit' value='submit'>\n" +
+ " </form>\n" +
+ "</div>");
+ }
+
+ @Override
+ public void processAction(ActionRequest actionRequest, ActionResponse actionResponse) throws PortletException, IOException
+ {
+ String zip = actionRequest.getParameter(ZIP);
+
+ if (null != zip)
+ {
+ PortletPreferences prefs = actionRequest.getPreferences();
+ prefs.setValue(ZIP, zip);
+ prefs.store();
+ }
+
+ // set zip as render parameter
+ actionResponse.setRenderParameter(ZIP, zip);
+
+ // request view
+ actionResponse.setPortletMode(PortletMode.VIEW);
+ }
+
+ protected String postProcessHTML(String html)
+ {
+ // links should open in new windows
+ html = html.replaceAll(A, A_TARGET_BLANK);
+
+ // src attributes should be absolute
+ html = html.replaceAll("src=/", "src=http://google.com/");
+ html = html.replaceAll("src=\"/", "src=\"http://google.com/");
+
+ // forms should open in new windows and have an absolute action URL
+ html = html.replaceAll("action=\"/", "target='_blank' action=\"http://google.com/");
+
+ return html;
+ }
+
+ protected String getQueryString(String zip)
+ {
+ return GOOGLE + zip;
+ }
+
+ private byte[] getBytes(InputStream in, int bufferSize) throws IOException, IllegalArgumentException
+ {
+ ByteArrayOutputStream out = new ByteArrayOutputStream();
+
+ byte[] buffer = new byte[bufferSize];
+ while (true)
+ {
+ int i = in.read(buffer);
+ if (i == 0)
+ {
+ continue;
+ }
+ if (i == -1)
+ {
+ break;
+ }
+ out.write(buffer, 0, i);
+ }
+ return out.toByteArray();
+ }
+
+}
Added: modules/portlet/trunk/samples/src/main/java/org/jboss/portal/portlet/samples/remotecontroller/RemoteControllerPortlet.java
===================================================================
--- modules/portlet/trunk/samples/src/main/java/org/jboss/portal/portlet/samples/remotecontroller/RemoteControllerPortlet.java (rev 0)
+++ modules/portlet/trunk/samples/src/main/java/org/jboss/portal/portlet/samples/remotecontroller/RemoteControllerPortlet.java 2008-03-02 22:18:57 UTC (rev 10172)
@@ -0,0 +1,75 @@
+/*
+ * Copyright (c) 2008, Your Corporation. All Rights Reserved.
+ */
+
+package org.jboss.portal.portlet.samples.remotecontroller;
+
+import javax.portlet.GenericPortlet;
+import javax.portlet.PortletException;
+import javax.portlet.PortletURL;
+import javax.portlet.RenderRequest;
+import javax.portlet.RenderResponse;
+import javax.portlet.ResourceRequest;
+import javax.portlet.ResourceResponse;
+import javax.portlet.ResourceURL;
+import javax.portlet.WindowState;
+import java.io.IOException;
+import java.io.PrintWriter;
+
+/**
+ * @author <a href="mailto:chris.laprun@jboss.com">Chris Laprun</a>
+ * @version $Revision: 9979 $
+ */
+public class RemoteControllerPortlet extends GenericPortlet
+{
+ private static final String ZIPCODE = "zipcode";
+
+ @Override
+ protected void doView(RenderRequest renderRequest, RenderResponse renderResponse) throws PortletException, IOException
+ {
+ renderResponse.setContentType("text/html");
+ PrintWriter printWriter = renderResponse.getWriter();
+ String namespace = renderResponse.getNamespace();
+ printWriter.print("<script type='text/javascript'>function " + namespace
+ + "_openRemote(url){window.name='" + namespace + "_parent';window.open(url, '" + namespace
+ + "_remote', 'width=400,height=200,scrollable=yes')}</script>");
+ printWriter.print("<p><a href='#' onclick=\"" + namespace + "_openRemote('");
+ ResourceURL resource = renderResponse.createResourceURL();
+ printWriter.print(resource);
+ printWriter.print("')\">Open remote control!</a></p>");
+ }
+
+ @Override
+ public void serveResource(ResourceRequest resourceRequest, ResourceResponse resourceResponse) throws PortletException, IOException
+ {
+ resourceResponse.setContentType("text/html");
+ PrintWriter writer = resourceResponse.getWriter();
+ String namespace = resourceResponse.getNamespace();
+ writer.print("<html><head><script type='text/javascript'>function openLinkInParent(url){window.open(url,'"
+ + namespace + "_parent');}</script>\n<link rel=\"stylesheet\" href='/simple-portal/css/master.css' type=\"text/css\"/></head><body>");
+ PortletURL url = resourceResponse.createRenderURL();
+ url.setWindowState(WindowState.MINIMIZED);
+ writer.print("<div class=\"remote-container\"><ul><li><a href='#' onclick=\"" + createParentURL(url) + "\"><img\n" +
+ " src=\"/simple-portal/images/icon-minimize.gif\" alt=\"\"/> minimize parent portlet</a></li>");
+ url.setWindowState(WindowState.MAXIMIZED);
+ writer.print("<li><a href='#' onclick=\"" + createParentURL(url) + "\"><img\n" +
+ " src=\"/simple-portal/images/icon-maximize.gif\" alt=\"\"/> maximize parent portlet</a></li>");
+ url.setWindowState(WindowState.NORMAL);
+ writer.print("<li><a href='#' onclick=\"" + createParentURL(url) + "\"><img\n" +
+ " src=\"/simple-portal/images/icon-normal.gif\" alt=\"\"/> make parent portlet normal</a></li></ul>");
+ writer.print("<br/><ul><li><b>'zipcode'</b> public render parameter value: " + resourceRequest.getParameter(ZIPCODE) + "<br/>");
+ writer.print("Set value of <b>'zipcode'</b> public render parameter to:</li>");
+ url.setParameter(ZIPCODE, "80201");
+ writer.print("<li><a href='#' onclick=\"" + createParentURL(url) + "\">Denver, CO</a>");
+ url.setParameter(ZIPCODE, "94102");
+ writer.print("<li><a href='#' onclick=\"" + createParentURL(url) + "\">San Francisco, CA</a>");
+ url.setParameter(ZIPCODE, "20001");
+ writer.print("<li><a href='#' onclick=\"" + createParentURL(url) + "\">Washington, DC</a>");
+ writer.print("</ul></div></body></html>");
+ }
+
+ private String createParentURL(PortletURL url)
+ {
+ return "openLinkInParent('" + url + "')";
+ }
+}
16 years, 3 months
JBoss Portal SVN: r10171 - in modules/portlet/trunk/build/distrib: jboss-4.2 and 5 other directories.
by portal-commits@lists.jboss.org
Author: julien(a)jboss.com
Date: 2008-03-02 17:15:47 -0500 (Sun, 02 Mar 2008)
New Revision: 10171
Added:
modules/portlet/trunk/build/distrib/jboss-4.2/
modules/portlet/trunk/build/distrib/jboss-4.2/server/
modules/portlet/trunk/build/distrib/jboss-4.2/server/default/
modules/portlet/trunk/build/distrib/jboss-4.2/server/default/deploy/
modules/portlet/trunk/build/distrib/jboss-4.2/server/default/deploy/jboss-web.deployer/
modules/portlet/trunk/build/distrib/jboss-4.2/server/default/deploy/jboss-web.deployer/conf/
modules/portlet/trunk/build/distrib/jboss-4.2/server/default/deploy/jboss-web.deployer/conf/web.xml
Modified:
modules/portlet/trunk/build/distrib/distrib.xml
Log:
adding support for taglib in jboss42
Modified: modules/portlet/trunk/build/distrib/distrib.xml
===================================================================
--- modules/portlet/trunk/build/distrib/distrib.xml 2008-03-02 22:05:53 UTC (rev 10170)
+++ modules/portlet/trunk/build/distrib/distrib.xml 2008-03-02 22:15:47 UTC (rev 10171)
@@ -88,6 +88,9 @@
<copy todir="${pc.build.bin.as42}/server/default/deploy/simple-portal">
<fileset dir="${source.dir}/portal/target/portlet-portal-${maven.version}-simple-portal-jboss42.dir/simple-portal"/>
</copy>
+ <copy todir="${pc.build.bin.as42}" overwrite="true">
+ <fileset dir="jboss-4.2"/>
+ </copy>
<antcall target="__zip">
<param name="release.name" value="${demo.release.name.jboss42}"/>
</antcall>
Added: modules/portlet/trunk/build/distrib/jboss-4.2/server/default/deploy/jboss-web.deployer/conf/web.xml
===================================================================
--- modules/portlet/trunk/build/distrib/jboss-4.2/server/default/deploy/jboss-web.deployer/conf/web.xml (rev 0)
+++ modules/portlet/trunk/build/distrib/jboss-4.2/server/default/deploy/jboss-web.deployer/conf/web.xml 2008-03-02 22:15:47 UTC (rev 10171)
@@ -0,0 +1,1253 @@
+<?xml version="1.0" encoding="ISO-8859-1"?>
+<web-app 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 http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd"
+ version="2.4">
+
+ <!-- ======================== Introduction ============================== -->
+ <!-- This document defines default values for *all* web applications -->
+ <!-- loaded into this instance of Tomcat. As each application is -->
+ <!-- deployed, this file is processed, followed by the -->
+ <!-- "/WEB-INF/web.xml" deployment descriptor from your own -->
+ <!-- applications. -->
+ <!-- -->
+ <!-- WARNING: Do not configure application-specific resources here! -->
+ <!-- They should go in the "/WEB-INF/web.xml" file in your application. -->
+
+ <!-- =========== Common Context Params ================================== -->
+ <!-- JBossInjectionProvider provides resource injection for managed beans. -->
+ <!-- See JSF 1.2 spec section 5.4 for details. -->
+ <context-param>
+ <param-name>com.sun.faces.injectionProvider</param-name>
+ <param-value>org.jboss.web.jsf.integration.injection.JBossInjectionProvider</param-value>
+ </context-param>
+
+ <!-- ================== Common filter Configuration ==================== -->
+ <filter>
+ <filter-name>CommonHeadersFilter</filter-name>
+ <filter-class>org.jboss.web.tomcat.filters.ReplyHeaderFilter</filter-class>
+ <init-param>
+ <param-name>X-Powered-By</param-name>
+ <param-value>Servlet 2.4; JBoss-4.2.2.GA (build: SVNTag=JBoss_4_2_2_GA date=200802142215)/Tomcat-5.5</param-value>
+ </init-param>
+ </filter>
+
+ <filter-mapping>
+ <filter-name>CommonHeadersFilter</filter-name>
+ <url-pattern>/*</url-pattern>
+ </filter-mapping>
+
+ <!-- JBAS-4752: This filter should be enabled when authentication cache -->
+ <!-- must be flushed as soon as the http sessions expire. -->
+
+ <!--
+ <filter>
+ <filter-name>PrincipalSessionAttributeFilter</filter-name>
+ <filter-class>org.jboss.web.tomcat.security.PrincipalSessionAttributeFilter</filter-class>
+ </filter>
+
+ <filter-mapping>
+ <filter-name>PrincipalSessionAttributeFilter</filter-name>
+ <url-pattern>/*</url-pattern>
+ </filter-mapping>
+ -->
+
+ <!-- ================== Common Listener Configuration ==================== -->
+ <listener>
+ <listener-class>org.jboss.web.tomcat.security.SecurityFlushSessionListener</listener-class>
+ </listener>
+
+ <!-- Configures JSF for a web application if the javax.faces.webapp.FacesServlet is declared -->
+ <!-- in web.xml. -->
+ <listener>
+ <listener-class>org.jboss.web.jsf.integration.config.JBossJSFConfigureListener</listener-class>
+ </listener>
+
+ <!-- Listens to all web app lifecycle events so that @PreDestroy can be called on -->
+ <!-- JSF managed beans that go out of scope. You can comment this out if you -->
+ <!-- don't use JSF or you don't use annotations on your managed beans. -->
+ <listener>
+ <listener-class>com.sun.faces.application.WebappLifecycleListener</listener-class>
+ </listener>
+
+
+ <!-- ================== Built In Servlet Definitions ==================== -->
+
+
+ <!-- The default servlet for all web applications, that serves static -->
+ <!-- resources. It processes all requests that are not mapped to other -->
+ <!-- servlets with servlet mappings (defined either here or in your own -->
+ <!-- web.xml file. This servlet supports the following initialization -->
+ <!-- parameters (default values are in square brackets): -->
+ <!-- -->
+ <!-- debug Debugging detail level for messages logged -->
+ <!-- by this servlet. [0] -->
+ <!-- -->
+ <!-- fileEncoding Encoding to be used to read static resources -->
+ <!-- [platform default] -->
+ <!-- -->
+ <!-- input Input buffer size (in bytes) when reading -->
+ <!-- resources to be served. [2048] -->
+ <!-- -->
+ <!-- listings Should directory listings be produced if there -->
+ <!-- is no welcome file in this directory? [false] -->
+ <!-- WARNING: Listings for directories with many -->
+ <!-- entries can be slow and may consume -->
+ <!-- significant proportions of server resources. -->
+ <!-- -->
+ <!-- output Output buffer size (in bytes) when writing -->
+ <!-- resources to be served. [2048] -->
+ <!-- -->
+ <!-- readonly Is this context "read only", so HTTP -->
+ <!-- commands like PUT and DELETE are -->
+ <!-- rejected? [true] -->
+ <!-- -->
+ <!-- readmeFile File name to display with the directory -->
+ <!-- contents. [null] -->
+ <!-- -->
+ <!-- sendfileSize If the connector used supports sendfile, this -->
+ <!-- represents the minimal file size in KB for -->
+ <!-- which sendfile will be used. Use a negative -->
+ <!-- value to always disable sendfile. [48] -->
+ <!-- -->
+ <!-- For directory listing customization. Checks localXsltFile, then -->
+ <!-- globalXsltFile, then defaults to original behavior. -->
+ <!-- -->
+ <!-- localXsltFile Make directory listings an XML doc and -->
+ <!-- pass the result to this style sheet residing -->
+ <!-- in that directory. This overrides -->
+ <!-- globalXsltFile[null] -->
+ <!-- -->
+ <!-- globalXsltFile Site wide configuration version of -->
+ <!-- localXsltFile This argument is expected -->
+ <!-- to be a physical file. [null] -->
+ <!-- -->
+ <!-- -->
+
+ <servlet>
+ <servlet-name>default</servlet-name>
+ <servlet-class>org.apache.catalina.servlets.DefaultServlet</servlet-class>
+ <init-param>
+ <param-name>debug</param-name>
+ <param-value>0</param-value>
+ </init-param>
+ <init-param>
+ <param-name>listings</param-name>
+ <param-value>false</param-value>
+ </init-param>
+ <load-on-startup>1</load-on-startup>
+ </servlet>
+
+
+ <!-- The "invoker" servlet, which executes anonymous servlet classes -->
+ <!-- that have not been defined in a web.xml file. Traditionally, this -->
+ <!-- servlet is mapped to the URL pattern "/servlet/*", but you can map -->
+ <!-- it to other patterns as well. The extra path info portion of such a -->
+ <!-- request must be the fully qualified class name of a Java class that -->
+ <!-- implements Servlet (or extends HttpServlet), or the servlet name -->
+ <!-- of an existing servlet definition. This servlet supports the -->
+ <!-- following initialization parameters (default values are in square -->
+ <!-- brackets): -->
+ <!-- -->
+ <!-- debug Debugging detail level for messages logged -->
+ <!-- by this servlet. [0] -->
+
+<!--
+ <servlet>
+ <servlet-name>invoker</servlet-name>
+ <servlet-class>
+ org.apache.catalina.servlets.InvokerServlet
+ </servlet-class>
+ <init-param>
+ <param-name>debug</param-name>
+ <param-value>0</param-value>
+ </init-param>
+ <load-on-startup>2</load-on-startup>
+ </servlet>
+-->
+
+
+ <!-- The JSP page compiler and execution servlet, which is the mechanism -->
+ <!-- used by Tomcat to support JSP pages. Traditionally, this servlet -->
+ <!-- is mapped to the URL pattern "*.jsp". This servlet supports the -->
+ <!-- following initialization parameters (default values are in square -->
+ <!-- brackets): -->
+ <!-- -->
+ <!-- checkInterval If development is false and checkInterval is -->
+ <!-- greater than zero, background compilations are -->
+ <!-- enabled. checkInterval is the time in seconds -->
+ <!-- between checks to see if a JSP page needs to -->
+ <!-- be recompiled. [0] -->
+ <!-- -->
+ <!-- modificationTestInterval -->
+ <!-- Causes a JSP (and its dependent files) to not -->
+ <!-- be checked for modification during the -->
+ <!-- specified time interval (in seconds) from the -->
+ <!-- last time the JSP was checked for -->
+ <!-- modification. A value of 0 will cause the JSP -->
+ <!-- to be checked on every access. -->
+ <!-- Used in development mode only. [4] -->
+ <!-- -->
+ <!-- compiler Which compiler Ant should use to compile JSP -->
+ <!-- pages. See the Ant documentation for more -->
+ <!-- information. -->
+ <!-- -->
+ <!-- classdebuginfo Should the class file be compiled with -->
+ <!-- debugging information? [true] -->
+ <!-- -->
+ <!-- classpath What class path should I use while compiling -->
+ <!-- generated servlets? [Created dynamically -->
+ <!-- based on the current web application] -->
+ <!-- -->
+ <!-- development Is Jasper used in development mode? If true, -->
+ <!-- the frequency at which JSPs are checked for -->
+ <!-- modification may be specified via the -->
+ <!-- modificationTestInterval parameter. [true] -->
+ <!-- -->
+ <!-- enablePooling Determines whether tag handler pooling is -->
+ <!-- enabled [true] -->
+ <!-- -->
+ <!-- fork Tell Ant to fork compiles of JSP pages so that -->
+ <!-- a separate JVM is used for JSP page compiles -->
+ <!-- from the one Tomcat is running in. [true] -->
+ <!-- -->
+ <!-- ieClassId The class-id value to be sent to Internet -->
+ <!-- Explorer when using <jsp:plugin> tags. -->
+ <!-- [clsid:8AD9C840-044E-11D1-B3E9-00805F499D93] -->
+ <!-- -->
+ <!-- javaEncoding Java file encoding to use for generating java -->
+ <!-- source files. [UTF8] -->
+ <!-- -->
+ <!-- keepgenerated Should we keep the generated Java source code -->
+ <!-- for each page instead of deleting it? [true] -->
+ <!-- -->
+ <!-- mappedfile Should we generate static content with one -->
+ <!-- print statement per input line, to ease -->
+ <!-- debugging? [true] -->
+ <!-- -->
+ <!-- trimSpaces Should white spaces in template text between -->
+ <!-- actions or directives be trimmed? [false] -->
+ <!-- -->
+ <!-- suppressSmap Should the generation of SMAP info for JSR45 -->
+ <!-- debugging be suppressed? [false] -->
+ <!-- -->
+ <!-- dumpSmap Should the SMAP info for JSR45 debugging be -->
+ <!-- dumped to a file? [false] -->
+ <!-- False if suppressSmap is true -->
+ <!-- -->
+ <!-- genStrAsCharArray Should text strings be generated as char -->
+ <!-- arrays, to improve performance in some cases? -->
+ <!-- [false] -->
+ <!-- -->
+ <!-- errorOnUseBeanInvalidClassAttribute -->
+ <!-- Should Jasper issue an error when the value of -->
+ <!-- the class attribute in an useBean action is -->
+ <!-- not a valid bean class? [true] -->
+ <!-- -->
+ <!-- scratchdir What scratch directory should we use when -->
+ <!-- compiling JSP pages? [default work directory -->
+ <!-- for the current web application] -->
+ <!-- -->
+ <!-- xpoweredBy Determines whether X-Powered-By response -->
+ <!-- header is added by generated servlet [false] -->
+ <!-- -->
+ <!-- compilerTargetVM Compiler target VM -->
+ <!-- default is System.properties -->
+ <!-- java.specification.version > 1.4 -->
+ <!-- [1.5] else [1.4] -->
+ <!-- -->
+ <!-- compilerSourceVM Compiler source VM -->
+ <!-- default is System.properties -->
+ <!-- java.specification.version > 1.4 -->
+ <!-- [1.5] else [1.4] -->
+ <!-- -->
+ <!-- If you wish to use Jikes to compile JSP pages: -->
+ <!-- Please see the "Using Jikes" section of the Jasper-HowTo -->
+ <!-- page in the Tomcat documentation. -->
+
+ <servlet>
+ <servlet-name>jsp</servlet-name>
+ <servlet-class>org.apache.jasper.servlet.JspServlet</servlet-class>
+ <init-param>
+ <param-name>fork</param-name>
+ <param-value>false</param-value>
+ </init-param>
+ <init-param>
+ <param-name>xpoweredBy</param-name>
+ <param-value>false</param-value>
+ </init-param>
+ <init-param>
+ <param-name>compilerSourceVM</param-name>
+ <param-value>1.5</param-value>
+ </init-param>
+ <!-- Use a custom options class to allow the shared tag lib descriptors
+ to be loaded from jars in the tomcat sar conf/tlds directory. The
+ standard options implementation can only find taglibs based on the
+ class loader classpath.
+ -->
+ <init-param>
+ <param-name>engineOptionsClass</param-name>
+ <param-value>org.jboss.web.tomcat.service.jasper.JspServletOptions</param-value>
+ </init-param>
+ <!-- Specify the jars relative to the jbossweb-tomcat6.sar that should
+ be scanned for common tag lib descriptors to include in every war
+ deployment.
+ -->
+ <init-param>
+ <description>JSF standard tlds</description>
+ <param-name>tagLibJar0</param-name>
+ <param-value>jsf-libs/jsf-impl.jar</param-value>
+ </init-param>
+ <init-param>
+ <description>JSTL standard tlds</description>
+ <param-name>tagLibJar1</param-name>
+ <param-value>jstl.jar</param-value>
+ </init-param>
+ <init-param>
+ <description>Portlet standard tlds</description>
+ <param-name>tagLibJar2</param-name>
+ <param-value>../simple-portal/portlet-portlet-2.0-SNAPSHOT.jar</param-value>
+ </init-param>
+
+ <load-on-startup>3</load-on-startup>
+ </servlet>
+
+
+ <!-- NOTE: An SSI Filter is also available as an alternative SSI -->
+ <!-- implementation. Use either the Servlet or the Filter but NOT both. -->
+ <!-- -->
+ <!-- Server Side Includes processing servlet, which processes SSI -->
+ <!-- directives in HTML pages consistent with similar support in web -->
+ <!-- servers like Apache. Traditionally, this servlet is mapped to the -->
+ <!-- URL pattern "*.shtml". This servlet supports the following -->
+ <!-- initialization parameters (default values are in square brackets): -->
+ <!-- -->
+ <!-- buffered Should output from this servlet be buffered? -->
+ <!-- (0=false, 1=true) [0] -->
+ <!-- -->
+ <!-- debug Debugging detail level for messages logged -->
+ <!-- by this servlet. [0] -->
+ <!-- -->
+ <!-- expires The number of seconds before a page with SSI -->
+ <!-- directives will expire. [No default] -->
+ <!-- -->
+ <!-- isVirtualWebappRelative -->
+ <!-- Should "virtual" paths be interpreted as -->
+ <!-- relative to the context root, instead of -->
+ <!-- the server root? (0=false, 1=true) [0] -->
+ <!-- -->
+ <!-- inputEncoding The encoding to assume for SSI resources if -->
+ <!-- one is not available from the resource. -->
+ <!-- [Platform default] -->
+ <!-- -->
+ <!-- outputEncoding The encoding to use for the page that results -->
+ <!-- from the SSI processing. [UTF-8] -->
+ <!-- -->
+ <!-- -->
+ <!-- IMPORTANT: To use the SSI servlet, you also need to rename the -->
+ <!-- $CATALINA_HOME/server/lib/servlets-ssi.renametojar file -->
+ <!-- to $CATALINA_HOME/server/lib/servlets-ssi.jar -->
+
+<!--
+ <servlet>
+ <servlet-name>ssi</servlet-name>
+ <servlet-class>
+ org.apache.catalina.ssi.SSIServlet
+ </servlet-class>
+ <init-param>
+ <param-name>buffered</param-name>
+ <param-value>1</param-value>
+ </init-param>
+ <init-param>
+ <param-name>debug</param-name>
+ <param-value>0</param-value>
+ </init-param>
+ <init-param>
+ <param-name>expires</param-name>
+ <param-value>666</param-value>
+ </init-param>
+ <init-param>
+ <param-name>isVirtualWebappRelative</param-name>
+ <param-value>0</param-value>
+ </init-param>
+ <load-on-startup>4</load-on-startup>
+ </servlet>
+-->
+
+
+ <!-- Common Gateway Includes (CGI) processing servlet, which supports -->
+ <!-- execution of external applications that conform to the CGI spec -->
+ <!-- requirements. Typically, this servlet is mapped to the URL pattern -->
+ <!-- "/cgi-bin/*", which means that any CGI applications that are -->
+ <!-- executed must be present within the web application. This servlet -->
+ <!-- supports the following initialization parameters (default values -->
+ <!-- are in square brackets): -->
+ <!-- -->
+ <!-- cgiPathPrefix The CGI search path will start at -->
+ <!-- webAppRootDir + File.separator + this prefix. -->
+ <!-- [WEB-INF/cgi] -->
+ <!-- -->
+ <!-- debug Debugging detail level for messages logged -->
+ <!-- by this servlet. [0] -->
+ <!-- -->
+ <!-- executable Name of the exectuable used to run the -->
+ <!-- script. [perl] -->
+ <!-- -->
+ <!-- parameterEncoding Name of parameter encoding to be used with -->
+ <!-- CGI servlet. -->
+ <!-- [System.getProperty("file.encoding","UTF-8")] -->
+ <!-- -->
+ <!-- passShellEnvironment Should the shell environment variables (if -->
+ <!-- any) be passed to the CGI script? [false] -->
+ <!-- -->
+ <!-- IMPORTANT: To use the CGI servlet, you also need to rename the -->
+ <!-- $CATALINA_HOME/server/lib/servlets-cgi.renametojar file -->
+ <!-- to $CATALINA_HOME/server/lib/servlets-cgi.jar -->
+
+<!--
+ <servlet>
+ <servlet-name>cgi</servlet-name>
+ <servlet-class>org.apache.catalina.servlets.CGIServlet</servlet-class>
+ <init-param>
+ <param-name>debug</param-name>
+ <param-value>0</param-value>
+ </init-param>
+ <init-param>
+ <param-name>cgiPathPrefix</param-name>
+ <param-value>WEB-INF/cgi</param-value>
+ </init-param>
+ <load-on-startup>5</load-on-startup>
+ </servlet>
+-->
+
+
+ <!-- ================ Built In Servlet Mappings ========================= -->
+
+
+ <!-- The servlet mappings for the built in servlets defined above. Note -->
+ <!-- that, by default, the CGI and SSI servlets are *not* mapped. You -->
+ <!-- must uncomment these mappings (or add them to your application's own -->
+ <!-- web.xml deployment descriptor) to enable these services -->
+
+ <!-- The mapping for the default servlet -->
+ <servlet-mapping>
+ <servlet-name>default</servlet-name>
+ <url-pattern>/</url-pattern>
+ </servlet-mapping>
+
+ <!-- The mapping for the invoker servlet -->
+<!--
+ <servlet-mapping>
+ <servlet-name>invoker</servlet-name>
+ <url-pattern>/servlet/*</url-pattern>
+ </servlet-mapping>
+-->
+
+ <!-- The mapping for the JSP servlet -->
+ <servlet-mapping>
+ <servlet-name>jsp</servlet-name>
+ <url-pattern>*.jsp</url-pattern>
+ </servlet-mapping>
+
+ <servlet-mapping>
+ <servlet-name>jsp</servlet-name>
+ <url-pattern>*.jspx</url-pattern>
+ </servlet-mapping>
+
+ <!-- The mapping for the SSI servlet -->
+<!--
+ <servlet-mapping>
+ <servlet-name>ssi</servlet-name>
+ <url-pattern>*.shtml</url-pattern>
+ </servlet-mapping>
+-->
+
+ <!-- The mapping for the CGI Gateway servlet -->
+
+<!--
+ <servlet-mapping>
+ <servlet-name>cgi</servlet-name>
+ <url-pattern>/cgi-bin/*</url-pattern>
+ </servlet-mapping>
+-->
+
+
+ <!-- ================== Built In Filter Definitions ===================== -->
+
+ <!-- NOTE: An SSI Servlet is also available as an alternative SSI -->
+ <!-- implementation. Use either the Servlet or the Filter but NOT both. -->
+ <!-- -->
+ <!-- Server Side Includes processing filter, which processes SSI -->
+ <!-- directives in HTML pages consistent with similar support in web -->
+ <!-- servers like Apache. Traditionally, this filter is mapped to the -->
+ <!-- URL pattern "*.shtml", though it can be mapped to "*" as it will -->
+ <!-- selectively enable/disable SSI processing based on mime types. For -->
+ <!-- this to work you will need to uncomment the .shtml mime type -->
+ <!-- definition towards the bottom of this file. -->
+ <!-- The contentType init param allows you to apply SSI processing to JSP -->
+ <!-- pages, javascript, or any other content you wish. This filter -->
+ <!-- supports the following initialization parameters (default values are -->
+ <!-- in square brackets): -->
+ <!-- -->
+ <!-- contentType A regex pattern that must be matched before -->
+ <!-- SSI processing is applied. -->
+ <!-- [text/x-server-parsed-html(;.*)?] -->
+ <!-- -->
+ <!-- debug Debugging detail level for messages logged -->
+ <!-- by this servlet. [0] -->
+ <!-- -->
+ <!-- expires The number of seconds before a page with SSI -->
+ <!-- directives will expire. [No default] -->
+ <!-- -->
+ <!-- isVirtualWebappRelative -->
+ <!-- Should "virtual" paths be interpreted as -->
+ <!-- relative to the context root, instead of -->
+ <!-- the server root? (0=false, 1=true) [0] -->
+ <!-- -->
+ <!-- -->
+ <!-- IMPORTANT: To use the SSI filter, you also need to rename the -->
+ <!-- $CATALINA_HOME/server/lib/servlets-ssi.renametojar file -->
+ <!-- to $CATALINA_HOME/server/lib/servlets-ssi.jar -->
+
+<!--
+ <filter>
+ <filter-name>ssi</filter-name>
+ <filter-class>
+ org.apache.catalina.ssi.SSIFilter
+ </filter-class>
+ <init-param>
+ <param-name>contentType</param-name>
+ <param-value>text/x-server-parsed-html(;.*)?</param-value>
+ </init-param>
+ <init-param>
+ <param-name>debug</param-name>
+ <param-value>0</param-value>
+ </init-param>
+ <init-param>
+ <param-name>expires</param-name>
+ <param-value>666</param-value>
+ </init-param>
+ <init-param>
+ <param-name>isVirtualWebappRelative</param-name>
+ <param-value>0</param-value>
+ </init-param>
+ </filter>
+-->
+
+
+ <!-- ==================== Built In Filter Mappings ====================== -->
+
+ <!-- The mapping for the SSI Filter -->
+<!--
+ <filter-mapping>
+ <filter-name>ssi</filter-name>
+ <url-pattern>*.shtml</url-pattern>
+ </filter-mapping>
+-->
+
+
+ <!-- ==================== Default Session Configuration ================= -->
+ <!-- You can set the default session timeout (in minutes) for all newly -->
+ <!-- created sessions by modifying the value below. -->
+
+ <session-config>
+ <session-timeout>30</session-timeout>
+ </session-config>
+
+
+ <!-- ===================== Default MIME Type Mappings =================== -->
+ <!-- When serving static resources, Tomcat will automatically generate -->
+ <!-- a "Content-Type" header based on the resource's filename extension, -->
+ <!-- based on these mappings. Additional mappings can be added here (to -->
+ <!-- apply to all web applications), or in your own application's web.xml -->
+ <!-- deployment descriptor. -->
+
+ <mime-mapping>
+ <extension>abs</extension>
+ <mime-type>audio/x-mpeg</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>ai</extension>
+ <mime-type>application/postscript</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>aif</extension>
+ <mime-type>audio/x-aiff</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>aifc</extension>
+ <mime-type>audio/x-aiff</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>aiff</extension>
+ <mime-type>audio/x-aiff</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>aim</extension>
+ <mime-type>application/x-aim</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>art</extension>
+ <mime-type>image/x-jg</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>asf</extension>
+ <mime-type>video/x-ms-asf</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>asx</extension>
+ <mime-type>video/x-ms-asf</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>au</extension>
+ <mime-type>audio/basic</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>avi</extension>
+ <mime-type>video/x-msvideo</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>avx</extension>
+ <mime-type>video/x-rad-screenplay</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>bcpio</extension>
+ <mime-type>application/x-bcpio</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>bin</extension>
+ <mime-type>application/octet-stream</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>bmp</extension>
+ <mime-type>image/bmp</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>body</extension>
+ <mime-type>text/html</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>cdf</extension>
+ <mime-type>application/x-cdf</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>cer</extension>
+ <mime-type>application/x-x509-ca-cert</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>class</extension>
+ <mime-type>application/java</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>cpio</extension>
+ <mime-type>application/x-cpio</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>csh</extension>
+ <mime-type>application/x-csh</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>css</extension>
+ <mime-type>text/css</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>dib</extension>
+ <mime-type>image/bmp</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>doc</extension>
+ <mime-type>application/msword</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>dtd</extension>
+ <mime-type>application/xml-dtd</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>dv</extension>
+ <mime-type>video/x-dv</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>dvi</extension>
+ <mime-type>application/x-dvi</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>eps</extension>
+ <mime-type>application/postscript</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>etx</extension>
+ <mime-type>text/x-setext</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>exe</extension>
+ <mime-type>application/octet-stream</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>gif</extension>
+ <mime-type>image/gif</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>gtar</extension>
+ <mime-type>application/x-gtar</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>gz</extension>
+ <mime-type>application/x-gzip</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>hdf</extension>
+ <mime-type>application/x-hdf</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>hqx</extension>
+ <mime-type>application/mac-binhex40</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>htc</extension>
+ <mime-type>text/x-component</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>htm</extension>
+ <mime-type>text/html</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>html</extension>
+ <mime-type>text/html</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>hqx</extension>
+ <mime-type>application/mac-binhex40</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>ief</extension>
+ <mime-type>image/ief</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>jad</extension>
+ <mime-type>text/vnd.sun.j2me.app-descriptor</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>jar</extension>
+ <mime-type>application/java-archive</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>java</extension>
+ <mime-type>text/plain</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>jnlp</extension>
+ <mime-type>application/x-java-jnlp-file</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>jpe</extension>
+ <mime-type>image/jpeg</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>jpeg</extension>
+ <mime-type>image/jpeg</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>jpg</extension>
+ <mime-type>image/jpeg</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>js</extension>
+ <mime-type>text/javascript</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>jsf</extension>
+ <mime-type>text/plain</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>jspf</extension>
+ <mime-type>text/plain</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>kar</extension>
+ <mime-type>audio/x-midi</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>latex</extension>
+ <mime-type>application/x-latex</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>m3u</extension>
+ <mime-type>audio/x-mpegurl</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>mac</extension>
+ <mime-type>image/x-macpaint</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>man</extension>
+ <mime-type>application/x-troff-man</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>mathml</extension>
+ <mime-type>application/mathml+xml</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>me</extension>
+ <mime-type>application/x-troff-me</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>mid</extension>
+ <mime-type>audio/x-midi</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>midi</extension>
+ <mime-type>audio/x-midi</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>mif</extension>
+ <mime-type>application/x-mif</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>mov</extension>
+ <mime-type>video/quicktime</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>movie</extension>
+ <mime-type>video/x-sgi-movie</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>mp1</extension>
+ <mime-type>audio/x-mpeg</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>mp2</extension>
+ <mime-type>audio/x-mpeg</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>mp3</extension>
+ <mime-type>audio/x-mpeg</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>mpa</extension>
+ <mime-type>audio/x-mpeg</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>mpe</extension>
+ <mime-type>video/mpeg</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>mpeg</extension>
+ <mime-type>video/mpeg</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>mpega</extension>
+ <mime-type>audio/x-mpeg</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>mpg</extension>
+ <mime-type>video/mpeg</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>mpv2</extension>
+ <mime-type>video/mpeg2</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>ms</extension>
+ <mime-type>application/x-wais-source</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>nc</extension>
+ <mime-type>application/x-netcdf</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>oda</extension>
+ <mime-type>application/oda</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <!-- OpenDocument Database -->
+ <extension>odb</extension>
+ <mime-type>application/vnd.oasis.opendocument.database</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <!-- OpenDocument Chart -->
+ <extension>odc</extension>
+ <mime-type>application/vnd.oasis.opendocument.chart</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <!-- OpenDocument Formula -->
+ <extension>odf</extension>
+ <mime-type>application/vnd.oasis.opendocument.formula</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <!-- OpenDocument Drawing -->
+ <extension>odg</extension>
+ <mime-type>application/vnd.oasis.opendocument.graphics</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <!-- OpenDocument Image -->
+ <extension>odi</extension>
+ <mime-type>application/vnd.oasis.opendocument.image</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <!-- OpenDocument Master Document -->
+ <extension>odm</extension>
+ <mime-type>application/vnd.oasis.opendocument.text-master</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <!-- OpenDocument Presentation -->
+ <extension>odp</extension>
+ <mime-type>application/vnd.oasis.opendocument.presentation</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <!-- OpenDocument Spreadsheet -->
+ <extension>ods</extension>
+ <mime-type>application/vnd.oasis.opendocument.spreadsheet</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <!-- OpenDocument Text -->
+ <extension>odt</extension>
+ <mime-type>application/vnd.oasis.opendocument.text</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>ogg</extension>
+ <mime-type>application/ogg</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <!-- OpenDocument Drawing Template -->
+ <extension>otg </extension>
+ <mime-type>application/vnd.oasis.opendocument.graphics-template</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <!-- HTML Document Template -->
+ <extension>oth</extension>
+ <mime-type>application/vnd.oasis.opendocument.text-web</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <!-- OpenDocument Presentation Template -->
+ <extension>otp</extension>
+ <mime-type>application/vnd.oasis.opendocument.presentation-template</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <!-- OpenDocument Spreadsheet Template -->
+ <extension>ots</extension>
+ <mime-type>application/vnd.oasis.opendocument.spreadsheet-template </mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <!-- OpenDocument Text Template -->
+ <extension>ott</extension>
+ <mime-type>application/vnd.oasis.opendocument.text-template</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>pbm</extension>
+ <mime-type>image/x-portable-bitmap</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>pct</extension>
+ <mime-type>image/pict</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>pdf</extension>
+ <mime-type>application/pdf</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>pgm</extension>
+ <mime-type>image/x-portable-graymap</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>pic</extension>
+ <mime-type>image/pict</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>pict</extension>
+ <mime-type>image/pict</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>pls</extension>
+ <mime-type>audio/x-scpls</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>png</extension>
+ <mime-type>image/png</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>pnm</extension>
+ <mime-type>image/x-portable-anymap</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>pnt</extension>
+ <mime-type>image/x-macpaint</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>ppm</extension>
+ <mime-type>image/x-portable-pixmap</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>ppt</extension>
+ <mime-type>application/powerpoint</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>ps</extension>
+ <mime-type>application/postscript</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>psd</extension>
+ <mime-type>image/x-photoshop</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>qt</extension>
+ <mime-type>video/quicktime</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>qti</extension>
+ <mime-type>image/x-quicktime</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>qtif</extension>
+ <mime-type>image/x-quicktime</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>ras</extension>
+ <mime-type>image/x-cmu-raster</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>rdf</extension>
+ <mime-type>application/rdf+xml</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>rgb</extension>
+ <mime-type>image/x-rgb</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>rm</extension>
+ <mime-type>application/vnd.rn-realmedia</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>roff</extension>
+ <mime-type>application/x-troff</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>rtf</extension>
+ <mime-type>application/rtf</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>rtx</extension>
+ <mime-type>text/richtext</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>sh</extension>
+ <mime-type>application/x-sh</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>shar</extension>
+ <mime-type>application/x-shar</mime-type>
+ </mime-mapping>
+<!--
+ <mime-mapping>
+ <extension>shtml</extension>
+ <mime-type>text/x-server-parsed-html</mime-type>
+ </mime-mapping>
+-->
+ <mime-mapping>
+ <extension>smf</extension>
+ <mime-type>audio/x-midi</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>sit</extension>
+ <mime-type>application/x-stuffit</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>snd</extension>
+ <mime-type>audio/basic</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>src</extension>
+ <mime-type>application/x-wais-source</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>sv4cpio</extension>
+ <mime-type>application/x-sv4cpio</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>sv4crc</extension>
+ <mime-type>application/x-sv4crc</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>swf</extension>
+ <mime-type>application/x-shockwave-flash</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>t</extension>
+ <mime-type>application/x-troff</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>tar</extension>
+ <mime-type>application/x-tar</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>tcl</extension>
+ <mime-type>application/x-tcl</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>tex</extension>
+ <mime-type>application/x-tex</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>texi</extension>
+ <mime-type>application/x-texinfo</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>texinfo</extension>
+ <mime-type>application/x-texinfo</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>tif</extension>
+ <mime-type>image/tiff</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>tiff</extension>
+ <mime-type>image/tiff</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>tr</extension>
+ <mime-type>application/x-troff</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>tsv</extension>
+ <mime-type>text/tab-separated-values</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>txt</extension>
+ <mime-type>text/plain</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>ulw</extension>
+ <mime-type>audio/basic</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>ustar</extension>
+ <mime-type>application/x-ustar</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>vxml</extension>
+ <mime-type>application/voicexml+xml</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>xbm</extension>
+ <mime-type>image/x-xbitmap</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>xht</extension>
+ <mime-type>application/xhtml+xml</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>xhtml</extension>
+ <mime-type>application/xhtml+xml</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>xml</extension>
+ <mime-type>application/xml</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>xpm</extension>
+ <mime-type>image/x-xpixmap</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>xsl</extension>
+ <mime-type>application/xml</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>xslt</extension>
+ <mime-type>application/xslt+xml</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>xul</extension>
+ <mime-type>application/vnd.mozilla.xul+xml</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>xwd</extension>
+ <mime-type>image/x-xwindowdump</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>wav</extension>
+ <mime-type>audio/x-wav</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>svg</extension>
+ <mime-type>image/svg+xml</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>svgz</extension>
+ <mime-type>image/svg+xml</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>vsd</extension>
+ <mime-type>application/x-visio</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <!-- Wireless Bitmap -->
+ <extension>wbmp</extension>
+ <mime-type>image/vnd.wap.wbmp</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <!-- WML Source -->
+ <extension>wml</extension>
+ <mime-type>text/vnd.wap.wml</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <!-- Compiled WML -->
+ <extension>wmlc</extension>
+ <mime-type>application/vnd.wap.wmlc</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <!-- WML Script Source -->
+ <extension>wmls</extension>
+ <mime-type>text/vnd.wap.wmlscript</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <!-- Compiled WML Script -->
+ <extension>wmlscriptc</extension>
+ <mime-type>application/vnd.wap.wmlscriptc</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>wrl</extension>
+ <mime-type>x-world/x-vrml</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>Z</extension>
+ <mime-type>application/x-compress</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>z</extension>
+ <mime-type>application/x-compress</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>zip</extension>
+ <mime-type>application/zip</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>xls</extension>
+ <mime-type>application/vnd.ms-excel</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>doc</extension>
+ <mime-type>application/vnd.ms-word</mime-type>
+ </mime-mapping>
+ <mime-mapping>
+ <extension>ppt</extension>
+ <mime-type>application/vnd.ms-powerpoint</mime-type>
+ </mime-mapping>
+
+ <!-- ==================== Default Welcome File List ===================== -->
+ <!-- When a request URI refers to a directory, the default servlet looks -->
+ <!-- for a "welcome file" within that directory and, if present, -->
+ <!-- to the corresponding resource URI for display. If no welcome file -->
+ <!-- is present, the default servlet either serves a directory listing, -->
+ <!-- or returns a 404 status, depending on how it is configured. -->
+ <!-- -->
+ <!-- If you define welcome files in your own application's web.xml -->
+ <!-- deployment descriptor, that list *replaces* the list configured -->
+ <!-- here, so be sure that you include any of the default values that -->
+ <!-- you wish to include. -->
+
+ <welcome-file-list>
+ <welcome-file>index.html</welcome-file>
+ <welcome-file>index.htm</welcome-file>
+ <welcome-file>index.jsp</welcome-file>
+ </welcome-file-list>
+
+</web-app>
16 years, 3 months
JBoss Portal SVN: r10170 - modules/portlet/trunk/samples.
by portal-commits@lists.jboss.org
Author: julien(a)jboss.com
Date: 2008-03-02 17:05:53 -0500 (Sun, 02 Mar 2008)
New Revision: 10170
Added:
modules/portlet/trunk/samples/pom.xml
Log:
adding pom.xml
Added: modules/portlet/trunk/samples/pom.xml
===================================================================
--- modules/portlet/trunk/samples/pom.xml (rev 0)
+++ modules/portlet/trunk/samples/pom.xml 2008-03-02 22:05:53 UTC (rev 10170)
@@ -0,0 +1,41 @@
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+ <parent>
+ <groupId>org.jboss.portal.portlet</groupId>
+ <artifactId>module-parent</artifactId>
+ <version>2.0-SNAPSHOT</version>
+ <relativePath>../build/pom.xml</relativePath>
+ </parent>
+ <modelVersion>4.0.0</modelVersion>
+ <artifactId>portlet-samples</artifactId>
+ <packaging>jar</packaging>
+ <name>Portlet Samples</name>
+
+ <dependencies>
+ <dependency>
+ <groupId>javax.portlet</groupId>
+ <artifactId>portlet-api</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>sun-jaxb</groupId>
+ <artifactId>jaxb-api</artifactId>
+ </dependency>
+ </dependencies>
+
+ <build>
+ <plugins>
+ <plugin>
+ <artifactId>maven-assembly-plugin</artifactId>
+ <configuration>
+ <descriptors>
+ <descriptor>src/assemble/samples-basic-portlet.xml</descriptor>
+ <descriptor>src/assemble/samples-shoppingcart-portlet.xml</descriptor>
+ <descriptor>src/assemble/samples-google-portlet.xml</descriptor>
+ <descriptor>src/assemble/samples-remotecontroller-portlet.xml</descriptor>
+ </descriptors>
+ </configuration>
+ </plugin>
+ </plugins>
+ </build>
+
+</project>
16 years, 3 months
JBoss Portal SVN: r10169 - modules/portlet/trunk/portlet/src/test/java/org/jboss/portal/unit.
by portal-commits@lists.jboss.org
Author: chris.laprun(a)jboss.com
Date: 2008-03-02 15:48:11 -0500 (Sun, 02 Mar 2008)
New Revision: 10169
Removed:
modules/portlet/trunk/portlet/src/test/java/org/jboss/portal/unit/TestContants.java
Log:
- Really remove TestContants after its renaming to TestConstants (not sure why it wasn't done the first time)...
Deleted: modules/portlet/trunk/portlet/src/test/java/org/jboss/portal/unit/TestContants.java
===================================================================
--- modules/portlet/trunk/portlet/src/test/java/org/jboss/portal/unit/TestContants.java 2008-03-02 19:49:00 UTC (rev 10168)
+++ modules/portlet/trunk/portlet/src/test/java/org/jboss/portal/unit/TestContants.java 2008-03-02 20:48:11 UTC (rev 10169)
@@ -1,43 +0,0 @@
-/******************************************************************************
- * JBoss, a division of Red Hat *
- * Copyright 2006, Red Hat Middleware, LLC, 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.portal.unit;
-
-/**
- * Constants for test asserts
- *
- * @author <a href="mailto:boleslaw.dawidowicz@jboss.org">Boleslaw Dawidowicz</a>
- * @version $Revision: 5510 $
- */
-public final class TestContants
-{
-
- /** String from <code>PortletContext.getServerInfo()</code/>. */
- public static final String SERVER_INVO = "JBossPortal/1.0";
-
- /** int for <code>PortletContext.getMinorVersion()</code/>. */
- public static final int MINOR_VERSION = 0;
-
- /** int for <code>PortletContext.getMajorVersion()</code/>. */
- public static final int MAJOR_VERSION = 2;
-
-}
16 years, 3 months
JBoss Portal SVN: r10168 - modules/portlet/trunk/portal/src/assemble.
by portal-commits@lists.jboss.org
Author: julien(a)jboss.com
Date: 2008-03-02 14:49:00 -0500 (Sun, 02 Mar 2008)
New Revision: 10168
Modified:
modules/portlet/trunk/portal/src/assemble/simple-portal-jboss42.xml
modules/portlet/trunk/portal/src/assemble/simple-portal-tomcat60.xml
Log:
name should be "assemble" and not "assembly" for the directories containing the assembly plugin files
Modified: modules/portlet/trunk/portal/src/assemble/simple-portal-jboss42.xml
===================================================================
--- modules/portlet/trunk/portal/src/assemble/simple-portal-jboss42.xml 2008-03-02 19:44:08 UTC (rev 10167)
+++ modules/portlet/trunk/portal/src/assemble/simple-portal-jboss42.xml 2008-03-02 19:49:00 UTC (rev 10168)
@@ -6,8 +6,8 @@
<baseDirectory>simple-portal</baseDirectory>
<componentDescriptors>
- <componentDescriptor>src/assembly/simple-portal-war.xml</componentDescriptor>
- <componentDescriptor>src/assembly/simple-portal-lib.xml</componentDescriptor>
+ <componentDescriptor>src/assemble/simple-portal-war.xml</componentDescriptor>
+ <componentDescriptor>src/assemble/simple-portal-lib.xml</componentDescriptor>
</componentDescriptors>
</assembly>
Modified: modules/portlet/trunk/portal/src/assemble/simple-portal-tomcat60.xml
===================================================================
--- modules/portlet/trunk/portal/src/assemble/simple-portal-tomcat60.xml 2008-03-02 19:44:08 UTC (rev 10167)
+++ modules/portlet/trunk/portal/src/assemble/simple-portal-tomcat60.xml 2008-03-02 19:49:00 UTC (rev 10168)
@@ -6,8 +6,8 @@
<baseDirectory>simple-portal</baseDirectory>
<componentDescriptors>
- <componentDescriptor>src/assembly/simple-portal-war.xml</componentDescriptor>
- <componentDescriptor>src/assembly/simple-portal-lib.xml</componentDescriptor>
+ <componentDescriptor>src/assemble/simple-portal-war.xml</componentDescriptor>
+ <componentDescriptor>src/assemble/simple-portal-lib.xml</componentDescriptor>
</componentDescriptors>
<dependencySets>
16 years, 3 months