portals-pluto-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From msnickl...@apache.org
Subject [14/35] portals-pluto git commit: Implemented type annotations for portlet request filters, portlet URL generation listeners, and portlet preference validators. The corresponding definitions in the portlet.xml file are merged into the annotated configura
Date Mon, 18 Jan 2016 12:41:16 GMT
http://git-wip-us.apache.org/repos/asf/portals-pluto/blob/a05e1563/pluto-container/src/test/resources/org/apache/pluto/container/om/portlet/portlet362AlterValidator1.xml
----------------------------------------------------------------------
diff --git a/pluto-container/src/test/resources/org/apache/pluto/container/om/portlet/portlet362AlterValidator1.xml
b/pluto-container/src/test/resources/org/apache/pluto/container/om/portlet/portlet362AlterValidator1.xml
new file mode 100644
index 0000000..3ad0f2d
--- /dev/null
+++ b/pluto-container/src/test/resources/org/apache/pluto/container/om/portlet/portlet362AlterValidator1.xml
@@ -0,0 +1,61 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE xml>
+<portlet-app id="id1" version="3.0"
+   xmlns="http://xmlns.jcp.org/xml/ns/portlet" 
+   xmlns:portlet="http://xmlns.jcp.org/xml/ns/portlet" 
+   xmlns:xml="http://www.w3.org/XML/1998/namespace"
+   xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+   xsi:schemaLocation="http://xmlns.jcp.org/xml/ns/portlet portlet-app_3_0.xsd ">
+
+   <!-- JSR 362 portlet DD test file -->
+
+   <portlet>
+      <portlet-name>portlet1</portlet-name>
+      <display-name xml:lang="de">display-name</display-name>
+      <portlet-preferences>
+         <preference>
+            <name>aPref</name>
+            <value>aValue</value>
+            <read-only>true</read-only>
+         </preference>
+         <preference>
+            <name>bPref</name>
+            <value>dValue</value>
+            <value>eValue</value>
+            <value>fValue</value>
+            <read-only>true</read-only>
+         </preference>
+      </portlet-preferences>
+   </portlet>
+   <portlet>
+      <portlet-name>portlet2</portlet-name>
+      <display-name xml:lang="de">display-name</display-name>
+      <portlet-preferences>
+         <preferences-validator>null</preferences-validator>
+      </portlet-preferences>
+   </portlet>
+   <portlet>
+      <portlet-name>portlet3</portlet-name>
+      <display-name xml:lang="de">display-name</display-name>
+      <portlet-preferences>
+         <preference>
+            <name>cPref</name>
+            <value>cValue</value>
+            <read-only>false</read-only>
+         </preference>
+         <preferences-validator>null</preferences-validator>
+      </portlet-preferences>
+   </portlet>
+   <portlet>
+      <portlet-name>portlet4</portlet-name>
+      <display-name xml:lang="de">display-name</display-name>
+      <portlet-class>org.apache.pluto.container.om.portlet.impl.fixtures.TestPortlet</portlet-class>
+      <portlet-preferences>
+         <preference>
+            <name>dPref</name>
+            <value>dValue</value>
+            <read-only>true</read-only>
+         </preference>
+      </portlet-preferences>
+   </portlet>
+</portlet-app>

http://git-wip-us.apache.org/repos/asf/portals-pluto/blob/a05e1563/pluto-container/src/test/resources/org/apache/pluto/container/om/portlet/portlet362AlterValidator2.xml
----------------------------------------------------------------------
diff --git a/pluto-container/src/test/resources/org/apache/pluto/container/om/portlet/portlet362AlterValidator2.xml
b/pluto-container/src/test/resources/org/apache/pluto/container/om/portlet/portlet362AlterValidator2.xml
new file mode 100644
index 0000000..a80426b
--- /dev/null
+++ b/pluto-container/src/test/resources/org/apache/pluto/container/om/portlet/portlet362AlterValidator2.xml
@@ -0,0 +1,67 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE xml>
+<portlet-app id="id1" version="3.0"
+   xmlns="http://xmlns.jcp.org/xml/ns/portlet" 
+   xmlns:portlet="http://xmlns.jcp.org/xml/ns/portlet" 
+   xmlns:xml="http://www.w3.org/XML/1998/namespace"
+   xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+   xsi:schemaLocation="http://xmlns.jcp.org/xml/ns/portlet portlet-app_3_0.xsd ">
+
+   <!-- JSR 362 portlet DD test file -->
+
+   <portlet>
+      <portlet-name>portlet1</portlet-name>
+      <display-name xml:lang="de">display-name</display-name>
+      <portlet-preferences>
+         <preference>
+            <name>aPref</name>
+            <value>aValue</value>
+            <read-only>true</read-only>
+         </preference>
+         <preference>
+            <name>bPref</name>
+            <value>dValue</value>
+            <value>eValue</value>
+            <value>fValue</value>
+            <read-only>true</read-only>
+         </preference>
+      </portlet-preferences>
+   </portlet>
+   <portlet>
+      <portlet-name>portlet3</portlet-name>
+      <display-name xml:lang="de">display-name</display-name>
+      <portlet-preferences>
+         <preference>
+            <name>cPref</name>
+            <value>cValue</value>
+            <read-only>false</read-only>
+         </preference>
+         <preferences-validator>
+            org.apache.pluto.container.om.portlet.impl.fixtures.TestPreferencesValidator
+         </preferences-validator>
+      </portlet-preferences>
+   </portlet>
+   <portlet>
+      <portlet-name>portlet4</portlet-name>
+      <display-name xml:lang="de">display-name</display-name>
+      <portlet-class>org.apache.pluto.container.om.portlet.impl.fixtures.TestPortlet</portlet-class>
+      <portlet-preferences>
+         <preference>
+            <name>dPref</name>
+            <value>dValue</value>
+            <read-only>true</read-only>
+         </preference>
+         <preferences-validator>
+            org.apache.pluto.container.om.portlet.impl.fixtures.TestPreferencesValidator
+         </preferences-validator>
+      </portlet-preferences>
+   </portlet>
+   <portlet>
+      <portlet-name>portlet5</portlet-name>
+      <display-name xml:lang="de">display-name</display-name>
+      <portlet-class>org.apache.pluto.container.om.portlet.impl.fixtures.TestPortlet</portlet-class>
+      <portlet-preferences>
+         <preferences-validator>null</preferences-validator>
+      </portlet-preferences>
+   </portlet>
+</portlet-app>

http://git-wip-us.apache.org/repos/asf/portals-pluto/blob/a05e1563/pluto-container/src/test/resources/org/apache/pluto/container/om/portlet/portlet362Generated.xml
----------------------------------------------------------------------
diff --git a/pluto-container/src/test/resources/org/apache/pluto/container/om/portlet/portlet362Generated.xml
b/pluto-container/src/test/resources/org/apache/pluto/container/om/portlet/portlet362Generated.xml
index f20bfc4..bc2d3d4 100644
--- a/pluto-container/src/test/resources/org/apache/pluto/container/om/portlet/portlet362Generated.xml
+++ b/pluto-container/src/test/resources/org/apache/pluto/container/om/portlet/portlet362Generated.xml
@@ -157,6 +157,7 @@
    </public-render-parameter>
    <listener>
       <listener-name>test listener</listener-name>
+      <ordinal>100</ordinal>
       <description xml:lang="de">description</description>
       <display-name xml:lang="de">display-name</display-name>
       <listener-class>org.apache.pluto.container.om.portlet.impl.fixtures.TestListener</listener-class>

http://git-wip-us.apache.org/repos/asf/portals-pluto/blob/a05e1563/portlet-api/src/main/java/javax/portlet/annotations/Preference.java
----------------------------------------------------------------------
diff --git a/portlet-api/src/main/java/javax/portlet/annotations/Preference.java b/portlet-api/src/main/java/javax/portlet/annotations/Preference.java
index 1bfa5ca..8cbd5e0 100644
--- a/portlet-api/src/main/java/javax/portlet/annotations/Preference.java
+++ b/portlet-api/src/main/java/javax/portlet/annotations/Preference.java
@@ -61,13 +61,4 @@ public @interface Preference {
     * @return  The read-only flag
     */
    boolean     isReadOnly() default false;
-   
-   /**
-    * <div class='container-change'>
-    * Provides locale-specific text describing the portlet preference for use by the portal
application or by tools.
-    * </div>
-    * 
-    * @return  The portlet preference description
-    */
-   LocaleString[]      description() default {};
 }


Mime
View raw message