Author: julien(a)jboss.com
Date: 2007-02-12 17:02:05 -0500 (Mon, 12 Feb 2007)
New Revision: 6228
Added:
docs/trunk/referenceGuide/en/images/tutorials/first_portlet/desc_relationship.odp
Modified:
docs/trunk/referenceGuide/en/images/tutorials/first_portlet/desc_relationship.gif
docs/trunk/referenceGuide/en/modules/tutorials.xml
Log:
updating tutorial first portlet descriptors with new DTD
Modified:
docs/trunk/referenceGuide/en/images/tutorials/first_portlet/desc_relationship.gif
===================================================================
(Binary files differ)
Added: docs/trunk/referenceGuide/en/images/tutorials/first_portlet/desc_relationship.odp
===================================================================
(Binary files differ)
Property changes on:
docs/trunk/referenceGuide/en/images/tutorials/first_portlet/desc_relationship.odp
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Modified: docs/trunk/referenceGuide/en/modules/tutorials.xml
===================================================================
--- docs/trunk/referenceGuide/en/modules/tutorials.xml 2007-02-12 20:34:50 UTC (rev 6227)
+++ docs/trunk/referenceGuide/en/modules/tutorials.xml 2007-02-12 22:02:05 UTC (rev 6228)
@@ -261,6 +261,10 @@
<listitem>
<para>portlet-instances.xml
<programlisting><![CDATA[
+<?xml version="1.0" standalone="yes"?>
+<!DOCTYPE deployments PUBLIC
+ "-//JBoss Portal//DTD Portlet Instances 2.6//EN"
+ "http://www.jboss.org/portal/dtd/portlet-instances_2_6.dtd">
<deployments>
<deployment>
<instance>
@@ -287,10 +291,14 @@
<listitem>
<para>helloworld-object.xml
<programlisting><![CDATA[
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE deployments PUBLIC
+ "-//JBoss Portal//DTD Portal Object 2.6//EN"
+ "http://www.jboss.org/portal/dtd/portal-object_2_6.dtd">
<deployments>
<deployment>
+ <parent-ref>default.default</parent-ref>
<if-exists>overwrite</if-exists>
- <parent-ref>default.default</parent-ref>
<window>
<window-name>HelloWorldPortletWindow</window-name>
<instance-ref>HelloWorldPortletInstance</instance-ref>
@@ -299,12 +307,45 @@
</window>
</deployment>
</deployments>]]></programlisting>
+
The *-object.xml is responsible for creating/configuring windows,
pages, and even portal
- instances. In our example, we are creating a portlet window,
assigning it to a page, and
+ objects. In our example, we are creating a portlet window,
assigning it to a page, and
specifying where it should appear on that page. This is a
specific descriptor to JBoss Portal.
+ Since 2.6 we can replace also the window section by the following
which will do exactly the same.
+
+ <programlisting><![CDATA[
+<window>
+ <window-name>HelloWorldPortletWindow</window-name>
+ <content>
+ <content-type>portlet</content-type>
+ <content-uri>HelloWorldPortletInstance</content-uri>
+ </content>
+ <region>center</region>
+ <height>1</height>
+</window>
+]]></programlisting>
+ The kind of declaration allows to declare for a window different
kind of content types. You can see
+ that as a generic way to declare content for a window. In our
case the type of content is portlet
+ and the content uri declares the HelloWorldPortletInstance. The
content uri value is the identifier of
+ the content. It is possible to declare windows with content type
cms and use directly the path
+ to the file in the CMS to make the window show cms content. That
behavior is pluggable and it
+ is virtually possible to plug in any kind of content.
<itemizedlist>
<listitem>
<para>
+
<programlisting><![CDATA[<parent-ref>default.default</parent-ref>]]></programlisting>
+ Tells the portal where this portlet should appear. In
this case,
+ <emphasis>default.default</emphasis>
+ specifies that this portlet should appear in the portal
instance named
+ <emphasis>default</emphasis>
+ and the
+ page named
+ <emphasis>default</emphasis>
+ .
+ </para>
+ </listitem>
+ <listitem>
+ <para>
<programlisting><![CDATA[<if-exists>overwrite</if-exists>]]></programlisting>
Instructs the portal to overwrite or keep this object if
it already exists.
Possible values are
@@ -322,19 +363,6 @@
</listitem>
<listitem>
<para>
-
<programlisting><![CDATA[<parent-ref>default.default</parent-ref>]]></programlisting>
- Tells the portal where this portlet should appear. In
this case,
- <emphasis>default.default</emphasis>
- specifies that this portlet should appear in the portal
instance named
- <emphasis>default</emphasis>
- and the
- page named
- <emphasis>default</emphasis>
- .
- </para>
- </listitem>
- <listitem>
- <para>
<programlisting>
<![CDATA[<window-name>HelloWorldPortletWindow</window-name>]]></programlisting>
Can be named anything.
Show replies by date