gatein SVN: r4251 - in components/pc/trunk: bridge and 11 other directories.
by do-not-reply@jboss.org
Author: julien_viet
Date: 2010-09-20 04:45:10 -0400 (Mon, 20 Sep 2010)
New Revision: 4251
Modified:
components/pc/trunk/api/
components/pc/trunk/bridge/
components/pc/trunk/controller/
components/pc/trunk/docs/
components/pc/trunk/docs/user-guide/
components/pc/trunk/federation/
components/pc/trunk/jsr168api/
components/pc/trunk/management/
components/pc/trunk/mc/
components/pc/trunk/portal/
components/pc/trunk/portlet/
components/pc/trunk/samples/
components/pc/trunk/test/
Log:
more svn:ignore
Property changes on: components/pc/trunk/api
___________________________________________________________________
Name: svn:ignore
- target
+ target
*.iml
Property changes on: components/pc/trunk/bridge
___________________________________________________________________
Name: svn:ignore
- target
+ target
*.iml
Property changes on: components/pc/trunk/controller
___________________________________________________________________
Name: svn:ignore
- target
+ target
*.iml
Property changes on: components/pc/trunk/docs
___________________________________________________________________
Name: svn:ignore
+ *.iml
Property changes on: components/pc/trunk/docs/user-guide
___________________________________________________________________
Name: svn:ignore
- target
+ target
*.iml
Property changes on: components/pc/trunk/federation
___________________________________________________________________
Name: svn:ignore
- target
+ target
*.iml
Property changes on: components/pc/trunk/jsr168api
___________________________________________________________________
Name: svn:ignore
- target
+ target
*.iml
Property changes on: components/pc/trunk/management
___________________________________________________________________
Name: svn:ignore
- target
+ target
*.iml
Property changes on: components/pc/trunk/mc
___________________________________________________________________
Name: svn:ignore
- target
+ target
*.iml
Property changes on: components/pc/trunk/portal
___________________________________________________________________
Name: svn:ignore
- target
+ target
*.iml
Property changes on: components/pc/trunk/portlet
___________________________________________________________________
Name: svn:ignore
- target
+ target
*.iml
Property changes on: components/pc/trunk/samples
___________________________________________________________________
Name: svn:ignore
- target
+ target
*.iml
Property changes on: components/pc/trunk/test
___________________________________________________________________
Name: svn:ignore
- target
+ target
*.iml
14 years, 3 months
gatein SVN: r4250 - components/pc/trunk.
by do-not-reply@jboss.org
Author: julien_viet
Date: 2010-09-20 04:16:07 -0400 (Mon, 20 Sep 2010)
New Revision: 4250
Modified:
components/pc/trunk/
Log:
ignore .idea too
Property changes on: components/pc/trunk
___________________________________________________________________
Name: svn:ignore
- target
.settings
.project
*.iml
+ target
.settings
.project
.idea
*.iml
14 years, 3 months
gatein SVN: r4249 - components/pc/trunk.
by do-not-reply@jboss.org
Author: julien_viet
Date: 2010-09-20 04:15:31 -0400 (Mon, 20 Sep 2010)
New Revision: 4249
Modified:
components/pc/trunk/
Log:
ignore *.iml
Property changes on: components/pc/trunk
___________________________________________________________________
Name: svn:ignore
- target
.settings
.project
+ target
.settings
.project
*.iml
14 years, 3 months
gatein SVN: r4248 - epp/docs/branches/EPP_5_0_Branch/5.0.1_Release_Notes/en-US.
by do-not-reply@jboss.org
Author: smumford
Date: 2010-09-20 03:54:11 -0400 (Mon, 20 Sep 2010)
New Revision: 4248
Modified:
epp/docs/branches/EPP_5_0_Branch/5.0.1_Release_Notes/en-US/5.0.1_Release_Notes.xml
epp/docs/branches/EPP_5_0_Branch/5.0.1_Release_Notes/en-US/Book_Info.xml
epp/docs/branches/EPP_5_0_Branch/5.0.1_Release_Notes/en-US/Revision_History.xml
Log:
JBEPP-377: Updated Release Notes based on review feedback
Modified: epp/docs/branches/EPP_5_0_Branch/5.0.1_Release_Notes/en-US/5.0.1_Release_Notes.xml
===================================================================
--- epp/docs/branches/EPP_5_0_Branch/5.0.1_Release_Notes/en-US/5.0.1_Release_Notes.xml 2010-09-20 06:00:10 UTC (rev 4247)
+++ epp/docs/branches/EPP_5_0_Branch/5.0.1_Release_Notes/en-US/5.0.1_Release_Notes.xml 2010-09-20 07:54:11 UTC (rev 4248)
@@ -188,39 +188,30 @@
<term><ulink type="http" url="https://jira.jboss.org/browse/JBEPP-452"></ulink></term>
<listitem>
<para>
- &PRODUCT; used <literal>request.getLocale()</literal> to localize a <literal>ResourceBundle</literal> which only reflected a user's <emphasis>browser</emphasis> language preference, while the rest of the portal employs a more complex logic to determine what locale is used. Under certain circumstances this mismatch caused the localization to switch incorrectly.
+ &PRODUCT;'s <literal>request.getLocale()</literal> only reflected a user's <emphasis>browser</emphasis> language preference, regardless of what language was set in the portal itself.
</para>
<para>
- A <literal>LocalizationFilter</literal> to wrap <literal>HttpServletRequest</literal> and override <literal>getLocale()</literal> / <literal>getLocales()</literal> and return values that are in sync with the rest of the portal was installed to address this issue. This creates a universal solution for all extra-portal-page resources that are served via non-portal-page URLs, and are outside regular portal page processing pipeline.
+ A <literal>LocalizationFilter</literal> to wrap <literal>HttpServletRequest</literal> and override <literal>getLocale()</literal> / <literal>getLocales()</literal> and return values that are in sync with the rest of the portal was installed to address this issue.
</para>
<para>
As a result, portlets use the preferred locale of a user and not the locale from the http servlet request.
</para>
- <para>
- This fix has also corrected language issues wherein the locale was not set correctly after a failed login attempt (<ulink type="http" url="https://jira.jboss.org/browse/JBEPP-403"></ulink>) and where language setting for languages with country variants, such as Chinese - China and Chinese - Taiwan, were lost at re-login. (<ulink type="http" url="https://jira.jboss.org/browse/JBEPP-383"></ulink>).
- </para>
- <note>
- <title>DOCS NOTE</title>
- <para>
- (Information gathered from <ulink type="http" url="https://jira.jboss.org/browse/GTNPORTAL-1355"></ulink>)
- </para>
- </note>
-
</listitem>
</varlistentry>
<varlistentry>
- <term><ulink type="http" url="https://jira.jboss.org/browse/JBEPP-451"></ulink></term>
+ <term><ulink type="http" url="https://jira.jboss.org/browse/JBEPP-403"></ulink></term>
<listitem>
<para>
- <literal>NullPointerExceptions</literal> were being encountered when a new <literal>UIFormMultiValueInputset</literal> was created using a <literal>UIComponent</literal> without some arguments being explicitly set. <filename>UIFormMultiValueInputset.java</filename> has been modified to pass <literal>parameterTypes</literal> and <literal>parameterValues</literal> to a constructor when a new <literal>UIFormMultilValueInputset</literal> is created. This corrects the exceptions encountered when invoking a non-default constructor.
+ The <literal>LocalizationFilter</literal> fix implemented for <ulink type="http" url="https://jira.jboss.org/browse/JBEPP-452"></ulink> also corrected an issue wherein a failed login attempt would present the login form in an incorrect language (that is; not the language set for the portal).
</para>
- <note>
- <title>DOCS NOTE</title>
-
+ </listitem>
+ </varlistentry>
+ <varlistentry>
+ <term><ulink type="http" url="https://jira.jboss.org/browse/JBEPP-383"></ulink></term>
+ <listitem>
<para>
- (Information sourced from <ulink type="http" url="https://jira.jboss.org/browse/GTNPORTAL-1223"></ulink>, <ulink type="http" url="https://jira.jboss.org/browse/GTNPORTAL-1225"></ulink> and <ulink type="http" url="https://jira.jboss.org/browse/JBEPP-405"></ulink>)
+ The <literal>LocalizationFilter</literal> fix also corrected an issue which caused language settings for languages with country variants (such as Chinese - China and Chinese - Taiwan) were not stored between logins.
</para>
- </note>
</listitem>
</varlistentry>
<varlistentry>
@@ -230,7 +221,7 @@
The Shindig Gadget Server was reporting malformed security tokens after a gadget was added to a portal. The error was originating from the <literal>org.apache.shindig.gadgets.servlet.RpcServlet</literal>'s <literal>doPost</literal> processing method. This method of reading POST requests from the servlet's input stream was being corrupted if the <literal>InputStream</literal> had already been read (in the recorded case, by <literal>RequestDumperValve</literal>).
</para>
<para>
- This error was resolved with a component upgrade to Apache Shindig 1.0-r790473-Patch03 which allows a reset of the input stream before the <literal>doPost</literal> method is invoked.
+ This error was resolved with a patch to Apache Shindig which allows a reset of the input stream before the <literal>doPost</literal> method is invoked.
</para>
</listitem>
</varlistentry>
@@ -243,18 +234,40 @@
<para>
This issue has been fixed with an updated PicketLink jar.
</para>
+ </listitem>
+ </varlistentry>
+ <varlistentry>
+ <term><ulink type="http" url="https://jira.jboss.org/browse/JBEPP-363"></ulink></term>
+ <listitem>
<para>
- This fix has also resolved an issue encountered when deleting registered portal users from LDAP. Information about users deleted from LDAP would still be retained in the database and those user accounts would appear in the portal user list. If one of these legacy accounts was then edited, the inconsistences would prevent any further login attempts from succeeding until the user session was cleared. (<ulink type="http" url="https://jira.jboss.org/browse/JBEPP-363"></ulink>).
+ The updated PicketLink jar has also resolved an issue encountered when deleting registered portal users from LDAP.
</para>
+ <para>
+ Information about users deleted from LDAP would still be retained in the database and those user accounts would appear in the portal user list. If one of these legacy accounts was then edited, the inconsistences would prevent any further login attempts from succeeding until the user session was cleared.
+ </para>
</listitem>
</varlistentry>
<varlistentry>
+ <term><ulink type="http" url="https://jira.jboss.org/browse/GTNPORTAL-1309"></ulink></term>
+ <listitem>
+ <para>
+ The updated PicketLink IDM component removes case-sensitivity from the username field of the portal login page.
+ </para>
+ <para>
+ This allows users whose login names contain capital latters to authenticate successfully, regardless of the case used in the username field of the login form.
+ </para>
+ <para>
+ Note that the password field remains case-sensitive for security.
+ </para>
+ </listitem>
+ </varlistentry>
+ <varlistentry>
<term><ulink type="http" url="https://jira.jboss.org/browse/JBEPP-368"></ulink></term>
<listitem>
<para>
The datasource defined in <filename>jboss-epp-5.0/jboss-as/docs/examples/portal/gatein-sample-portal-ds.xml</filename> has been updated from <literal>local-tx-datasourc</literal> to <literal>no-tx-datasource</literal>.
- </para>
- <para>
+ </para>
+ <para>
This update prevents exceptions being thrown by the JCR when the name of the datasource in <filename>server/default/deploy/gatein-ds.xml</filename> is changed to suit operational requirements.
</para>
</listitem>
@@ -263,12 +276,9 @@
<term><ulink type="http" url="https://jira.jboss.org/browse/JBEPP-342"></ulink></term>
<listitem>
<para>
- Node names were being dispalyed incorrectly if the name contained special characters when the site language was changed to a different locale. For example; if the site language was changed to German the SiteMap node would display as <literal>Seiten&uuml;bersicht</literal> instead of <emphasis role="bold">Seitenübersicht</emphasis>.
+ Node names were being displayed incorrectly if they contained accentuated characters. For example; if the site language was German, the SiteMap node would display as <literal>Seiten&uuml;bersicht</literal> instead of <emphasis role="bold">Seitenübersicht</emphasis>.
</para>
<para>
- Badly escaped special characters caused these characters to render <emphasis>literally</emphasis> on the page instead of being rendered as human-readable special characters.
- </para>
- <para>
Language <filename>.properties</filename> files have been updated to escape special characters correctly and languages that contain special characters now render as expected.
</para>
</listitem>
@@ -285,11 +295,17 @@
<term><ulink type="http" url="https://jira.jboss.org/browse/JBEPP-167"></ulink></term>
<listitem>
<para>
- This release includes a copy of the <filename>jcip-annotations.jar</filename> in the <filename>/server/default/lib</filename> directory.
+ A bug in the IBM JDK (1.5) would prevent the <literal>HAPartition</literal> service from starting. This, in turn, prevented JBoss AS from starting correctly when using the <literal>all</literal> configuration. The HAPartition would return the following error:
</para>
+<screen>ERROR [AbstractKernelController] Error installing to Start: name=HAPartition state=Create
+org.jboss.cache.config.ConfigurationException: Unable to build interceptor chain
+</screen>
<para>
- This file is needed to avoid an exception causing the <literal>HAPartition</literal> service to fail to start when using IBM JDK 1.5.
+ This release includes a copy of the <filename>jcip-annotations.jar</filename> in the <filename>/server/default/lib</filename> directory as a workaround.
</para>
+ <para>
+ This file is needed to avoid the above exception and may be removed in a later release.
+ </para>
</listitem>
</varlistentry>
</variablelist>
@@ -303,11 +319,17 @@
A list of general issues in this release can be found at:
</para>
<para>
- <ulink type="http" url="https://jira.jboss.org/secure/IssueNavigator.jspa?reset=true&jqlQuery..."></ulink>
+ <ulink type="http" url="https://jira.jboss.org/secure/IssueNavigator.jspa?mode=hide&requestId..."></ulink>
</para>
+ <warning>
+ <title>DOC NOTE</title>
+ <para>
+ Is this list appropriate to offer readers? It points to a JIRA filter for all Open/Unresolved bugs attached to EPP 5.0.1 (so it doesn't catch related JIRAs for GTN or PLIDM etc, unless they're cloned to JBEPP).
+ </para>
+ </warning>
</section>
- <section>
+<!-- <section>
<title>Security Issues</title>
<variablelist>
<varlistentry>
@@ -322,43 +344,13 @@
</listitem>
</varlistentry>
</variablelist>
- </section>
+ </section>-->
- <section id="sect-Release_Notes-_Known_Issues_with_this_release_-Component_Specific_Known_Issues">
- <title>Specific Known Issues</title>
- <variablelist>
- <varlistentry>
- <term><ulink type="http" url="https://jira.jboss.org/browse/JBEPP-406"></ulink></term>
- <listitem>
- <para>
- This issue has no information and I wasn't able to determine the problem from <ulink type="http" url="https://jira.jboss.org/browse/GTNPORTAL-756"></ulink> or <ulink type="http" url="http://jira.exoplatform.org/browse/PORTAL-3720"></ulink>.
- </para>
- <para>
- Please supply a starter draft paragraph and I will edit it for the next burn of these Release Notes.
- </para>
- </listitem>
- </varlistentry>
- <varlistentry>
- <term><ulink type="http" url="https://jira.jboss.org/">https://jira.jboss.org/</ulink></term>
- <listitem>
- <para>
- Issue.
- </para>
- </listitem>
- </varlistentry>
- </variablelist>
- </section>
-
</section>
<section>
<title>Recommended Practices</title>
- <note>
- <title>DOC TODO</title>
- <para>
- Is this section still required/relevant?
- </para>
- </note>
+<!--DOC TODO: This Information should be in the Installtion Guide. Move for 5.1.0 release.-->
<para>
&PRODUCT; &VERSION; includes four pre-configured user accounts for testing and evaluation puposes. These accounts can be used for direct access to the portal.
</para>
@@ -414,12 +406,6 @@
</warning>
<section>
<title>Site Publisher</title>
- <note>
- <title>DOC TODO</title>
- <para>
- Is this section still required/relevant?
- </para>
- </note>
<para>
&PRODUCT; 5.1 will include an optional web content authoring system add on called Site Publisher. A technical preview of this add on is available for download from the <ulink type="http" url="https://support.redhat.com/jbossnetwork/restricted/softwareDetail.html?so...">Red Hat Customer Support Portal</ulink>.
</para>
Modified: epp/docs/branches/EPP_5_0_Branch/5.0.1_Release_Notes/en-US/Book_Info.xml
===================================================================
--- epp/docs/branches/EPP_5_0_Branch/5.0.1_Release_Notes/en-US/Book_Info.xml 2010-09-20 06:00:10 UTC (rev 4247)
+++ epp/docs/branches/EPP_5_0_Branch/5.0.1_Release_Notes/en-US/Book_Info.xml 2010-09-20 07:54:11 UTC (rev 4248)
@@ -5,7 +5,7 @@
<title>5.0.1 Release Notes</title>
<subtitle>For use with JBoss Enterprise Portal Platform 5.0.1</subtitle>
<edition>1.0</edition>
- <pubsnumber>1.1</pubsnumber>
+ <pubsnumber>1.2</pubsnumber>
<productname>JBoss Enterprise Portal Platform</productname>
<productnumber>5.0</productnumber>
<abstract>
Modified: epp/docs/branches/EPP_5_0_Branch/5.0.1_Release_Notes/en-US/Revision_History.xml
===================================================================
--- epp/docs/branches/EPP_5_0_Branch/5.0.1_Release_Notes/en-US/Revision_History.xml 2010-09-20 06:00:10 UTC (rev 4247)
+++ epp/docs/branches/EPP_5_0_Branch/5.0.1_Release_Notes/en-US/Revision_History.xml 2010-09-20 07:54:11 UTC (rev 4248)
@@ -5,7 +5,21 @@
<title>Revision History</title>
<simpara>
<revhistory>
- <revision>
+ <revision>
+ <revnumber>1.2</revnumber>
+ <date>Mon Sep 20 2010</date>
+ <author>
+ <firstname>Scott</firstname>
+ <surname>Mumford</surname>
+ <email>smumford(a)redhat.com</email>
+ </author>
+ <revdescription>
+ <simplelist>
+ <member>Refined JIRA descriptions and added new JIRA links.</member>
+ </simplelist>
+ </revdescription>
+ </revision>
+ <revision>
<revnumber>1.1</revnumber>
<date>Mon Sep 06 2010</date>
<author>
14 years, 3 months
gatein SVN: r4247 - portal/trunk/examples/portlets/api.
by do-not-reply@jboss.org
Author: julien_viet
Date: 2010-09-20 02:00:10 -0400 (Mon, 20 Sep 2010)
New Revision: 4247
Modified:
portal/trunk/examples/portlets/api/
Log:
ignore target and *.iml
Property changes on: portal/trunk/examples/portlets/api
___________________________________________________________________
Name: svn:ignore
+ target
*.iml
14 years, 3 months
gatein SVN: r4246 - portal/trunk/testsuite/selenium-snifftests/src/suite/org/exoplatform/portal/selenium.
by do-not-reply@jboss.org
Author: hangnguyen
Date: 2010-09-20 00:35:05 -0400 (Mon, 20 Sep 2010)
New Revision: 4246
Modified:
portal/trunk/testsuite/selenium-snifftests/src/suite/org/exoplatform/portal/selenium/Test_PRL_01_017_CreateNewAccountWhenFirstNameStartsWithNumber.html
portal/trunk/testsuite/selenium-snifftests/src/suite/org/exoplatform/portal/selenium/Test_PRL_01_018_CreateNewAccountWhenLastNameStartWithNumber.html
portal/trunk/testsuite/selenium-snifftests/src/suite/org/exoplatform/portal/selenium/Test_PRL_01_019_CreateNewAccoutFirstNameStartsWithUnderscoreDashDot.html
portal/trunk/testsuite/selenium-snifftests/src/suite/org/exoplatform/portal/selenium/Test_PRL_01_020_CreateNewAccoutFirstNameStartsWithUnderscoreDashDot.html
portal/trunk/testsuite/selenium-snifftests/src/suite/org/exoplatform/portal/selenium/Test_PRL_01_021_CreateNewAccountWithFirstLastNameIncludesSpecialCharacters.html
Log:
TestVN-356:Clean and Improve existing Selenium for GateIn
Modified: portal/trunk/testsuite/selenium-snifftests/src/suite/org/exoplatform/portal/selenium/Test_PRL_01_017_CreateNewAccountWhenFirstNameStartsWithNumber.html
===================================================================
--- portal/trunk/testsuite/selenium-snifftests/src/suite/org/exoplatform/portal/selenium/Test_PRL_01_017_CreateNewAccountWhenFirstNameStartsWithNumber.html 2010-09-20 03:32:03 UTC (rev 4245)
+++ portal/trunk/testsuite/selenium-snifftests/src/suite/org/exoplatform/portal/selenium/Test_PRL_01_017_CreateNewAccountWhenFirstNameStartsWithNumber.html 2010-09-20 04:35:05 UTC (rev 4246)
@@ -97,7 +97,32 @@
<td>Test_PRL_01_017(a)gmail.com</td>
</tr>
<tr>
+ <td>echo</td>
+ <td>-- Choose user Profile --</td>
+ <td></td>
+</tr>
+<tr>
<td>waitForElementPresent</td>
+ <td>//div[@id='UIAccountPortlet']/div[1]/div/div/div/div/div/div/div/div/div[2]/div/div/div/div</td>
+ <td></td>
+</tr>
+<tr>
+ <td>click</td>
+ <td>//div[@id='UIAccountPortlet']/div[1]/div/div/div/div/div/div/div/div/div[2]/div/div/div/div</td>
+ <td></td>
+</tr>
+<tr>
+ <td>waitForElementPresent</td>
+ <td>user.language</td>
+ <td></td>
+</tr>
+<tr>
+ <td>select</td>
+ <td>user.language</td>
+ <td>label=German</td>
+</tr>
+<tr>
+ <td>waitForElementPresent</td>
<td>link=Save</td>
<td></td>
</tr>
@@ -183,7 +208,7 @@
</tr>
<tr>
<td>clickAndWait</td>
- <td>link=Sign out</td>
+ <td>link=Abmelden</td>
<td></td>
</tr>
<tr>
@@ -307,14 +332,14 @@
<td></td>
</tr>
<tr>
- <td>clickAndWait</td>
+ <td>waitForElementPresent</td>
<td>link=Sign out</td>
<td></td>
</tr>
<tr>
- <td>close</td>
+ <td>clickAndWait</td>
+ <td>link=Sign out</td>
<td></td>
- <td></td>
</tr>
</tbody></table>
Modified: portal/trunk/testsuite/selenium-snifftests/src/suite/org/exoplatform/portal/selenium/Test_PRL_01_018_CreateNewAccountWhenLastNameStartWithNumber.html
===================================================================
--- portal/trunk/testsuite/selenium-snifftests/src/suite/org/exoplatform/portal/selenium/Test_PRL_01_018_CreateNewAccountWhenLastNameStartWithNumber.html 2010-09-20 03:32:03 UTC (rev 4245)
+++ portal/trunk/testsuite/selenium-snifftests/src/suite/org/exoplatform/portal/selenium/Test_PRL_01_018_CreateNewAccountWhenLastNameStartWithNumber.html 2010-09-20 04:35:05 UTC (rev 4246)
@@ -4,12 +4,12 @@
<head profile="http://selenium-ide.openqa.org/profiles/test-case">
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<link rel="selenium.base" href="" />
-<title>Test_PRL_018_CreateNewAccountWhenLastNameStartWithNumber</title>
+<title>Test_PRL_01_018_CreateNewAccountWhenLastNameStartWithNumber</title>
</head>
<body>
<table cellpadding="1" cellspacing="1" border="1">
<thead>
-<tr><td rowspan="1" colspan="3">Test_PRL_018_CreateNewAccountWhenLastNameStartWithNumber</td></tr>
+<tr><td rowspan="1" colspan="3">Test_PRL_01_018_CreateNewAccountWhenLastNameStartWithNumber</td></tr>
</thead><tbody>
<tr>
<td>open</td>
@@ -97,7 +97,32 @@
<td>Test_PRL_01_018(a)gmail.com</td>
</tr>
<tr>
+ <td>echo</td>
+ <td>-- Choose User Profile --</td>
+ <td></td>
+</tr>
+<tr>
<td>waitForElementPresent</td>
+ <td>//div[@id='UIAccountPortlet']/div[1]/div/div/div/div/div/div/div/div/div[2]/div/div/div/div</td>
+ <td></td>
+</tr>
+<tr>
+ <td>click</td>
+ <td>//div[@id='UIAccountPortlet']/div[1]/div/div/div/div/div/div/div/div/div[2]/div/div/div/div</td>
+ <td></td>
+</tr>
+<tr>
+ <td>waitForElementPresent</td>
+ <td>user.language</td>
+ <td></td>
+</tr>
+<tr>
+ <td>select</td>
+ <td>user.language</td>
+ <td>label=French</td>
+</tr>
+<tr>
+ <td>waitForElementPresent</td>
<td>link=Save</td>
<td></td>
</tr>
@@ -183,7 +208,7 @@
</tr>
<tr>
<td>clickAndWait</td>
- <td>link=Sign out</td>
+ <td>link=Déconnexion</td>
<td></td>
</tr>
<tr>
@@ -307,14 +332,14 @@
<td></td>
</tr>
<tr>
- <td>clickAndWait</td>
+ <td>waitForElementPresent</td>
<td>link=Sign out</td>
<td></td>
</tr>
<tr>
- <td>close</td>
+ <td>clickAndWait</td>
+ <td>link=Sign out</td>
<td></td>
- <td></td>
</tr>
</tbody></table>
Modified: portal/trunk/testsuite/selenium-snifftests/src/suite/org/exoplatform/portal/selenium/Test_PRL_01_019_CreateNewAccoutFirstNameStartsWithUnderscoreDashDot.html
===================================================================
--- portal/trunk/testsuite/selenium-snifftests/src/suite/org/exoplatform/portal/selenium/Test_PRL_01_019_CreateNewAccoutFirstNameStartsWithUnderscoreDashDot.html 2010-09-20 03:32:03 UTC (rev 4245)
+++ portal/trunk/testsuite/selenium-snifftests/src/suite/org/exoplatform/portal/selenium/Test_PRL_01_019_CreateNewAccoutFirstNameStartsWithUnderscoreDashDot.html 2010-09-20 04:35:05 UTC (rev 4246)
@@ -102,6 +102,11 @@
<td></td>
</tr>
<tr>
+ <td>waitForElementPresent</td>
+ <td>//div[@id='UIAccountPortlet']/div[1]/div/div/div/div/div/div/div/div/div[2]/div/div/div/div</td>
+ <td></td>
+</tr>
+<tr>
<td>click</td>
<td>//div[@id='UIAccountPortlet']/div[1]/div/div/div/div/div/div/div/div/div[2]/div/div/div/div</td>
<td></td>
@@ -114,7 +119,7 @@
<tr>
<td>select</td>
<td>user.language</td>
- <td>label=Portuguese (Brazil) (Brazil)</td>
+ <td>label=Portuguese (Brazil)</td>
</tr>
<tr>
<td>waitForElementPresent</td>
@@ -317,14 +322,14 @@
<td></td>
</tr>
<tr>
- <td>clickAndWait</td>
+ <td>waitForElementPresent</td>
<td>link=Sign out</td>
<td></td>
</tr>
<tr>
- <td>close</td>
+ <td>clickAndWait</td>
+ <td>link=Sign out</td>
<td></td>
- <td></td>
</tr>
</tbody></table>
Modified: portal/trunk/testsuite/selenium-snifftests/src/suite/org/exoplatform/portal/selenium/Test_PRL_01_020_CreateNewAccoutFirstNameStartsWithUnderscoreDashDot.html
===================================================================
--- portal/trunk/testsuite/selenium-snifftests/src/suite/org/exoplatform/portal/selenium/Test_PRL_01_020_CreateNewAccoutFirstNameStartsWithUnderscoreDashDot.html 2010-09-20 03:32:03 UTC (rev 4245)
+++ portal/trunk/testsuite/selenium-snifftests/src/suite/org/exoplatform/portal/selenium/Test_PRL_01_020_CreateNewAccoutFirstNameStartsWithUnderscoreDashDot.html 2010-09-20 04:35:05 UTC (rev 4246)
@@ -114,7 +114,7 @@
<tr>
<td>select</td>
<td>user.language</td>
- <td>label=Portuguese (Brazil) (Brazil)</td>
+ <td>label=Portuguese (Brazil)</td>
</tr>
<tr>
<td>waitForElementPresent</td>
@@ -321,11 +321,6 @@
<td>link=Sign out</td>
<td></td>
</tr>
-<tr>
- <td>close</td>
- <td></td>
- <td></td>
-</tr>
</tbody></table>
</body>
Modified: portal/trunk/testsuite/selenium-snifftests/src/suite/org/exoplatform/portal/selenium/Test_PRL_01_021_CreateNewAccountWithFirstLastNameIncludesSpecialCharacters.html
===================================================================
--- portal/trunk/testsuite/selenium-snifftests/src/suite/org/exoplatform/portal/selenium/Test_PRL_01_021_CreateNewAccountWithFirstLastNameIncludesSpecialCharacters.html 2010-09-20 03:32:03 UTC (rev 4245)
+++ portal/trunk/testsuite/selenium-snifftests/src/suite/org/exoplatform/portal/selenium/Test_PRL_01_021_CreateNewAccountWithFirstLastNameIncludesSpecialCharacters.html 2010-09-20 04:35:05 UTC (rev 4246)
@@ -97,7 +97,32 @@
<td>Test_PRL_01_021(a)gmail.com</td>
</tr>
<tr>
+ <td>echo</td>
+ <td>-- Choose User Profile --</td>
+ <td></td>
+</tr>
+<tr>
<td>waitForElementPresent</td>
+ <td>//div[@id='UIAccountPortlet']/div[1]/div/div/div/div/div/div/div/div/div[2]/div/div/div/div</td>
+ <td></td>
+</tr>
+<tr>
+ <td>click</td>
+ <td>//div[@id='UIAccountPortlet']/div[1]/div/div/div/div/div/div/div/div/div[2]/div/div/div/div</td>
+ <td></td>
+</tr>
+<tr>
+ <td>waitForElementPresent</td>
+ <td>user.language</td>
+ <td></td>
+</tr>
+<tr>
+ <td>select</td>
+ <td>user.language</td>
+ <td>label=Ukrainian</td>
+</tr>
+<tr>
+ <td>waitForElementPresent</td>
<td>link=Save</td>
<td></td>
</tr>
@@ -178,7 +203,7 @@
</tr>
<tr>
<td>clickAndWait</td>
- <td>link=Sign out</td>
+ <td>link=Вийти</td>
<td></td>
</tr>
<tr>
@@ -301,11 +326,6 @@
<td>link=Sign out</td>
<td></td>
</tr>
-<tr>
- <td>close</td>
- <td></td>
- <td></td>
-</tr>
</tbody></table>
</body>
14 years, 3 months
gatein SVN: r4245 - portal/trunk/testsuite/selenium-snifftests/src/suite/org/exoplatform/portal/selenium/NewSnifftest.
by do-not-reply@jboss.org
Author: hangnguyen
Date: 2010-09-19 23:32:03 -0400 (Sun, 19 Sep 2010)
New Revision: 4245
Modified:
portal/trunk/testsuite/selenium-snifftests/src/suite/org/exoplatform/portal/selenium/NewSnifftest/Test_SNF_PRL_41_ChangeSiteConfigWhenEditlayOutForGroupPage.html
Log:
TestVN-356:Clean and Improve existing Selenium for GateIn
Modified: portal/trunk/testsuite/selenium-snifftests/src/suite/org/exoplatform/portal/selenium/NewSnifftest/Test_SNF_PRL_41_ChangeSiteConfigWhenEditlayOutForGroupPage.html
===================================================================
--- portal/trunk/testsuite/selenium-snifftests/src/suite/org/exoplatform/portal/selenium/NewSnifftest/Test_SNF_PRL_41_ChangeSiteConfigWhenEditlayOutForGroupPage.html 2010-09-19 18:58:58 UTC (rev 4244)
+++ portal/trunk/testsuite/selenium-snifftests/src/suite/org/exoplatform/portal/selenium/NewSnifftest/Test_SNF_PRL_41_ChangeSiteConfigWhenEditlayOutForGroupPage.html 2010-09-20 03:32:03 UTC (rev 4245)
@@ -352,6 +352,11 @@
<td></td>
</tr>
<tr>
+ <td>waitForElementPresent</td>
+ <td>//a[@class='NodeIcon DefaultPageIcon' and @title='Test_SNF_PRL_41']</td>
+ <td></td>
+</tr>
+<tr>
<td>mouseDownRight</td>
<td>//a[@class='NodeIcon DefaultPageIcon' and @title='Test_SNF_PRL_41']</td>
<td></td>
14 years, 3 months
gatein SVN: r4244 - portal/trunk/component/application-registry/src/main/java/org/exoplatform/application/registry/impl.
by do-not-reply@jboss.org
Author: chris.laprun(a)jboss.com
Date: 2010-09-19 14:58:58 -0400 (Sun, 19 Sep 2010)
New Revision: 4244
Modified:
portal/trunk/component/application-registry/src/main/java/org/exoplatform/application/registry/impl/ApplicationRegistryServiceImpl.java
Log:
- JBEPP-470: account for the fact that there might be a beginning slash in portlet application name (this is the case with WSRP).
Modified: portal/trunk/component/application-registry/src/main/java/org/exoplatform/application/registry/impl/ApplicationRegistryServiceImpl.java
===================================================================
--- portal/trunk/component/application-registry/src/main/java/org/exoplatform/application/registry/impl/ApplicationRegistryServiceImpl.java 2010-09-19 12:35:50 UTC (rev 4243)
+++ portal/trunk/component/application-registry/src/main/java/org/exoplatform/application/registry/impl/ApplicationRegistryServiceImpl.java 2010-09-19 18:58:58 UTC (rev 4244)
@@ -253,7 +253,17 @@
{
throw new Exception("Invalid Application Id: [" + id + "]");
}
- return getApplication(fragments[0], fragments[1]);
+
+ String category = fragments[0];
+ String applicationName = fragments[1];
+
+ // If the application name contained a beginning slash (which can happen with WSRP), we need to hack around the
+ // hardcoding of portlet id expectations >_<
+ if(fragments.length == 3 && applicationName.length() == 0)
+ {
+ applicationName = "/" + fragments[2];
+ }
+ return getApplication(category, applicationName);
}
public Application getApplication(final String category, final String name) throws Exception
14 years, 3 months
gatein SVN: r4243 - in portal/trunk/webui/portal/src/main/java: org/exoplatform/portal/application/state and 1 other directory.
by do-not-reply@jboss.org
Author: julien_viet
Date: 2010-09-19 08:35:50 -0400 (Sun, 19 Sep 2010)
New Revision: 4243
Modified:
portal/trunk/webui/portal/src/main/java/conf/portal/configuration.xml
portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/application/state/AbstractContextualPropertyProviderPlugin.java
portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/application/state/InternalPropertiesPlugin.java
portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/application/state/PublicPropertiesPlugin.java
Log:
GTNPORTAL-1398: actually no need to bother with a QName prefix
Modified: portal/trunk/webui/portal/src/main/java/conf/portal/configuration.xml
===================================================================
--- portal/trunk/webui/portal/src/main/java/conf/portal/configuration.xml 2010-09-19 11:53:07 UTC (rev 4242)
+++ portal/trunk/webui/portal/src/main/java/conf/portal/configuration.xml 2010-09-19 12:35:50 UTC (rev 4243)
@@ -52,11 +52,6 @@
<description>Namespace URI</description>
<value>http://www.gatein.org/xml/ns/prp_1_0</value>
</value-param>
- <value-param>
- <name>prefix</name>
- <description>Prefix of QName</description>
- <value>prp</value>
- </value-param>
</init-params>
</component-plugin>
<component-plugin>
@@ -69,11 +64,6 @@
<description>Namespace URI</description>
<value>http://www.gatein.org/xml/ns/internal_prp_1_0</value>
</value-param>
- <value-param>
- <name>prefix</name>
- <description>Prefix of QName</description>
- <value>iprp</value>
- </value-param>
</init-params>
</component-plugin>
</component-plugins>
Modified: portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/application/state/AbstractContextualPropertyProviderPlugin.java
===================================================================
--- portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/application/state/AbstractContextualPropertyProviderPlugin.java 2010-09-19 11:53:07 UTC (rev 4242)
+++ portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/application/state/AbstractContextualPropertyProviderPlugin.java 2010-09-19 12:35:50 UTC (rev 4243)
@@ -40,13 +40,9 @@
/** . */
protected final String namespaceURI;
- /** . */
- protected final String prefix;
-
protected AbstractContextualPropertyProviderPlugin(InitParams params)
{
this.namespaceURI = params.getValueParam("namespaceURI").getValue();
- this.prefix = params.getValueParam("prefix").getValue();
}
public abstract void getProperties(UIPortlet portletWindow, Map<QName, String[]> properties);
Modified: portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/application/state/InternalPropertiesPlugin.java
===================================================================
--- portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/application/state/InternalPropertiesPlugin.java 2010-09-19 11:53:07 UTC (rev 4242)
+++ portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/application/state/InternalPropertiesPlugin.java 2010-09-19 12:35:50 UTC (rev 4243)
@@ -46,8 +46,8 @@
super(params);
//
- this.storageIdQName = new QName(namespaceURI, "storage_id", prefix);
- this.storageNameQName = new QName(namespaceURI, "storage_name", prefix);
+ this.storageIdQName = new QName(namespaceURI, "storage_id");
+ this.storageNameQName = new QName(namespaceURI, "storage_name");
}
@Override
Modified: portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/application/state/PublicPropertiesPlugin.java
===================================================================
--- portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/application/state/PublicPropertiesPlugin.java 2010-09-19 11:53:07 UTC (rev 4242)
+++ portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/application/state/PublicPropertiesPlugin.java 2010-09-19 12:35:50 UTC (rev 4243)
@@ -64,13 +64,13 @@
super(params);
//
- this.navigationURIQName = new QName(namespaceURI, "navigation_uri", prefix);
- this.pageNameQName = new QName(namespaceURI, "page_name", prefix);
- this.siteTypeQName = new QName(namespaceURI, "site_type", prefix);
- this.siteNameQName = new QName(namespaceURI, "site_name", prefix);
- this.windowWidth = new QName(namespaceURI, "window_width", prefix);
- this.windowHeight = new QName(namespaceURI, "window_height", prefix);
- this.windowShowInfoBarQName = new QName(namespaceURI, "window_show_info_bar", prefix);
+ this.navigationURIQName = new QName(namespaceURI, "navigation_uri");
+ this.pageNameQName = new QName(namespaceURI, "page_name");
+ this.siteTypeQName = new QName(namespaceURI, "site_type");
+ this.siteNameQName = new QName(namespaceURI, "site_name");
+ this.windowWidth = new QName(namespaceURI, "window_width");
+ this.windowHeight = new QName(namespaceURI, "window_height");
+ this.windowShowInfoBarQName = new QName(namespaceURI, "window_show_info_bar");
}
@Override
14 years, 3 months
gatein SVN: r4242 - in portal/trunk: examples/portlets/api and 13 other directories.
by do-not-reply@jboss.org
Author: julien_viet
Date: 2010-09-19 07:53:07 -0400 (Sun, 19 Sep 2010)
New Revision: 4242
Added:
portal/trunk/examples/portlets/api/
portal/trunk/examples/portlets/api/pom.xml
portal/trunk/examples/portlets/api/src/
portal/trunk/examples/portlets/api/src/main/
portal/trunk/examples/portlets/api/src/main/java/
portal/trunk/examples/portlets/api/src/main/java/org/
portal/trunk/examples/portlets/api/src/main/java/org/gatein/
portal/trunk/examples/portlets/api/src/main/java/org/gatein/portal/
portal/trunk/examples/portlets/api/src/main/java/org/gatein/portal/samples/
portal/trunk/examples/portlets/api/src/main/java/org/gatein/portal/samples/api/
portal/trunk/examples/portlets/api/src/main/java/org/gatein/portal/samples/api/PRPPortlet.java
portal/trunk/examples/portlets/api/src/main/resources/
portal/trunk/examples/portlets/api/src/main/webapp/
portal/trunk/examples/portlets/api/src/main/webapp/WEB-INF/
portal/trunk/examples/portlets/api/src/main/webapp/WEB-INF/portlet.xml
portal/trunk/examples/portlets/api/src/main/webapp/WEB-INF/web.xml
portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/application/state/InternalPropertiesPlugin.java
portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/application/state/PublicPropertiesPlugin.java
Removed:
portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/application/state/NavigationalStateProviderPlugin.java
Modified:
portal/trunk/examples/portlets/pom.xml
portal/trunk/webui/portal/src/main/java/conf/portal/configuration.xml
portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/application/state/AbstractContextualPropertyProviderPlugin.java
portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/application/state/ContextualPropertyManager.java
portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/application/state/ContextualPropertyManagerImpl.java
portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/webui/application/UIPortlet.java
Log:
GTNPORTAL-1484: GateIn PRP API Sample
GTNPORTAL-1398: Portal navigational properties based on JSR-286 / fix a bug where the local name of the PRP definition qname was used instead of the PRP definition identifier
Added: portal/trunk/examples/portlets/api/pom.xml
===================================================================
--- portal/trunk/examples/portlets/api/pom.xml (rev 0)
+++ portal/trunk/examples/portlets/api/pom.xml 2010-09-19 11:53:07 UTC (rev 4242)
@@ -0,0 +1,39 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<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">
+ <modelVersion>4.0.0</modelVersion>
+
+ <!--
+ the parent isn't required, you can drop it if you add a groupId
+ and version
+ -->
+ <parent>
+ <groupId>org.gatein.portal.examples.portlets</groupId>
+ <artifactId>parent</artifactId>
+ <version>3.2.0-Beta01-SNAPSHOT</version>
+ </parent>
+
+ <artifactId>gatein-api</artifactId>
+ <packaging>war</packaging>
+ <name>GateIn Portal Examples - GateIn API</name>
+
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-compiler-plugin</artifactId>
+ <configuration>
+ <source>1.5</source>
+ <target>1.5</target>
+ </configuration>
+ </plugin>
+ </plugins>
+ </build>
+
+ <dependencies>
+ <dependency>
+ <groupId>javax.portlet</groupId>
+ <artifactId>portlet-api</artifactId>
+ <scope>provided</scope>
+ </dependency>
+ </dependencies>
+</project>
\ No newline at end of file
Added: portal/trunk/examples/portlets/api/src/main/java/org/gatein/portal/samples/api/PRPPortlet.java
===================================================================
--- portal/trunk/examples/portlets/api/src/main/java/org/gatein/portal/samples/api/PRPPortlet.java (rev 0)
+++ portal/trunk/examples/portlets/api/src/main/java/org/gatein/portal/samples/api/PRPPortlet.java 2010-09-19 11:53:07 UTC (rev 4242)
@@ -0,0 +1,62 @@
+/*
+ * Copyright (C) 2010 eXo Platform SAS.
+ *
+ * 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.gatein.portal.samples.api;
+
+import javax.portlet.GenericPortlet;
+import javax.portlet.PortletException;
+import javax.portlet.RenderRequest;
+import javax.portlet.RenderResponse;
+import java.io.IOException;
+import java.io.PrintWriter;
+import java.util.Map;
+
+/**
+ * @author <a href="mailto:julien.viet@exoplatform.com">Julien Viet</a>
+ * @version $Revision$
+ */
+public class PRPPortlet extends GenericPortlet
+{
+
+ @Override
+ protected void doView(RenderRequest req, RenderResponse resp) throws PortletException, IOException
+ {
+ resp.setContentType("text/html");
+ PrintWriter writer = resp.getWriter();
+
+ //
+ writer.println("Public Render Parameters<br/>");
+ writer.println("<table>");
+ for (Map.Entry<String, String[]> entry : req.getParameterMap().entrySet())
+ {
+ writer.print("<tr>");
+ writer.print("<td>");
+ writer.print(entry.getKey());
+ writer.print("</td>");
+ writer.print("<td>");
+ writer.print(entry.getValue()[0]);
+ writer.print("</td>");
+ writer.print("</tr>");
+ }
+ writer.println("</table>");
+
+ //
+ writer.close();
+ }
+}
Added: portal/trunk/examples/portlets/api/src/main/webapp/WEB-INF/portlet.xml
===================================================================
--- portal/trunk/examples/portlets/api/src/main/webapp/WEB-INF/portlet.xml (rev 0)
+++ portal/trunk/examples/portlets/api/src/main/webapp/WEB-INF/portlet.xml 2010-09-19 11:53:07 UTC (rev 4242)
@@ -0,0 +1,87 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+
+ Copyright (C) 2009 eXo Platform SAS.
+
+ 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 version="1.0" 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">
+ -->
+
+ <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="1.0">
+
+ <portlet>
+ <description xml:lang="EN">Public Render Parameter API Portlet</description>
+ <portlet-name>PRPAPIPortlet</portlet-name>
+ <display-name xml:lang="EN">Public Render Parameter API Portlet</display-name>
+ <portlet-class>org.gatein.portal.samples.api.PRPPortlet</portlet-class>
+
+ <supports>
+ <mime-type>text/html</mime-type>
+ </supports>
+
+ <portlet-info>
+ <title>PRP Portlet</title>
+ <short-title>PRP Portlet</short-title>
+ <keywords>Sample</keywords>
+ </portlet-info>
+
+ <supported-public-render-parameter>navigation_uri</supported-public-render-parameter>
+ <supported-public-render-parameter>page_name</supported-public-render-parameter>
+ <supported-public-render-parameter>site_type</supported-public-render-parameter>
+ <supported-public-render-parameter>site_name</supported-public-render-parameter>
+ <supported-public-render-parameter>window_width</supported-public-render-parameter>
+ <supported-public-render-parameter>window_height</supported-public-render-parameter>
+ <supported-public-render-parameter>window_show_info_bar</supported-public-render-parameter>
+
+ </portlet>
+
+ <public-render-parameter>
+ <identifier>navigation_uri</identifier>
+ <qname xmlns:prp='http://www.gatein.org/xml/ns/prp_1_0'>prp:navigation_uri</qname>
+ </public-render-parameter>
+ <public-render-parameter>
+ <identifier>page_name</identifier>
+ <qname xmlns:prp='http://www.gatein.org/xml/ns/prp_1_0'>prp:page_name</qname>
+ </public-render-parameter>
+ <public-render-parameter>
+ <identifier>site_type</identifier>
+ <qname xmlns:prp='http://www.gatein.org/xml/ns/prp_1_0'>prp:site_type</qname>
+ </public-render-parameter>
+ <public-render-parameter>
+ <identifier>site_name</identifier>
+ <qname xmlns:prp='http://www.gatein.org/xml/ns/prp_1_0'>prp:site_name</qname>
+ </public-render-parameter>
+ <public-render-parameter>
+ <identifier>window_width</identifier>
+ <qname xmlns:prp='http://www.gatein.org/xml/ns/prp_1_0'>prp:window_width</qname>
+ </public-render-parameter>
+ <public-render-parameter>
+ <identifier>window_height</identifier>
+ <qname xmlns:prp='http://www.gatein.org/xml/ns/prp_1_0'>prp:window_height</qname>
+ </public-render-parameter>
+ <public-render-parameter>
+ <identifier>window_show_info_bar</identifier>
+ <qname xmlns:prp='http://www.gatein.org/xml/ns/prp_1_0'>prp:window_show_info_bar</qname>
+ </public-render-parameter>
+
+</portlet-app>
Added: portal/trunk/examples/portlets/api/src/main/webapp/WEB-INF/web.xml
===================================================================
--- portal/trunk/examples/portlets/api/src/main/webapp/WEB-INF/web.xml (rev 0)
+++ portal/trunk/examples/portlets/api/src/main/webapp/WEB-INF/web.xml 2010-09-19 11:53:07 UTC (rev 4242)
@@ -0,0 +1,16 @@
+<?xml version="1.0"?>
+<web-app 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.5">
+
+ <servlet>
+ <servlet-name>GateInServlet</servlet-name>
+ <servlet-class>org.gatein.wci.api.GateInServlet</servlet-class>
+ <load-on-startup>0</load-on-startup>
+ </servlet>
+ <servlet-mapping>
+ <servlet-name>GateInServlet</servlet-name>
+ <url-pattern>/gateinservlet</url-pattern>
+ </servlet-mapping>
+
+</web-app>
Modified: portal/trunk/examples/portlets/pom.xml
===================================================================
--- portal/trunk/examples/portlets/pom.xml 2010-09-17 14:42:13 UTC (rev 4241)
+++ portal/trunk/examples/portlets/pom.xml 2010-09-19 11:53:07 UTC (rev 4242)
@@ -14,6 +14,7 @@
<name>GateIn Portal Examples - Portlets</name>
<modules>
+ <module>api</module>
<module>jsfhellouser</module>
<module>jsphellouser</module>
<module>simplesthelloworld</module>
Modified: portal/trunk/webui/portal/src/main/java/conf/portal/configuration.xml
===================================================================
--- portal/trunk/webui/portal/src/main/java/conf/portal/configuration.xml 2010-09-17 14:42:13 UTC (rev 4241)
+++ portal/trunk/webui/portal/src/main/java/conf/portal/configuration.xml 2010-09-19 11:53:07 UTC (rev 4242)
@@ -43,22 +43,39 @@
<type>org.exoplatform.portal.application.state.ContextualPropertyManagerImpl</type>
<component-plugins>
<component-plugin>
- <name>NavigationalStateProviderPlugin</name>
+ <name>PublicPropertiesPlugin</name>
<set-method>addPlugin</set-method>
- <type>org.exoplatform.portal.application.state.NavigationalStateProviderPlugin</type>
+ <type>org.exoplatform.portal.application.state.PublicPropertiesPlugin</type>
<init-params>
<value-param>
<name>namespaceURI</name>
<description>Namespace URI</description>
- <value>http://www.gatein.org</value>
+ <value>http://www.gatein.org/xml/ns/prp_1_0</value>
</value-param>
<value-param>
<name>prefix</name>
<description>Prefix of QName</description>
- <value>gtn</value>
+ <value>prp</value>
</value-param>
</init-params>
</component-plugin>
+ <component-plugin>
+ <name>InternalPropertiesPlugin</name>
+ <set-method>addPlugin</set-method>
+ <type>org.exoplatform.portal.application.state.InternalPropertiesPlugin</type>
+ <init-params>
+ <value-param>
+ <name>namespaceURI</name>
+ <description>Namespace URI</description>
+ <value>http://www.gatein.org/xml/ns/internal_prp_1_0</value>
+ </value-param>
+ <value-param>
+ <name>prefix</name>
+ <description>Prefix of QName</description>
+ <value>iprp</value>
+ </value-param>
+ </init-params>
+ </component-plugin>
</component-plugins>
</component>
</configuration>
Modified: portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/application/state/AbstractContextualPropertyProviderPlugin.java
===================================================================
--- portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/application/state/AbstractContextualPropertyProviderPlugin.java 2010-09-17 14:42:13 UTC (rev 4241)
+++ portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/application/state/AbstractContextualPropertyProviderPlugin.java 2010-09-19 11:53:07 UTC (rev 4242)
@@ -23,16 +23,39 @@
import javax.xml.namespace.QName;
import org.exoplatform.container.component.BaseComponentPlugin;
+import org.exoplatform.container.xml.InitParams;
import org.exoplatform.portal.webui.application.UIPortlet;
+import org.gatein.common.logging.Logger;
+import org.gatein.common.logging.LoggerFactory;
/**
* @author <a href="mailto:hoang281283@gmail.com">Minh Hoang TO</a>
- * @date
*/
-
public abstract class AbstractContextualPropertyProviderPlugin extends BaseComponentPlugin
{
- public abstract Map<QName, String[]> getProperties(UIPortlet portletWindow);
+ /** . */
+ protected final Logger log = LoggerFactory.getLogger(getClass());
+ /** . */
+ protected final String namespaceURI;
+
+ /** . */
+ protected final String prefix;
+
+ protected AbstractContextualPropertyProviderPlugin(InitParams params)
+ {
+ this.namespaceURI = params.getValueParam("namespaceURI").getValue();
+ this.prefix = params.getValueParam("prefix").getValue();
+ }
+
+ public abstract void getProperties(UIPortlet portletWindow, Map<QName, String[]> properties);
+
+ protected final void addProperty(Map<QName, String[]> map, QName qname, String value)
+ {
+ if (value != null)
+ {
+ map.put(qname, new String[]{value});
+ }
+ }
}
Modified: portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/application/state/ContextualPropertyManager.java
===================================================================
--- portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/application/state/ContextualPropertyManager.java 2010-09-17 14:42:13 UTC (rev 4241)
+++ portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/application/state/ContextualPropertyManager.java 2010-09-19 11:53:07 UTC (rev 4242)
@@ -23,16 +23,19 @@
import javax.xml.namespace.QName;
import org.exoplatform.portal.webui.application.UIPortlet;
-import org.picocontainer.Startable;
/**
* @author <a href="mailto:hoang281283@gmail.com">Minh Hoang TO</a>
- * @date
*/
-
-public interface ContextualPropertyManager extends Startable
+public interface ContextualPropertyManager
{
+ /**
+ * Returns a map of qualified names and string values for contextual properties of the portlet.
+ *
+ * @param portletWindow the portlet
+ * @return the contextual properties
+ */
public Map<QName, String[]> getProperties(UIPortlet portletWindow);
}
Modified: portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/application/state/ContextualPropertyManagerImpl.java
===================================================================
--- portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/application/state/ContextualPropertyManagerImpl.java 2010-09-17 14:42:13 UTC (rev 4241)
+++ portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/application/state/ContextualPropertyManagerImpl.java 2010-09-19 11:53:07 UTC (rev 4242)
@@ -27,41 +27,42 @@
import org.exoplatform.container.component.ComponentPlugin;
import org.exoplatform.portal.webui.application.UIPortlet;
+import org.picocontainer.Startable;
/**
* @author <a href="mailto:hoang281283@gmail.com">Minh Hoang TO</a>
* @date
*/
-public class ContextualPropertyManagerImpl implements ContextualPropertyManager
+public class ContextualPropertyManagerImpl implements ContextualPropertyManager, Startable
{
- private List<AbstractContextualPropertyProviderPlugin> propertyProviderPlugins;
+ private ArrayList<AbstractContextualPropertyProviderPlugin> propertyProviderPlugins;
public ContextualPropertyManagerImpl() throws Exception
{
propertyProviderPlugins = new ArrayList<AbstractContextualPropertyProviderPlugin>();
}
- @Override
public Map<QName, String[]> getProperties(UIPortlet portletWindow)
{
Map<QName, String[]> whatPortletWindowSee = new HashMap<QName, String[]>();
-
- for(AbstractContextualPropertyProviderPlugin plugin : propertyProviderPlugins)
+
+ // No need to use an iterator here
+ for (int i = 0;i < propertyProviderPlugins.size();i++)
{
- whatPortletWindowSee.putAll(plugin.getProperties(portletWindow));
+ AbstractContextualPropertyProviderPlugin plugin = propertyProviderPlugins.get(i);
+ plugin.getProperties(portletWindow, whatPortletWindowSee);
}
-
+
+ //
return whatPortletWindowSee;
}
- @Override
public void start()
{
}
- @Override
public void stop()
{
}
@@ -73,5 +74,4 @@
propertyProviderPlugins.add((AbstractContextualPropertyProviderPlugin)plugin);
}
}
-
}
Added: portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/application/state/InternalPropertiesPlugin.java
===================================================================
--- portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/application/state/InternalPropertiesPlugin.java (rev 0)
+++ portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/application/state/InternalPropertiesPlugin.java 2010-09-19 11:53:07 UTC (rev 4242)
@@ -0,0 +1,59 @@
+/*
+ * Copyright (C) 2010 eXo Platform SAS.
+ *
+ * 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.exoplatform.portal.application.state;
+
+import org.exoplatform.container.xml.InitParams;
+import org.exoplatform.portal.webui.application.UIPortlet;
+
+import javax.xml.namespace.QName;
+import java.util.Map;
+
+/**
+ * This plugins setup properties that are NOT publicly supported, however it is recommanded to not change anything
+ * but there are no guarantees that it won't change.
+ *
+ * @author <a href="mailto:julien.viet@exoplatform.com">Julien Viet</a>
+ * @version $Revision$
+ */
+public class InternalPropertiesPlugin extends AbstractContextualPropertyProviderPlugin
+{
+
+ /** . */
+ private final QName storageIdQName;
+
+ /** . */
+ private final QName storageNameQName;
+
+ public InternalPropertiesPlugin(InitParams params)
+ {
+ super(params);
+
+ //
+ this.storageIdQName = new QName(namespaceURI, "storage_id", prefix);
+ this.storageNameQName = new QName(namespaceURI, "storage_name", prefix);
+ }
+
+ @Override
+ public void getProperties(UIPortlet portletWindow, Map<QName, String[]> properties)
+ {
+ addProperty(properties, storageIdQName, portletWindow.getStorageId());
+ addProperty(properties, storageNameQName, portletWindow.getStorageName());
+ }
+}
Deleted: portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/application/state/NavigationalStateProviderPlugin.java
===================================================================
--- portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/application/state/NavigationalStateProviderPlugin.java 2010-09-17 14:42:13 UTC (rev 4241)
+++ portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/application/state/NavigationalStateProviderPlugin.java 2010-09-19 11:53:07 UTC (rev 4242)
@@ -1,86 +0,0 @@
-/*
- * Copyright (C) 2009 eXo Platform SAS.
- *
- * 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.exoplatform.portal.application.state;
-
-import java.util.HashMap;
-import java.util.Map;
-
-import javax.xml.namespace.QName;
-
-import org.exoplatform.container.xml.InitParams;
-import org.exoplatform.portal.config.model.PageNode;
-import org.exoplatform.portal.webui.application.UIPortlet;
-import org.exoplatform.portal.webui.page.UIPage;
-import org.exoplatform.portal.webui.portal.UIPortal;
-import org.exoplatform.portal.webui.util.Util;
-
-/**
- * @author <a href="mailto:hoang281283@gmail.com">Minh Hoang TO</a>
- * @date
- */
-
-public class NavigationalStateProviderPlugin extends AbstractContextualPropertyProviderPlugin
-{
-
- private final String NAMESPACE_URI;
-
- private final String PREFIX;
-
- public NavigationalStateProviderPlugin(InitParams params) throws Exception
- {
- NAMESPACE_URI = params.getValueParam("namespaceURI").getValue();
- PREFIX = params.getValueParam("prefix").getValue();
- }
-
- @Override
- public Map<QName, String[]> getProperties(UIPortlet portletWindow)
- {
- Map<QName, String[]> whatThisPluginProvides = new HashMap<QName, String[]>();
-
- try
- {
- UIPortal currentSite = Util.getUIPortalApplication().getShowedUIPortal();
- PageNode currentNode = currentSite.getSelectedNode();
-
- //Provides current node URI
- whatThisPluginProvides.put(new QName(NAMESPACE_URI, "navigation_uri", PREFIX), new String[]{currentNode.getUri()});
-
- //Provides current page name
- UIPage currentPage = currentSite.getUIPage(currentNode.getPageReference());
- if(currentPage != null)
- {
- whatThisPluginProvides.put(new QName(NAMESPACE_URI, "page_name", PREFIX), new String[]{currentPage.getTitle()});
- }
-
- //Provides current site type
- whatThisPluginProvides.put(new QName(NAMESPACE_URI, "site_type", PREFIX), new String[]{currentSite.getOwnerType()});
-
- //Provides current site name
- whatThisPluginProvides.put(new QName(NAMESPACE_URI, "site_name", PREFIX), new String[]{currentSite.getOwner()});
-
- return whatThisPluginProvides;
- }
- catch (Exception ex)
- {
- ex.printStackTrace();
- return null;
- }
- }
-
-}
Copied: portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/application/state/PublicPropertiesPlugin.java (from rev 4221, portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/application/state/NavigationalStateProviderPlugin.java)
===================================================================
--- portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/application/state/PublicPropertiesPlugin.java (rev 0)
+++ portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/application/state/PublicPropertiesPlugin.java 2010-09-19 11:53:07 UTC (rev 4242)
@@ -0,0 +1,108 @@
+/*
+ * Copyright (C) 2009 eXo Platform SAS.
+ *
+ * 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.exoplatform.portal.application.state;
+
+import java.util.Map;
+
+import javax.xml.namespace.QName;
+
+import org.exoplatform.container.xml.InitParams;
+import org.exoplatform.portal.config.model.PageNode;
+import org.exoplatform.portal.webui.application.UIPortlet;
+import org.exoplatform.portal.webui.page.UIPage;
+import org.exoplatform.portal.webui.portal.UIPortal;
+import org.exoplatform.portal.webui.util.Util;
+
+/**
+ * This plugin setup properties that are publicly supported, hence this is part of a public API
+ * and once published its contract must not change whatsoever.
+ *
+ * @author <a href="mailto:hoang281283@gmail.com">Minh Hoang TO</a>
+ */
+public class PublicPropertiesPlugin extends AbstractContextualPropertyProviderPlugin
+{
+
+ /** . */
+ private final QName navigationURIQName;
+
+ /** . */
+ private final QName pageNameQName;
+
+ /** . */
+ private final QName siteTypeQName;
+
+ /** . */
+ private final QName siteNameQName;
+
+ /** . */
+ private final QName windowShowInfoBarQName;
+
+ /** . */
+ private final QName windowHeight;
+
+ /** . */
+ private final QName windowWidth;
+
+ public PublicPropertiesPlugin(InitParams params) throws Exception
+ {
+ super(params);
+
+ //
+ this.navigationURIQName = new QName(namespaceURI, "navigation_uri", prefix);
+ this.pageNameQName = new QName(namespaceURI, "page_name", prefix);
+ this.siteTypeQName = new QName(namespaceURI, "site_type", prefix);
+ this.siteNameQName = new QName(namespaceURI, "site_name", prefix);
+ this.windowWidth = new QName(namespaceURI, "window_width", prefix);
+ this.windowHeight = new QName(namespaceURI, "window_height", prefix);
+ this.windowShowInfoBarQName = new QName(namespaceURI, "window_show_info_bar", prefix);
+ }
+
+ @Override
+ public void getProperties(UIPortlet portletWindow, Map<QName, String[]> properties)
+ {
+ try
+ {
+ UIPortal currentSite = Util.getUIPortalApplication().getShowedUIPortal();
+ PageNode currentNode = currentSite.getSelectedNode();
+
+ // Navigation related properties
+ addProperty(properties, navigationURIQName, currentNode.getUri());
+
+ // Page related properties
+ UIPage currentPage = currentSite.getUIPage(currentNode.getPageReference());
+ if(currentPage != null)
+ {
+ addProperty(properties, pageNameQName, currentPage.getTitle());
+ }
+
+ // Site related properties
+ addProperty(properties, siteTypeQName, currentSite.getOwnerType());
+ addProperty(properties, siteNameQName, currentSite.getOwner());
+
+ // Window related properties
+ addProperty(properties, windowShowInfoBarQName, Boolean.toString(portletWindow.getShowInfoBar()));
+ addProperty(properties, windowWidth, portletWindow.getWidth());
+ addProperty(properties, windowHeight, portletWindow.getHeight());
+ }
+ catch (Exception ex)
+ {
+ log.error("Could not obtain contextual properties for portlet " + portletWindow, ex);
+ }
+ }
+}
Modified: portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/webui/application/UIPortlet.java
===================================================================
--- portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/webui/application/UIPortlet.java 2010-09-17 14:42:13 UTC (rev 4241)
+++ portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/webui/application/UIPortlet.java 2010-09-19 11:53:07 UTC (rev 4242)
@@ -154,7 +154,7 @@
private List<QName> supportedPublishingEvents_;
- private List<String> supportedPublicParams_;
+ private Map<QName, String> supportedPublicParams_;
private boolean portletInPortal_ = true;
@@ -351,12 +351,37 @@
supportedProcessingEvents_ = supportedProcessingEvents;
}
- public List<String> getSupportedPublicRenderParameters()
+ public Map<QName, String> getSupportedPublicRenderParameters()
{
+ if (supportedPublicParams_ == null)
+ {
+ if (producedOfferedPortlet == null)
+ {
+ log.info("Could not find portlet with ID : " + producerOfferedPortletContext.getId());
+ return Collections.emptyMap();
+ }
+
+ //
+ Collection<ParameterInfo> parameters = (Collection<ParameterInfo>)producedOfferedPortlet.getInfo().getNavigation().getPublicParameters();
+ Map<QName, String> supportedPublicParams = Collections.emptyMap();
+ for (ParameterInfo parameter : parameters)
+ {
+ if (supportedPublicParams.isEmpty())
+ {
+ supportedPublicParams = new HashMap<QName, String>();
+ }
+ supportedPublicParams.put(parameter.getName(), parameter.getId());
+ }
+
+ //
+ this.supportedPublicParams_ = supportedPublicParams;
+ }
+
+ //
return supportedPublicParams_;
}
- public void setSupportedPublicRenderParameters(List<String> supportedPublicRenderParameters)
+ public void setSupportedPublicRenderParameters(Map<QName, String> supportedPublicRenderParameters)
{
supportedPublicParams_ = supportedPublicRenderParameters;
}
@@ -542,46 +567,35 @@
/**
* Tells, according to the info located in portlet.xml, wether this portlet supports the public render parameter
- * given as a method argument
+ * qname given as method argument. If the qname is supported, the public render parameter id is returned otherwise
+ * false is returned.
+ *
+ * @param supportedPublicParam the supported public parameter qname
+ * @return the supported public parameter id
*/
- public boolean supportsPublicParam(String supportedPublicParam)
+ public String supportsPublicParam(QName supportedPublicParam)
{
- if (supportedPublicParams_ == null)
- {
+ Map<QName, String> supportedPublicParams = getSupportedPublicRenderParameters();
+ return supportedPublicParams.get(supportedPublicParam);
+ }
- //
- if (producedOfferedPortlet == null)
- {
- log.info("Could not find portlet with ID : " + producerOfferedPortletContext.getId());
- return false;
- }
-
- //
- Collection<ParameterInfo> parameters =
- (Collection<ParameterInfo>)producedOfferedPortlet.getInfo().getNavigation().getPublicParameters();
- supportedPublicParams_ = new ArrayList<String>();
- for (ParameterInfo parameter : parameters)
- {
- supportedPublicParams_.add(parameter.getId());
- }
- }
-
- //
- for (String publicParam : supportedPublicParams_)
+ /**
+ * Tells, according to the info located in portlet.xml, wether this portlet supports the public render parameter
+ * id given as a method argument.
+ *
+ * @param supportedPublicParamId the supported public parameter id
+ * @return true if the supported public parameter id is supported
+ */
+ public boolean supportsPublicParam(String supportedPublicParamId)
+ {
+ Map<QName, String> supportedPublicParams = getSupportedPublicRenderParameters();
+ boolean supported = supportedPublicParams.containsValue(supportedPublicParamId);
+ if (supported && log.isDebugEnabled())
{
- if (publicParam.equals(supportedPublicParam))
- {
- if (log.isDebugEnabled())
- {
- log.debug("The Portlet " + producerOfferedPortletContext.getId()
- + " supports the public render parameter : " + supportedPublicParam);
- }
- return true;
- }
+ log.debug("The Portlet " + producerOfferedPortletContext.getId()
+ + " supports the public render parameter : " + supportedPublicParamId);
}
-
- //
- return false;
+ return true;
}
/**
@@ -625,16 +639,19 @@
}
}
- //Handle exposed portal contextual properties
+ // Handle exposed portal contextual properties
ContextualPropertyManager propertyManager = this.getApplicationComponent(ContextualPropertyManager.class);
Map<QName, String[]> exposedPortalState = propertyManager.getProperties(this);
- for(QName qName : exposedPortalState.keySet())
+ for(QName prpQName : exposedPortalState.keySet())
{
- if(supportsPublicParam(qName.getLocalPart()))
+ String prpId = supportsPublicParam(prpQName);
+ if(prpId != null)
{
- publicParamsMap.put(qName.toString(), exposedPortalState.get(qName));
+ publicParamsMap.put(prpId, exposedPortalState.get(prpQName));
}
}
+
+ //
return publicParamsMap;
}
14 years, 3 months