JBoss Portal SVN: r10915 - branches/JBoss_Portal_Branch_2_7/core/src/resources/portal-server-war.
by portal-commits@lists.jboss.org
Author: thomas.heute(a)jboss.com
Date: 2008-06-03 14:30:45 -0400 (Tue, 03 Jun 2008)
New Revision: 10915
Modified:
branches/JBoss_Portal_Branch_2_7/core/src/resources/portal-server-war/login.jsp
Log:
oups
Modified: branches/JBoss_Portal_Branch_2_7/core/src/resources/portal-server-war/login.jsp
===================================================================
--- branches/JBoss_Portal_Branch_2_7/core/src/resources/portal-server-war/login.jsp 2008-06-03 18:28:51 UTC (rev 10914)
+++ branches/JBoss_Portal_Branch_2_7/core/src/resources/portal-server-war/login.jsp 2008-06-03 18:30:45 UTC (rev 10915)
@@ -25,12 +25,11 @@
<%@page import="java.util.ResourceBundle"%>
<%
- ResourceBundle rb = ResourceBundle.getBundle("Resource", request.getLocale());
+ ResourceBundle rb = ResourceBundle.getBundle("Resource", request.getLocale());
%>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
-<%@page import="java.util.Locale"%>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title><%= rb.getString("LOGIN_TITLE") %></title>
17 years, 11 months
JBoss Portal SVN: r10914 - branches/JBoss_Portal_Branch_2_7/core/src/resources/portal-server-war.
by portal-commits@lists.jboss.org
Author: thomas.heute(a)jboss.com
Date: 2008-06-03 14:28:51 -0400 (Tue, 03 Jun 2008)
New Revision: 10914
Modified:
branches/JBoss_Portal_Branch_2_7/core/src/resources/portal-server-war/login.jsp
Log:
minor
Modified: branches/JBoss_Portal_Branch_2_7/core/src/resources/portal-server-war/login.jsp
===================================================================
--- branches/JBoss_Portal_Branch_2_7/core/src/resources/portal-server-war/login.jsp 2008-06-03 17:55:43 UTC (rev 10913)
+++ branches/JBoss_Portal_Branch_2_7/core/src/resources/portal-server-war/login.jsp 2008-06-03 18:28:51 UTC (rev 10914)
@@ -25,11 +25,12 @@
<%@page import="java.util.ResourceBundle"%>
<%
- ResourceBundle rb = ResourceBundle.getBundle("Resource", request.getLocale());
+ ResourceBundle rb = ResourceBundle.getBundle("Resource", request.getLocale());
%>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<%@page import="java.util.Locale"%>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title><%= rb.getString("LOGIN_TITLE") %></title>
17 years, 11 months
JBoss Portal SVN: r10913 - branches/JBoss_Portal_Branch_2_7/core-admin/src/resources/portal-admin-war/jsf/common.
by portal-commits@lists.jboss.org
Author: wesleyhales
Date: 2008-06-03 13:55:43 -0400 (Tue, 03 Jun 2008)
New Revision: 10913
Modified:
branches/JBoss_Portal_Branch_2_7/core-admin/src/resources/portal-admin-war/jsf/common/showPortletDetails.xhtml
Log:
fix form enclosing entire page
Modified: branches/JBoss_Portal_Branch_2_7/core-admin/src/resources/portal-admin-war/jsf/common/showPortletDetails.xhtml
===================================================================
--- branches/JBoss_Portal_Branch_2_7/core-admin/src/resources/portal-admin-war/jsf/common/showPortletDetails.xhtml 2008-06-03 16:54:16 UTC (rev 10912)
+++ branches/JBoss_Portal_Branch_2_7/core-admin/src/resources/portal-admin-war/jsf/common/showPortletDetails.xhtml 2008-06-03 17:55:43 UTC (rev 10913)
@@ -5,8 +5,9 @@
xmlns:a4j="http://richfaces.org/a4j"
xmlns:rich="http://richfaces.org/rich"
xmlns:portal="http://www.jboss.org/portal">
-<h:form>
+
<div class="details-container">
+<h:form>
<div class="full-width details-header">
<div class="main-header">
<br/>
@@ -51,6 +52,7 @@
<br class="clear"/>
</div>
</div>
+</h:form>
<div class="details-body">
<div class="half-width float-left details-left-col">
@@ -125,13 +127,10 @@
<div class="half-width float-right details-right-col">
-
-
<f:subview rendered="#{showDisplayNameEditor}">
<div class="whiteWithLtGreyHeader meta-box">
-
<h3 class="blue">#{bundle.COMMON_ADD_INSTANCE_DISPLAY_NAMES}</h3>
<div class="pad5">
<h:form style="background-color:transparent;width:100%;margin:0;padding:0;display:inline;">
@@ -233,5 +232,5 @@
<br class="clear"/>
</div>
-</h:form>
+
</div>
\ No newline at end of file
17 years, 11 months
JBoss Portal SVN: r10912 - in branches/JBoss_Portal_Branch_2_7: core-admin/src/bin/portal-admin-war/css and 6 other directories.
by portal-commits@lists.jboss.org
Author: wesleyhales
Date: 2008-06-03 12:54:16 -0400 (Tue, 03 Jun 2008)
New Revision: 10912
Added:
branches/JBoss_Portal_Branch_2_7/core-admin/src/bin/portal-admin-war/img/corners/
branches/JBoss_Portal_Branch_2_7/core-admin/src/bin/portal-admin-war/img/corners/7px/
branches/JBoss_Portal_Branch_2_7/core-admin/src/bin/portal-admin-war/img/corners/7px/corner-left-bottom-grey.gif
branches/JBoss_Portal_Branch_2_7/core-admin/src/bin/portal-admin-war/img/corners/7px/corner-left-bottom-white.gif
branches/JBoss_Portal_Branch_2_7/core-admin/src/bin/portal-admin-war/img/corners/7px/corner-left-top-grey.gif
branches/JBoss_Portal_Branch_2_7/core-admin/src/bin/portal-admin-war/img/corners/7px/corner-left-top-white.gif
branches/JBoss_Portal_Branch_2_7/core-admin/src/bin/portal-admin-war/img/corners/7px/corner-right-bottom-grey.gif
branches/JBoss_Portal_Branch_2_7/core-admin/src/bin/portal-admin-war/img/corners/7px/corner-right-bottom-white.gif
branches/JBoss_Portal_Branch_2_7/core-admin/src/bin/portal-admin-war/img/corners/7px/corner-right-top-grey.gif
branches/JBoss_Portal_Branch_2_7/core-admin/src/bin/portal-admin-war/img/corners/7px/corner-right-top-white.gif
Modified:
branches/JBoss_Portal_Branch_2_7/core-admin/src/bin/portal-admin-war/css/basestyles.css
branches/JBoss_Portal_Branch_2_7/core-admin/src/bin/portal-admin-war/css/boxes.css
branches/JBoss_Portal_Branch_2_7/core-admin/src/bin/portal-admin-war/css/style.css
branches/JBoss_Portal_Branch_2_7/core-admin/src/resources/portal-admin-war/WEB-INF/jboss-portlet.xml
branches/JBoss_Portal_Branch_2_7/core-admin/src/resources/portal-admin-war/WEB-INF/tags/boxes.xhtml
branches/JBoss_Portal_Branch_2_7/core-admin/src/resources/portal-admin-war/WEB-INF/web.xml
branches/JBoss_Portal_Branch_2_7/core-admin/src/resources/portal-admin-war/jsf/common/showPortletDetails.xhtml
branches/JBoss_Portal_Branch_2_7/core/src/bin/portal-core-war/css/login.css
Log:
semantically marked up rounded corners, and ie fix for login modal
Modified: branches/JBoss_Portal_Branch_2_7/core/src/bin/portal-core-war/css/login.css
===================================================================
--- branches/JBoss_Portal_Branch_2_7/core/src/bin/portal-core-war/css/login.css 2008-06-03 13:02:14 UTC (rev 10911)
+++ branches/JBoss_Portal_Branch_2_7/core/src/bin/portal-core-war/css/login.css 2008-06-03 16:54:16 UTC (rev 10912)
@@ -18,6 +18,7 @@
font-size: 10px;
font-weight: bold;
position: absolute;
+ width: 75px;
}
input.login-button {
Modified: branches/JBoss_Portal_Branch_2_7/core-admin/src/bin/portal-admin-war/css/basestyles.css
===================================================================
--- branches/JBoss_Portal_Branch_2_7/core-admin/src/bin/portal-admin-war/css/basestyles.css 2008-06-03 13:02:14 UTC (rev 10911)
+++ branches/JBoss_Portal_Branch_2_7/core-admin/src/bin/portal-admin-war/css/basestyles.css 2008-06-03 16:54:16 UTC (rev 10912)
@@ -100,3 +100,11 @@
border-right: 1px solid #b9c6d7;
}
+.absolute{
+ position:absolute;
+}
+
+.relative{
+ position:relative;
+}
+
Modified: branches/JBoss_Portal_Branch_2_7/core-admin/src/bin/portal-admin-war/css/boxes.css
===================================================================
--- branches/JBoss_Portal_Branch_2_7/core-admin/src/bin/portal-admin-war/css/boxes.css 2008-06-03 13:02:14 UTC (rev 10911)
+++ branches/JBoss_Portal_Branch_2_7/core-admin/src/bin/portal-admin-war/css/boxes.css 2008-06-03 16:54:16 UTC (rev 10912)
@@ -1,195 +1,86 @@
-/*------------------------------------------Grey Rounded Box-----*/
-
-.greyRounded {
- /*width: 100%;*/
+.meta-box{
+ width: 95%;
+ padding: 0 0 8px 0;
+ margin: 0 auto 0 auto;
}
-.greyRounded .xtop, .greyRounded .xbottom {
- display: block;
- background: transparent;
- font-size: 1px;
+.meta-box h3 {
+ background-color: #ececec;
+ padding: 2px 2px 2px 5px;
+ color: #777777;
}
-.greyRounded .xtop .xb1, .greyRounded .xtop .xb2, .greyRounded .xtop .xb3, .greyRounded .xtop .xb4,
- .greyRounded .xbottom .xb1, .greyRounded .xbottom .xb2, .greyRounded .xbottom .xb3, .greyRounded .xbottom .xb4 {
- display: block;
- overflow: hidden;
+/*------------------------------------------White Rounded Box with light grey Header-----*/
+.whiteWithLtGreyHeader {
+ position:relative;
+ margin: 5px 0 5px 10px;
}
-.greyRounded .xtop .xb1, .greyRounded .xtop .xb2, .greyRounded .xtop .xb3,
- .greyRounded .xbottom .xb1, .greyRounded .xbottom .xb2, .greyRounded .xbottom .xb3 {
- height: 1px;
+.whiteWithLtGreyHeader .box-header,
+.whiteWithLtGreyHeader .box-footer{
+ padding: 0 7px 0 7px;
+ position: relative;
}
-.greyRounded .xtop .xb2, .greyRounded .xtop .xb3, .greyRounded .xtop .xb4,
- .greyRounded .xbottom .xb2, .greyRounded .xbottom .xb3, .greyRounded .xbottom .xb4 {
- background: #f8f8f8;
- border-left: 1px solid #d4d4d4;
- border-right: 1px solid #d4d4d4;
+.whiteWithLtGreyHeader .img-top-left{
+ position:absolute;
+ top:0;
+ left:0;
}
-.greyRounded .xtop .xb1,
- .greyRounded .xbottom .xb1 {
- margin: 0 5px;
- background: #d4d4d4;
+.whiteWithLtGreyHeader .img-top-right{
+ position:absolute;
+ top:0;
+ right:0;
}
-.greyRounded .xtop .xb2,
- .greyRounded .xbottom .xb2 {
- margin: 0 3px;
- border-width: 0 2px;
+.whiteWithLtGreyHeader .img-bottom-left{
+ position:absolute;
+ bottom:0;
+ left:0;
}
-.greyRounded .xtop .xb3,
- .greyRounded .xbottom .xb3 {
- margin: 0 2px;
+.whiteWithLtGreyHeader .img-bottom-right{
+ position:absolute;
+ bottom:0;
+ right:0;
}
-.greyRounded .xtop .xb4,
- .greyRounded .xbottom .xb4 {
- height: 2px;
- margin: 0 1px;
+.whiteWithLtGreyHeader .box-header-content{
+ border-top:1px solid #a5a5a5;
+ background-color:#ececec;
+ width: 100%;
+ height:6px;
}
-.greyRounded .xboxcontent {
- background: #f8f8f8;
- border: 0 solid #d4d4d4;
- border-width: 0 1px;
- padding: 5px;
- font-family: verdana, arial, helvetica, sans-serif;
- font-size: 11px;
- color: #000;
+.whiteWithLtGreyHeader .box-content{
+ border-left:1px solid #a5a5a5;
+ border-right:1px solid #a5a5a5;
}
-/*------------------------------------------lt blue Rounded Box-----*/
-
-.ltBlueRounded {
- /*width: 100%;*/
+.whiteWithLtGreyHeader .box-footer-content{
+ border-bottom:1px solid #a5a5a5;
+ width: 100%;
+ height:6px;
}
-.ltBlueRounded .xtop, .ltBlueRounded .xbottom {
- display: block;
- background: transparent;
- font-size: 1px;
-}
-.ltBlueRounded .xtop .xb1, .ltBlueRounded .xtop .xb2, .ltBlueRounded .xtop .xb3, .ltBlueRounded .xtop .xb4,
- .ltBlueRounded .xbottom .xb1, .ltBlueRounded .xbottom .xb2, .ltBlueRounded .xbottom .xb3, .ltBlueRounded .xbottom .xb4 {
- display: block;
- overflow: hidden;
-}
-.ltBlueRounded .xtop .xb1, .ltBlueRounded .xtop .xb2, .ltBlueRounded .xtop .xb3,
- .ltBlueRounded .xbottom .xb1, .ltBlueRounded .xbottom .xb2, .ltBlueRounded .xbottom .xb3 {
- height: 1px;
-}
+/*------------------------------------------Grey Rounded Box-----*/
-.ltBlueRounded .xtop .xb2, .ltBlueRounded .xtop .xb3, .ltBlueRounded .xtop .xb4,
- .ltBlueRounded .xbottom .xb2, .ltBlueRounded .xbottom .xb3, .ltBlueRounded .xbottom .xb4 {
- background: #f7f9fc;
- border-left: 1px solid #d4d4d4;
- border-right: 1px solid #d4d4d4;
+.greyRounded {
+ /*todo*/
}
-.ltBlueRounded .xtop .xb1,
- .ltBlueRounded .xbottom .xb1 {
- margin: 0 5px;
- background: #d4d4d4;
-}
-.ltBlueRounded .xtop .xb2,
- .ltBlueRounded .xbottom .xb2 {
- margin: 0 3px;
- border-width: 0 2px;
-}
-.ltBlueRounded .xtop .xb3,
- .ltBlueRounded .xbottom .xb3 {
- margin: 0 2px;
-}
+/*------------------------------------------lt blue Rounded Box-----*/
-.ltBlueRounded .xtop .xb4,
- .ltBlueRounded .xbottom .xb4 {
- height: 2px;
- margin: 0 1px;
+.ltBlueRounded {
+ /*todo*/
}
-.ltBlueRounded .xboxcontent {
- background: #f7f9fc;
- border: 0 solid #d4d4d4;
- border-width: 0 1px;
- padding: 5px;
- font-family: verdana, arial, helvetica, sans-serif;
- font-size: 11px;
- color: #000;
-}
-/*------------------------------------------White Rounded Box with light grey Header-----*/
-.whiteWithLtGreyHeader {
- /*width: 100%;*/
-}
-
-.whiteWithLtGreyHeader .xtop, .whiteWithLtGreyHeader .xbottom {
- display:block;
- background:transparent;
- font-size:1px;
-}
-
-.whiteWithLtGreyHeader .xtop .xb1, .whiteWithLtGreyHeader .xtop .xb2, .whiteWithLtGreyHeader .xtop .xb3, .whiteWithLtGreyHeader .xtop .xb4,
-.whiteWithLtGreyHeader .xbottom .xb1, .whiteWithLtGreyHeader .xbottom .xb2, .whiteWithLtGreyHeader .xbottom .xb3, .whiteWithLtGreyHeader .xbottom .xb4 {
- display:block;
- overflow:hidden;
-
-}
-.whiteWithLtGreyHeader .xtop .xb1, .whiteWithLtGreyHeader .xtop .xb2, .whiteWithLtGreyHeader .xtop .xb3,
-.whiteWithLtGreyHeader .xbottom .xb1, .whiteWithLtGreyHeader .xbottom .xb2, .whiteWithLtGreyHeader .xbottom .xb3 {
- height:1px;
-}
-
-.whiteWithLtGreyHeader .xtop .xb2, .whiteWithLtGreyHeader .xtop .xb3, .whiteWithLtGreyHeader .xtop .xb4{
- background:#f8f8f8;
- border-left:1px solid #d4d4d4;
- border-right:1px solid #d4d4d4;
-}
-.whiteWithLtGreyHeader .xbottom .xb2, .whiteWithLtGreyHeader .xbottom .xb3, .whiteWithLtGreyHeader .xbottom .xb4 {
- background:#ffffff;
- border-left:1px solid #d4d4d4;
- border-right:1px solid #d4d4d4;
-}
-
-.whiteWithLtGreyHeader .xtop .xb1,
-.whiteWithLtGreyHeader .xbottom .xb1 {
- margin:0 5px;
- background:#d4d4d4;
-}
-
-.whiteWithLtGreyHeader .xtop .xb2,
-.whiteWithLtGreyHeader .xbottom .xb2 {
- margin:0 3px;
- border-width:0 2px;
-}
-
-.whiteWithLtGreyHeader .xtop .xb3,
-.whiteWithLtGreyHeader .xbottom .xb3 {
- margin:0 2px;
-}
-
-.whiteWithLtGreyHeader .xtop .xb4,
-.whiteWithLtGreyHeader .xbottom .xb4 {
- height:2px;
- margin:0 1px;
-}
-
-.whiteWithLtGreyHeader .xboxcontent {
- display:block;
- background:#ffffff;
- border:0 solid #d4d4d4;
- border-width:0 1px;
- padding: 0px;
- font-family: verdana,arial,helvetica,sans-serif;
- font-size: 11px;
- color: #000;
-}
\ No newline at end of file
Modified: branches/JBoss_Portal_Branch_2_7/core-admin/src/bin/portal-admin-war/css/style.css
===================================================================
--- branches/JBoss_Portal_Branch_2_7/core-admin/src/bin/portal-admin-war/css/style.css 2008-06-03 13:02:14 UTC (rev 10911)
+++ branches/JBoss_Portal_Branch_2_7/core-admin/src/bin/portal-admin-war/css/style.css 2008-06-03 16:54:16 UTC (rev 10912)
@@ -293,6 +293,11 @@
border: 1px solid #d5d5d5;
}
+.admin-ui .portlet-section-alternate-blue {
+ background-color: #EEF3F5;
+ border: 1px solid #d5d5d5;
+}
+
.admin-ui .portlet-section-selected {
background-color: #CBD4E6;
}
@@ -623,7 +628,7 @@
.details-container {
margin: 0 15px 15px 15px;
- border: 1px solid #ececec;
+ border: 2px solid #d0d0d0;
}
.details-container p {
@@ -687,24 +692,9 @@
padding: 15px 0 0 0;
}
-.meta-box{
- width: 95%;
- padding: 0 0 8px 0;
- margin: 0 auto 0 auto;
-}
-.meta-box h3 {
- background-color: #f8f8f8;
+h3.blue {
padding: 2px 2px 2px 5px;
- color: #666666;
-}
-
-div.displayNames {
- width: 100%
-}
-
-div.displayNames h3 {
- padding: 2px 2px 2px 5px;
margin: 0 0 3px 0;
color: #003399;
}
Added: branches/JBoss_Portal_Branch_2_7/core-admin/src/bin/portal-admin-war/img/corners/7px/corner-left-bottom-grey.gif
===================================================================
(Binary files differ)
Property changes on: branches/JBoss_Portal_Branch_2_7/core-admin/src/bin/portal-admin-war/img/corners/7px/corner-left-bottom-grey.gif
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Added: branches/JBoss_Portal_Branch_2_7/core-admin/src/bin/portal-admin-war/img/corners/7px/corner-left-bottom-white.gif
===================================================================
(Binary files differ)
Property changes on: branches/JBoss_Portal_Branch_2_7/core-admin/src/bin/portal-admin-war/img/corners/7px/corner-left-bottom-white.gif
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Added: branches/JBoss_Portal_Branch_2_7/core-admin/src/bin/portal-admin-war/img/corners/7px/corner-left-top-grey.gif
===================================================================
(Binary files differ)
Property changes on: branches/JBoss_Portal_Branch_2_7/core-admin/src/bin/portal-admin-war/img/corners/7px/corner-left-top-grey.gif
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Added: branches/JBoss_Portal_Branch_2_7/core-admin/src/bin/portal-admin-war/img/corners/7px/corner-left-top-white.gif
===================================================================
(Binary files differ)
Property changes on: branches/JBoss_Portal_Branch_2_7/core-admin/src/bin/portal-admin-war/img/corners/7px/corner-left-top-white.gif
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Added: branches/JBoss_Portal_Branch_2_7/core-admin/src/bin/portal-admin-war/img/corners/7px/corner-right-bottom-grey.gif
===================================================================
(Binary files differ)
Property changes on: branches/JBoss_Portal_Branch_2_7/core-admin/src/bin/portal-admin-war/img/corners/7px/corner-right-bottom-grey.gif
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Added: branches/JBoss_Portal_Branch_2_7/core-admin/src/bin/portal-admin-war/img/corners/7px/corner-right-bottom-white.gif
===================================================================
(Binary files differ)
Property changes on: branches/JBoss_Portal_Branch_2_7/core-admin/src/bin/portal-admin-war/img/corners/7px/corner-right-bottom-white.gif
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Added: branches/JBoss_Portal_Branch_2_7/core-admin/src/bin/portal-admin-war/img/corners/7px/corner-right-top-grey.gif
===================================================================
(Binary files differ)
Property changes on: branches/JBoss_Portal_Branch_2_7/core-admin/src/bin/portal-admin-war/img/corners/7px/corner-right-top-grey.gif
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Added: branches/JBoss_Portal_Branch_2_7/core-admin/src/bin/portal-admin-war/img/corners/7px/corner-right-top-white.gif
===================================================================
(Binary files differ)
Property changes on: branches/JBoss_Portal_Branch_2_7/core-admin/src/bin/portal-admin-war/img/corners/7px/corner-right-top-white.gif
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Modified: branches/JBoss_Portal_Branch_2_7/core-admin/src/resources/portal-admin-war/WEB-INF/jboss-portlet.xml
===================================================================
--- branches/JBoss_Portal_Branch_2_7/core-admin/src/resources/portal-admin-war/WEB-INF/jboss-portlet.xml 2008-06-03 13:02:14 UTC (rev 10911)
+++ branches/JBoss_Portal_Branch_2_7/core-admin/src/resources/portal-admin-war/WEB-INF/jboss-portlet.xml 2008-06-03 16:54:16 UTC (rev 10912)
@@ -39,6 +39,7 @@
<script src="/faces/rfRes/org/richfaces/ui.pack.js" type="text/javascript" ></script>
<link rel="stylesheet" type="text/css" href="/faces/rfRes/org/richfaces/skin.xcss" />
<link rel="stylesheet" type="text/css" href="/css/style.css" media="screen"/>
+ <link rel="stylesheet" type="text/css" href="/css/boxes.css"/>
</header-content>
<portlet-info>
<icon>
Modified: branches/JBoss_Portal_Branch_2_7/core-admin/src/resources/portal-admin-war/WEB-INF/tags/boxes.xhtml
===================================================================
--- branches/JBoss_Portal_Branch_2_7/core-admin/src/resources/portal-admin-war/WEB-INF/tags/boxes.xhtml 2008-06-03 13:02:14 UTC (rev 10911)
+++ branches/JBoss_Portal_Branch_2_7/core-admin/src/resources/portal-admin-war/WEB-INF/tags/boxes.xhtml 2008-06-03 16:54:16 UTC (rev 10912)
@@ -2,12 +2,23 @@
xmlns:ui="http://java.sun.com/jsf/facelets"
xmlns:f="http://java.sun.com/jsf/core"
xmlns:h="http://java.sun.com/jsf/html">
- <link rel="stylesheet" type="text/css" href="/portal-admin/css/boxes.css"/>
- <div class="#{class == null ? 'greyRounded' : class}" >
- <b class="xtop"><b class="xb1"/><b class="xb2"/><b class="xb3"/><b class="xb4"/></b>
- <div class="xboxcontent">
- <ui:insert/>
+
+ <div class="#{class == null ? 'greyRounded' : class}">
+ <div class="box-header">
+ <h:graphicImage url="/img/corners/7px/corner-left-top-grey.gif" alt="" styleClass="img-top-left"/>
+ <div class="box-header-content">
</div>
- <b class="xbottom"><b class="xb4"/><b class="xb3"/><b class="xb2"/><b class="xb1"/></b>
+ <h:graphicImage url="/img/corners/7px/corner-right-top-grey.gif" alt="" styleClass="img-top-right"/>
+ </div>
+ <div class="box-content">
+ <ui:insert/>
+ </div>
+ <div class="box-footer">
+ <h:graphicImage url="/img/corners/7px/corner-left-bottom-white.gif" alt="" styleClass="img-bottom-left"/>
+ <div class="box-footer-content">
</div>
+ <h:graphicImage url="/img/corners/7px/corner-right-bottom-white.gif" alt="" styleClass="img-bottom-right"/>
+ </div>
+ </div>
+
</ui:composition>
\ No newline at end of file
Modified: branches/JBoss_Portal_Branch_2_7/core-admin/src/resources/portal-admin-war/WEB-INF/web.xml
===================================================================
--- branches/JBoss_Portal_Branch_2_7/core-admin/src/resources/portal-admin-war/WEB-INF/web.xml 2008-06-03 13:02:14 UTC (rev 10911)
+++ branches/JBoss_Portal_Branch_2_7/core-admin/src/resources/portal-admin-war/WEB-INF/web.xml 2008-06-03 16:54:16 UTC (rev 10912)
@@ -39,11 +39,6 @@
</context-param>
<context-param>
- <param-name>javax.portlet.faces.preserveActionParams</param-name>
- <param-value>true</param-value>
- </context-param>
-
- <context-param>
<param-name>org.ajax4jsf.RESOURCE_URI_PREFIX</param-name>
<param-value>rfRes</param-value>
</context-param>
Modified: branches/JBoss_Portal_Branch_2_7/core-admin/src/resources/portal-admin-war/jsf/common/showPortletDetails.xhtml
===================================================================
--- branches/JBoss_Portal_Branch_2_7/core-admin/src/resources/portal-admin-war/jsf/common/showPortletDetails.xhtml 2008-06-03 13:02:14 UTC (rev 10911)
+++ branches/JBoss_Portal_Branch_2_7/core-admin/src/resources/portal-admin-war/jsf/common/showPortletDetails.xhtml 2008-06-03 16:54:16 UTC (rev 10912)
@@ -129,13 +129,12 @@
<f:subview rendered="#{showDisplayNameEditor}">
- <portal:box class="ltBlueRounded meta-box">
- <div class="displayNames">
- <div>
- <h:form style="background-color:transparent;">
- <h3 style="background-color:transparent;">#{bundle.COMMON_ADD_INSTANCE_DISPLAY_NAMES}</h3>
+ <div class="whiteWithLtGreyHeader meta-box">
- <div style="background-color:transparent;">
+
+ <h3 class="blue">#{bundle.COMMON_ADD_INSTANCE_DISPLAY_NAMES}</h3>
+ <div class="pad5">
+ <h:form style="background-color:transparent;width:100%;margin:0;padding:0;display:inline;">
<h:inputText id="newName" value="#{instanceDisplayNameAction.newText}" required="true"/>
<h:selectOneMenu id="locales" value="#{instanceDisplayNameAction.newLocale}">
<f:selectItems value="#{instanceDisplayNameAction.locales}"/>
@@ -143,19 +142,16 @@
<h:commandButton value="#{instanceDisplayNameAction.newText ne null ? 'Modify' : 'Add'} Name"
action="#{instanceDisplayNameAction.addDisplayName}"
styleClass="portlet-form-button"/>
- </div>
- </h:form>
+ </h:form>
</div>
<br/>
- <div>
- <h:form >
- <h3>#{bundle.COMMON_CURRENT_INSTANCE_DISPLAY_NAMES}</h3>
+ <h3 class="blue">#{bundle.COMMON_CURRENT_INSTANCE_DISPLAY_NAMES}</h3>
+ <div class="pad5">
- <div >
-
+ <h:form style="display:inline;width:100%;">
<h:dataTable var="value" value="#{instanceDisplayNameAction.currentLocales}"
styleClass="objectList datatable"
- rowClasses="portlet-section-body,portlet-section-alternate"
+ rowClasses="portlet-section-body,portlet-section-alternate-blue"
columnClasses="objectNameColumn, objectActionColumn"
headerClass="portlet-section-header">
<h:column>
@@ -186,21 +182,18 @@
<h:outputText value="#{bundle.RENAME}"/>
</f:facet>
- <div style="width:150px"><h:commandLink action="#{instanceDisplayNameAction.editDisplayName}">
+ <div style="width:150px">
+ <h:commandLink action="#{instanceDisplayNameAction.editDisplayName}">
<h:outputText styleClass="actionRename" value="#{bundle.RENAME}"/>
<f:param name="locale" value="#{value.locale}"/>
<f:param name="editAction" value="rename"/>
</h:commandLink></div>
</h:column>
</h:dataTable>
-
- </div>
- </h:form>
-
+ </h:form>
</div>
- <br class="clear"/>
- </div>
- </portal:box>
+ </div>
+
</f:subview>
<br class="clear"/>
@@ -237,7 +230,7 @@
<br class="clear"/>
</div>
-
+<br class="clear"/>
</div>
</h:form>
17 years, 11 months
JBoss Portal SVN: r10911 - in modules/presentation/trunk/portal/src: main/java/org/jboss/portal/presentation/portal and 4 other directories.
by portal-commits@lists.jboss.org
Author: julien(a)jboss.com
Date: 2008-06-03 09:02:14 -0400 (Tue, 03 Jun 2008)
New Revision: 10911
Added:
modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/PortalNodeAdapter.java
modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/PortalNodeManager.java
modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/PortalNodeState.java
modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/structural/
modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/structural/StructuralAdapter.java
modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/structural/StructuralObjectImpl.java
modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/structural/StructuralStateContextImpl.java
Removed:
modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/StructuralNode.java
modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/StructuralObjectImpl.java
modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/StructuralStateContextImpl.java
modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/StructuralStateImpl.java
Modified:
modules/presentation/trunk/portal/src/main/artifacts/presentation-portal-war/WEB-INF/jboss-beans.xml
modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/PresentationServerImpl.java
modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/ContextNode.java
modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/PageNode.java
modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/PaneNode.java
modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/PortalNode.java
modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/WindowNode.java
modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/servlet/StructuralStateContextImporter.java
modules/presentation/trunk/portal/src/test/java/org/jboss/portal/presentation/portal/model/StructuralStateContextTestCase.java
Log:
decouple the portal node tree and the structural object facade
Modified: modules/presentation/trunk/portal/src/main/artifacts/presentation-portal-war/WEB-INF/jboss-beans.xml
===================================================================
--- modules/presentation/trunk/portal/src/main/artifacts/presentation-portal-war/WEB-INF/jboss-beans.xml 2008-06-03 11:44:57 UTC (rev 10910)
+++ modules/presentation/trunk/portal/src/main/artifacts/presentation-portal-war/WEB-INF/jboss-beans.xml 2008-06-03 13:02:14 UTC (rev 10911)
@@ -131,7 +131,7 @@
</constructor>
</bean>
- <bean name="StructuralStateContext" class="org.jboss.portal.presentation.portal.model.StructuralStateContextImpl"/>
+ <bean name="StructuralStateContext" class="org.jboss.portal.presentation.portal.model.PortalNodeManager"/>
<bean name="StructuralStateContextImporter" class="org.jboss.portal.presentation.portal.servlet.StructuralStateContextImporter">
<property name="servletContext"><inject bean="ServletContext"/></property>
Modified: modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/PresentationServerImpl.java
===================================================================
--- modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/PresentationServerImpl.java 2008-06-03 11:44:57 UTC (rev 10910)
+++ modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/PresentationServerImpl.java 2008-06-03 13:02:14 UTC (rev 10911)
@@ -24,7 +24,7 @@
import org.jboss.portal.presentation.client.PresentationClient;
import org.jboss.portal.presentation.portal.model.PortalNode;
-import org.jboss.portal.presentation.portal.model.StructuralStateContextImpl;
+import org.jboss.portal.presentation.portal.model.PortalNodeManager;
import org.jboss.portal.presentation.portal.model.WindowNode;
import org.jboss.portal.presentation.portal.model.PageNode;
import org.jboss.portal.presentation.portal.content.protocol.ContentAction;
@@ -53,12 +53,12 @@
{
/** . */
- private StructuralStateContextImpl structuralStateContext;
+ private PortalNodeManager structuralStateContext;
/** . */
private ContentHandlerRegistry contentHandlerRegistry;
- public PresentationServerImpl(StructuralStateContextImpl structuralStateContext, ContentHandlerRegistry contentHandlerRegistry)
+ public PresentationServerImpl(PortalNodeManager structuralStateContext, ContentHandlerRegistry contentHandlerRegistry)
{
this.structuralStateContext = structuralStateContext;
this.contentHandlerRegistry = contentHandlerRegistry;
@@ -66,7 +66,7 @@
public StructuralStateContext getStructuralStateContext()
{
- return structuralStateContext;
+ return structuralStateContext.getStructuralStateContext();
}
public WindowContent renderWindow(PresentationClient client, String windowId) throws PresentationServerException
Modified: modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/ContextNode.java
===================================================================
--- modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/ContextNode.java 2008-06-03 11:44:57 UTC (rev 10910)
+++ modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/ContextNode.java 2008-06-03 13:02:14 UTC (rev 10911)
@@ -31,7 +31,7 @@
*/
public class ContextNode extends PortalNode
{
- public ContextNode(String name, StructuralStateContextImpl structuralStateContext)
+ public ContextNode(String name, PortalNodeManager structuralStateContext)
{
super(name, structuralStateContext);
}
Modified: modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/PageNode.java
===================================================================
--- modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/PageNode.java 2008-06-03 11:44:57 UTC (rev 10910)
+++ modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/PageNode.java 2008-06-03 13:02:14 UTC (rev 10911)
@@ -35,7 +35,7 @@
*/
public class PageNode extends PortalNode
{
- public PageNode(String name, StructuralStateContextImpl structuralStateContext)
+ public PageNode(String name, PortalNodeManager structuralStateContext)
{
super(name, structuralStateContext);
}
Modified: modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/PaneNode.java
===================================================================
--- modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/PaneNode.java 2008-06-03 11:44:57 UTC (rev 10910)
+++ modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/PaneNode.java 2008-06-03 13:02:14 UTC (rev 10911)
@@ -32,7 +32,7 @@
public class PaneNode extends PortalNode
{
- public PaneNode(String name, StructuralStateContextImpl structuralStateContext)
+ public PaneNode(String name, PortalNodeManager structuralStateContext)
{
super(name, structuralStateContext);
}
Modified: modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/PortalNode.java
===================================================================
--- modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/PortalNode.java 2008-06-03 11:44:57 UTC (rev 10910)
+++ modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/PortalNode.java 2008-06-03 13:02:14 UTC (rev 10911)
@@ -23,8 +23,6 @@
package org.jboss.portal.presentation.portal.model;
import org.jboss.portal.presentation.model.ui.UIObject;
-import org.jboss.portal.presentation.state.StaleStateException;
-import org.jboss.portal.presentation.state.structural.StructuralObject;
import java.lang.reflect.Constructor;
import java.lang.reflect.InvocationTargetException;
@@ -32,7 +30,6 @@
import java.util.Collection;
import java.util.Collections;
import java.util.HashMap;
-import java.util.HashSet;
import java.util.Map;
import java.util.Set;
import java.io.Serializable;
@@ -45,30 +42,27 @@
{
/** . */
- private final Set<String> EMPTY_STRING_SET = Collections.emptySet();
-
- /** . */
private PortalNode parent;
/** . */
- private final Map<String, PortalNode> children = new HashMap<String, PortalNode>();
+ final Map<String, PortalNode> children = new HashMap<String, PortalNode>();
/** . */
- private final StructuralStateContextImpl structuralStateContext;
+ private final PortalNodeManager structuralStateContext;
/** . */
- private final String id;
+ final String id;
/** . */
- private final String name;
+ private boolean valid;
/** . */
- private boolean valid;
+ final String name;
/** . */
- private final Map<String, Serializable> properties;
+ final Map<String, Serializable> properties;
- protected PortalNode(String name, StructuralStateContextImpl structuralStateContext)
+ protected PortalNode(String name, PortalNodeManager structuralStateContext)
{
this.name = name;
this.id = structuralStateContext.nextId();
@@ -79,112 +73,6 @@
public abstract Class<? extends UIObject> getType();
- Collection<StructuralObject> takeChildrenSnapshot(StructuralObject structuralObject)
- {
- synchronized (this)
- {
- if (!takeSnapshot().equals(structuralObject))
- {
- throw new StaleStateException();
- }
-
- //
- Set<StructuralObject> structuralChildren = new HashSet<StructuralObject>();
- for (PortalNode child : children.values())
- {
- structuralChildren.add(child.takeSnapshot());
- }
-
- //
- return structuralChildren;
- }
- }
-
- StructuralObject takeParentSnapshot(StructuralObject structuralObject)
- {
- synchronized (this)
- {
- if (!takeSnapshot().equals(structuralObject))
- {
- throw new StaleStateException();
- }
-
- //
- return parent != null ? parent.takeSnapshot() : null;
- }
- }
-
- StructuralObject takeSnapshot()
- {
- synchronized (this)
- {
- StructuralStateImpl state = new StructuralStateImpl(
- getType(),
- name,
- Collections.unmodifiableMap(new HashMap<String, Serializable>(properties)));
-
- //
- Set<String> childrenIds = new HashSet<String>();
- for (PortalNode child : children.values())
- {
- childrenIds.add(child.id);
- }
-
- //
- String parentId = parent != null ? parent.id : null;
-
- //
- return new StructuralObjectImpl(id, parentId, Collections.unmodifiableSet(childrenIds), state);
- }
- }
-
- StructuralObject.Refresh refresh(StructuralObjectImpl structuralObject)
- {
- synchronized (this)
- {
- Map<String, PortalNode> childrenMap = new HashMap<String, PortalNode>();
- for (PortalNode child : children.values())
- {
- childrenMap.put(child.getId(), child);
- }
-
- //
- Map<String, PortalNode> addedChildrenMap = new HashMap<String, PortalNode>(childrenMap);
- addedChildrenMap.keySet().removeAll(structuralObject.getChildrenIds());
-
- //
- Map<String, PortalNode> staleChildren = new HashMap<String, PortalNode>(childrenMap);
- staleChildren.keySet().retainAll(structuralObject.getChildrenIds());
-
- //
- Set<String> removedChildrenIds = new HashSet<String>(structuralObject.getChildrenIds());
- removedChildrenIds.removeAll(staleChildren.keySet());
-
- //
- Set<StructuralObject> addedStructuralChildren = new HashSet<StructuralObject>();
- for (PortalNode addedChild : addedChildrenMap.values())
- {
- addedStructuralChildren.add(addedChild.takeSnapshot());
- }
-
- //
- Map<String, StructuralObject> staleStructuralChildren = new HashMap<String, StructuralObject>();
- for (PortalNode stateChild : staleChildren.values())
- {
- staleStructuralChildren.put(stateChild.getId(), stateChild.takeSnapshot());
- }
-
- //
- return new StructuralObject.Refresh(
- parent != null ? parent.takeSnapshot() : null,
- takeSnapshot(),
- addedStructuralChildren,
- removedChildrenIds,
- staleStructuralChildren,
- EMPTY_STRING_SET);
- }
- }
-
public boolean isValid()
{
return valid;
@@ -210,6 +98,11 @@
return Collections.unmodifiableSet(properties.keySet());
}
+ public Map<String, Serializable> getProperties()
+ {
+ return Collections.unmodifiableMap(properties);
+ }
+
public Serializable getProperty(String propertyName)
{
if (propertyName == null)
@@ -265,7 +158,7 @@
T child;
try
{
- Constructor<T> ctor = type.getConstructor(String.class, StructuralStateContextImpl.class);
+ Constructor<T> ctor = type.getConstructor(String.class, PortalNodeManager.class);
child = ctor.newInstance(name, structuralStateContext);
}
catch (InstantiationException e)
Added: modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/PortalNodeAdapter.java
===================================================================
--- modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/PortalNodeAdapter.java (rev 0)
+++ modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/PortalNodeAdapter.java 2008-06-03 13:02:14 UTC (rev 10911)
@@ -0,0 +1,158 @@
+/******************************************************************************
+ * 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.presentation.portal.model;
+
+import org.jboss.portal.presentation.portal.model.structural.StructuralAdapter;
+import org.jboss.portal.presentation.model.ui.UIObject;
+import org.jboss.portal.presentation.state.structural.StructuralState;
+import org.jboss.portal.common.NotYetImplemented;
+
+import java.util.Collection;
+import java.util.Map;
+import java.util.HashMap;
+import java.io.Serializable;
+
+/**
+ * @author <a href="mailto:julien@jboss-portal.org">Julien Viet</a>
+ * @version $Revision: 630 $
+ */
+public class PortalNodeAdapter implements StructuralAdapter<Object>
+{
+
+ /** . */
+ private PortalNodeManager nodeManager;
+
+ public PortalNodeAdapter(PortalNodeManager nodeManager)
+ {
+ this.nodeManager = nodeManager;
+ }
+
+ public String getRootId()
+ {
+ return nodeManager.getRoot().getId();
+ }
+
+ public Object getNode(String id)
+ {
+ return nodeManager.getNode(id);
+ }
+
+ public Object getParent(Object o)
+ {
+ if (o instanceof PortalNode)
+ {
+ return ((PortalNode)o).getParent();
+ }
+ else
+ {
+ throw new NotYetImplemented();
+ }
+ }
+
+ public Collection<?> getChilren(Object o)
+ {
+ if (o instanceof PortalNode)
+ {
+ return ((PortalNode)o).getChildren();
+ }
+ else
+ {
+ throw new NotYetImplemented();
+ }
+ }
+
+ public String getId(Object o)
+ {
+ if (o instanceof PortalNode)
+ {
+ return ((PortalNode)o).getId();
+ }
+ else
+ {
+ throw new NotYetImplemented();
+ }
+ }
+
+ public Class<? extends UIObject> getType(Object o)
+ {
+ if (o instanceof PortalNode)
+ {
+ return ((PortalNode)o).getType();
+ }
+ else
+ {
+ throw new NotYetImplemented();
+ }
+ }
+
+ public String getName(Object o)
+ {
+ if (o instanceof PortalNode)
+ {
+ return ((PortalNode)o).getName();
+ }
+ else
+ {
+ throw new NotYetImplemented();
+ }
+ }
+
+ public Map<String, Serializable> getProperties(Object o)
+ {
+ if (o instanceof PortalNode)
+ {
+ return ((PortalNode)o).getProperties();
+ }
+ else
+ {
+ throw new NotYetImplemented();
+ }
+ }
+
+ public StructuralState getState(Object o)
+ {
+ if (o instanceof PortalNode)
+ {
+ PortalNode portalNode = (PortalNode)o;
+
+ //
+ return new PortalNodeState(
+ portalNode.getType(),
+ portalNode.getName(),
+ new HashMap<String, Serializable>(portalNode.getProperties())
+ );
+ }
+ else
+ {
+ throw new NotYetImplemented();
+ }
+ }
+
+ public void lock(Object o)
+ {
+ }
+
+ public void unlock(Object o)
+ {
+ }
+}
Copied: modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/PortalNodeManager.java (from rev 10906, modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/StructuralStateContextImpl.java)
===================================================================
--- modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/PortalNodeManager.java (rev 0)
+++ modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/PortalNodeManager.java 2008-06-03 13:02:14 UTC (rev 10911)
@@ -0,0 +1,105 @@
+/******************************************************************************
+ * 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.presentation.portal.model;
+
+import org.jboss.portal.presentation.state.structural.StructuralStateContext;
+import org.jboss.portal.presentation.portal.model.structural.StructuralStateContextImpl;
+
+import java.util.concurrent.ConcurrentHashMap;
+import java.util.concurrent.ConcurrentMap;
+import java.util.concurrent.atomic.AtomicLong;
+
+/**
+ * @author <a href="mailto:julien@jboss-portal.org">Julien Viet</a>
+ * @version $Revision: 630 $
+ */
+public class PortalNodeManager
+{
+
+ /** . */
+ private final AtomicLong sequence = new AtomicLong();
+
+ /** . */
+ final ConcurrentMap<String, PortalNode> nodes = new ConcurrentHashMap<String, PortalNode>();
+
+ /** . */
+ private final ContextNode root = new ContextNode("", this);
+
+ /** . */
+ private final StructuralStateContext structuralStateContext;
+
+ public PortalNodeManager()
+ {
+ nodes.put(root.getId(), root);
+ structuralStateContext = new StructuralStateContextImpl<Object>(new PortalNodeAdapter(this));
+ }
+
+ String nextId()
+ {
+ return Long.toString(sequence.getAndIncrement());
+ }
+
+ public StructuralStateContext getStructuralStateContext()
+ {
+ return structuralStateContext;
+ }
+
+ public PortalNode getNode(String nodeId)
+ {
+ if (nodeId == null)
+ {
+ throw new IllegalArgumentException();
+ }
+
+ //
+ return nodes.get(nodeId);
+ }
+
+ public ContextNode getRoot()
+ {
+ return root;
+ }
+
+ public void destroy(String objectId)
+ {
+ if (objectId == null)
+ {
+ throw new IllegalArgumentException();
+ }
+
+ //
+ PortalNode node = nodes.get(objectId);
+
+ //
+ PortalNode parent = node.getParent();
+
+ //
+ if (parent == null)
+ {
+ throw new IllegalArgumentException("Cannot destroy root");
+ }
+
+ //
+ parent.destroyChild(node.getName());
+ }
+}
Copied: modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/PortalNodeState.java (from rev 10905, modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/StructuralStateImpl.java)
===================================================================
--- modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/PortalNodeState.java (rev 0)
+++ modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/PortalNodeState.java 2008-06-03 13:02:14 UTC (rev 10911)
@@ -0,0 +1,99 @@
+/******************************************************************************
+ * 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.presentation.portal.model;
+
+import org.jboss.portal.presentation.model.ui.UIObject;
+import org.jboss.portal.presentation.state.structural.StructuralState;
+
+import java.util.Map;
+import java.io.Serializable;
+
+/**
+ * @author <a href="mailto:julien@jboss-portal.org">Julien Viet</a>
+ * @version $Revision: 630 $
+ */
+public class PortalNodeState implements StructuralState
+{
+
+ /** . */
+ private final Class<? extends UIObject> type;
+
+ /** . */
+ private final String name;
+
+ /** . */
+ private final Map<String, Serializable> properties;
+
+ public PortalNodeState(
+ Class<? extends UIObject> type,
+ String name,
+ Map<String, Serializable> properties)
+ {
+ this.type = type;
+ this.name = name;
+ this.properties = properties;
+ }
+
+ public Class<? extends UIObject> getType()
+ {
+ return type;
+ }
+
+ public String getName()
+ {
+ return name;
+ }
+
+ public Map<String, Serializable> getProperties()
+ {
+ return properties;
+ }
+
+ public boolean equals(Object obj)
+ {
+ if (obj == this)
+ {
+ return true;
+ }
+ if (obj instanceof PortalNodeState)
+ {
+ PortalNodeState that = (PortalNodeState)obj;
+
+ //
+ if (!that.type.equals(this.type))
+ {
+ return false;
+ }
+
+ //
+ if (!that.name.equals(this.name))
+ {
+ return false;
+ }
+
+ //
+ return that.properties.equals(this.properties);
+ }
+ return false;
+ }
+}
Deleted: modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/StructuralNode.java
===================================================================
--- modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/StructuralNode.java 2008-06-03 11:44:57 UTC (rev 10910)
+++ modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/StructuralNode.java 2008-06-03 13:02:14 UTC (rev 10911)
@@ -1,353 +0,0 @@
-/******************************************************************************
- * 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.presentation.portal.model;
-
-import org.jboss.portal.presentation.model.ui.UIObject;
-import org.jboss.portal.presentation.state.StaleStateException;
-import org.jboss.portal.presentation.state.structural.StructuralObject;
-
-import java.lang.reflect.Constructor;
-import java.lang.reflect.InvocationTargetException;
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.Collections;
-import java.util.HashMap;
-import java.util.HashSet;
-import java.util.Map;
-import java.util.Set;
-import java.io.Serializable;
-
-/**
- * @author <a href="mailto:julien@jboss-portal.org">Julien Viet</a>
- * @version $Revision: 630 $
- */
-public abstract class StructuralNode
-{
-
- /** . */
- private final Set<String> EMPTY_STRING_SET = Collections.emptySet();
-
- /** . */
- private StructuralNode parent;
-
- /** . */
- private final Map<String, StructuralNode> children = new HashMap<String, StructuralNode>();
-
- /** . */
- private final StructuralStateContextImpl structuralStateContext;
-
- /** . */
- private final String id;
-
- /** . */
- private final String name;
-
- /** . */
- private boolean valid;
-
- /** . */
- private final Map<String, Serializable> properties;
-
- protected StructuralNode(String name, StructuralStateContextImpl structuralStateContext)
- {
- this.name = name;
- this.id = structuralStateContext.nextId();
- this.structuralStateContext = structuralStateContext;
- this.properties = new HashMap<String, Serializable>();
- this.valid = true;
- }
-
- public abstract Class<? extends UIObject> getType();
-
- Collection<StructuralObject> takeChildrenSnapshot(StructuralObject structuralObject)
- {
- synchronized (this)
- {
- if (!takeSnapshot().equals(structuralObject))
- {
- throw new StaleStateException();
- }
-
- //
- Set<StructuralObject> structuralChildren = new HashSet<StructuralObject>();
- for (StructuralNode child : children.values())
- {
- structuralChildren.add(child.takeSnapshot());
- }
-
- //
- return structuralChildren;
- }
- }
-
- StructuralObject takeParentSnapshot(StructuralObject structuralObject)
- {
- synchronized (this)
- {
- if (!takeSnapshot().equals(structuralObject))
- {
- throw new StaleStateException();
- }
-
- //
- return parent != null ? parent.takeSnapshot() : null;
- }
- }
-
- StructuralObject takeSnapshot()
- {
- synchronized (this)
- {
- StructuralStateImpl state = new StructuralStateImpl(
- getType(),
- name,
- Collections.unmodifiableMap(new HashMap<String, Serializable>(properties)));
-
- //
- Set<String> childrenIds = new HashSet<String>();
- for (StructuralNode child : children.values())
- {
- childrenIds.add(child.id);
- }
-
- //
- String parentId = parent != null ? parent.id : null;
-
- //
- return new StructuralObjectImpl(id, parentId, Collections.unmodifiableSet(childrenIds), state);
- }
- }
-
- StructuralObject.Refresh refresh(StructuralObjectImpl structuralObject)
- {
- synchronized (this)
- {
- Map<String, StructuralNode> childrenMap = new HashMap<String, StructuralNode>();
- for (StructuralNode child : children.values())
- {
- childrenMap.put(child.getId(), child);
- }
-
- //
- Map<String, StructuralNode> addedChildrenMap = new HashMap<String, StructuralNode>(childrenMap);
- addedChildrenMap.keySet().removeAll(structuralObject.getChildrenIds());
-
- //
- Map<String, StructuralNode> staleChildren = new HashMap<String, StructuralNode>(childrenMap);
- staleChildren.keySet().retainAll(structuralObject.getChildrenIds());
-
- //
- Set<String> removedChildrenIds = new HashSet<String>(structuralObject.getChildrenIds());
- removedChildrenIds.removeAll(staleChildren.keySet());
-
- //
- Set<StructuralObject> addedStructuralChildren = new HashSet<StructuralObject>();
- for (StructuralNode addedChild : addedChildrenMap.values())
- {
- addedStructuralChildren.add(addedChild.takeSnapshot());
- }
-
- //
- Map<String, StructuralObject> staleStructuralChildren = new HashMap<String, StructuralObject>();
- for (StructuralNode stateChild : staleChildren.values())
- {
- staleStructuralChildren.put(stateChild.getId(), stateChild.takeSnapshot());
- }
-
- //
- return new StructuralObject.Refresh(
- parent != null ? parent.takeSnapshot() : null,
- takeSnapshot(),
- addedStructuralChildren,
- removedChildrenIds,
- staleStructuralChildren,
- EMPTY_STRING_SET);
- }
- }
-
- public boolean isValid()
- {
- return valid;
- }
-
- public String getId()
- {
- return id;
- }
-
- public String getName()
- {
- return name;
- }
-
- public StructuralNode getParent()
- {
- return parent;
- }
-
- public Set<String> getPropertyNames()
- {
- return Collections.unmodifiableSet(properties.keySet());
- }
-
- public Serializable getProperty(String propertyName)
- {
- if (propertyName == null)
- {
- throw new IllegalArgumentException("No null property name");
- }
-
- //
- synchronized (this)
- {
- return properties.get(propertyName);
- }
- }
-
- public void setProperty(String propertyName, Serializable propertyValue)
- {
- if (propertyName == null)
- {
- throw new IllegalArgumentException("No null property name");
- }
-
- //
- synchronized (this)
- {
- if (propertyValue != null)
- {
- properties.put(propertyName, propertyValue);
- }
- else
- {
- properties.remove(propertyName);
- }
- }
- }
-
- public Collection<? extends StructuralNode> getChildren()
- {
- return Collections.unmodifiableCollection(children.values());
- }
-
- public <T extends StructuralNode> T addChild(String name, Class<T> type)
- {
- if (name == null)
- {
- throw new IllegalArgumentException();
- }
- if (type == null)
- {
- throw new IllegalArgumentException();
- }
-
- //
- T child;
- try
- {
- Constructor<T> ctor = type.getConstructor(String.class, StructuralStateContextImpl.class);
- child = ctor.newInstance(name, structuralStateContext);
- }
- catch (InstantiationException e)
- {
- throw new AssertionError(e);
- }
- catch (IllegalAccessException e)
- {
- throw new AssertionError(e);
- }
- catch (NoSuchMethodException e)
- {
- throw new AssertionError(e);
- }
- catch (InvocationTargetException e)
- {
- throw new AssertionError(e);
- }
-
- //
- synchronized (this)
- {
- if (children.containsKey(name))
- {
- throw new IllegalArgumentException("Child already exist");
- }
- children.put(name, child);
- child.parent = this;
- }
-
- //
- structuralStateContext.nodes.put(child.id, child);
-
- //
- return child;
- }
-
- public void destroyChild(String name)
- {
- if (name == null)
- {
- throw new IllegalArgumentException();
- }
-
- //
- StructuralNode child;
- synchronized (this)
- {
- if (!children.containsKey(name))
- {
- throw new IllegalArgumentException("No such child " + name);
- }
-
- child = children.get(name);
-
- //
- for (String blah : new ArrayList<String>(child.children.keySet()))
- {
- child.destroyChild(blah);
- }
-
- //
- children.remove(name);
- structuralStateContext.nodes.remove(child.id);
-
- //
- child.valid = false;
- child.parent = null;
- }
- }
-
- public StructuralNode getChild(String name)
- {
- if (name == null)
- {
- throw new IllegalArgumentException();
- }
-
- //
- synchronized (this)
- {
- return children.get(name);
- }
- }
-}
Deleted: modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/StructuralObjectImpl.java
===================================================================
--- modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/StructuralObjectImpl.java 2008-06-03 11:44:57 UTC (rev 10910)
+++ modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/StructuralObjectImpl.java 2008-06-03 13:02:14 UTC (rev 10911)
@@ -1,121 +0,0 @@
-/******************************************************************************
- * 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.presentation.portal.model;
-
-import org.jboss.portal.presentation.state.structural.StructuralObject;
-import org.jboss.portal.presentation.state.structural.StructuralState;
-
-import java.util.Set;
-
-/**
- * @author <a href="mailto:julien@jboss-portal.org">Julien Viet</a>
- * @version $Revision: 630 $
- */
-public class StructuralObjectImpl implements StructuralObject
-{
-
- /** . */
- private final String id;
-
- /** . */
- private final StructuralStateImpl state;
-
- /** . */
- private final String parentId;
-
- /** . */
- private final Set<String> childrenIds;
-
- public StructuralObjectImpl(
- String id,
- String parentId,
- Set<String> childrenIds,
- StructuralStateImpl state)
- {
- this.id = id;
- this.parentId = parentId;
- this.childrenIds = childrenIds;
- this.state = state;
- }
-
- String getParentId()
- {
- return parentId;
- }
-
- Set<String> getChildrenIds()
- {
- return childrenIds;
- }
-
- public String getId()
- {
- return id;
- }
-
- public StructuralState getState()
- {
- return state;
- }
-
- public boolean equals(Object obj)
- {
- if (obj == this)
- {
- return true;
- }
- if (obj instanceof StructuralObjectImpl)
- {
- StructuralObjectImpl that = (StructuralObjectImpl)obj;
-
- //
- if (!that.id.equals(this.id))
- {
- return false;
- }
-
- //
- if (!that.state.equals(this.state))
- {
- return false;
- }
-
- //
- if (that.parentId == null)
- {
- if (this.parentId != null)
- {
- return false;
- }
- }
- else if (!that.parentId.equals(this.parentId))
- {
- return false;
- }
-
- //
- return that.childrenIds.equals(this.childrenIds);
- }
- return false;
- }
-}
Deleted: modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/StructuralStateContextImpl.java
===================================================================
--- modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/StructuralStateContextImpl.java 2008-06-03 11:44:57 UTC (rev 10910)
+++ modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/StructuralStateContextImpl.java 2008-06-03 13:02:14 UTC (rev 10911)
@@ -1,202 +0,0 @@
-/******************************************************************************
- * 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.presentation.portal.model;
-
-import org.jboss.portal.presentation.state.NoSuchStateException;
-import org.jboss.portal.presentation.state.StaleStateException;
-import org.jboss.portal.presentation.state.StateException;
-import org.jboss.portal.presentation.state.structural.StructuralObject;
-import org.jboss.portal.presentation.state.structural.StructuralStateContext;
-
-import java.util.Collection;
-import java.util.concurrent.ConcurrentHashMap;
-import java.util.concurrent.ConcurrentMap;
-import java.util.concurrent.atomic.AtomicLong;
-
-/**
- * @author <a href="mailto:julien@jboss-portal.org">Julien Viet</a>
- * @version $Revision: 630 $
- */
-public class StructuralStateContextImpl implements StructuralStateContext
-{
-
- /** . */
- private final AtomicLong sequence = new AtomicLong();
-
- /** . */
- final ConcurrentMap<String, PortalNode> nodes = new ConcurrentHashMap<String, PortalNode>();
-
- /** . */
- private final ContextNode root = new ContextNode("", this);
-
- public StructuralStateContextImpl()
- {
- nodes.put(root.getId(), root);
- }
-
- String nextId()
- {
- return Long.toString(sequence.getAndIncrement());
- }
-
- public PortalNode getNode(String nodeId)
- {
- if (nodeId == null)
- {
- throw new IllegalArgumentException();
- }
-
- //
- return nodes.get(nodeId);
- }
-
- public ContextNode getRoot()
- {
- return root;
- }
-
- public void destroy(String objectId)
- {
- if (objectId == null)
- {
- throw new IllegalArgumentException();
- }
-
- //
- PortalNode node = nodes.get(objectId);
-
- //
- PortalNode parent = node.getParent();
-
- //
- if (parent == null)
- {
- throw new IllegalArgumentException("Cannot destroy root");
- }
-
- //
- parent.destroyChild(node.getName());
- }
-
- public StructuralObject load(String objectId) throws IllegalArgumentException
- {
- if (objectId == null)
- {
- throw new IllegalArgumentException();
- }
-
- //
- PortalNode node = nodes.get(objectId);
-
- //
- return node != null ? node.takeSnapshot() : null;
- }
-
- public Collection<StructuralObject> loadChildren(StructuralObject structuralParent) throws IllegalArgumentException, StateException
- {
- if (structuralParent == null)
- {
- throw new IllegalArgumentException();
- }
-
- //
- PortalNode parentNode = nodes.get(structuralParent.getId());
-
- //
- if (parentNode == null)
- {
- throw new NoSuchStateException();
- }
-
- //
- return parentNode.takeChildrenSnapshot(structuralParent);
- }
-
- public StructuralObject loadParent(StructuralObject structuralChild) throws IllegalArgumentException, StateException
- {
- if (structuralChild == null)
- {
- throw new IllegalArgumentException();
- }
-
- //
- PortalNode childNode = nodes.get(structuralChild.getId());
-
- //
- if (childNode == null)
- {
- throw new NoSuchStateException();
- }
-
- //
- return childNode.takeParentSnapshot(structuralChild);
- }
-
- public String getRootId()
- {
- return root.getId();
- }
-
- public void validate(StructuralObject structuralObject) throws IllegalArgumentException, StateException
- {
- if (structuralObject == null)
- {
- throw new IllegalArgumentException();
- }
-
- //
- PortalNode portalNode = nodes.get(structuralObject.getId());
-
- //
- if (portalNode == null)
- {
- throw new NoSuchStateException();
- }
-
- //
- if (!portalNode.takeSnapshot().equals(structuralObject))
- {
- throw new StaleStateException();
- }
- }
-
- public StructuralObject.Refresh refresh(StructuralObject structuralObject) throws IllegalArgumentException, StateException
- {
- if (structuralObject == null)
- {
- throw new IllegalArgumentException();
- }
-
- //
- PortalNode portalNode = nodes.get(structuralObject.getId());
-
- //
- if (portalNode == null)
- {
- throw new NoSuchStateException();
- }
-
- //
- return portalNode.refresh((StructuralObjectImpl)structuralObject);
- }
-}
Deleted: modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/StructuralStateImpl.java
===================================================================
--- modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/StructuralStateImpl.java 2008-06-03 11:44:57 UTC (rev 10910)
+++ modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/StructuralStateImpl.java 2008-06-03 13:02:14 UTC (rev 10911)
@@ -1,99 +0,0 @@
-/******************************************************************************
- * 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.presentation.portal.model;
-
-import org.jboss.portal.presentation.model.ui.UIObject;
-import org.jboss.portal.presentation.state.structural.StructuralState;
-
-import java.util.Map;
-import java.io.Serializable;
-
-/**
- * @author <a href="mailto:julien@jboss-portal.org">Julien Viet</a>
- * @version $Revision: 630 $
- */
-public class StructuralStateImpl implements StructuralState
-{
-
- /** . */
- private final Class<? extends UIObject> type;
-
- /** . */
- private final String name;
-
- /** . */
- private final Map<String, Serializable> properties;
-
- public StructuralStateImpl(
- Class<? extends UIObject> type,
- String name,
- Map<String, Serializable> properties)
- {
- this.type = type;
- this.name = name;
- this.properties = properties;
- }
-
- public Class<? extends UIObject> getType()
- {
- return type;
- }
-
- public String getName()
- {
- return name;
- }
-
- public Map<String, Serializable> getProperties()
- {
- return properties;
- }
-
- public boolean equals(Object obj)
- {
- if (obj == this)
- {
- return true;
- }
- if (obj instanceof StructuralStateImpl)
- {
- StructuralStateImpl that = (StructuralStateImpl)obj;
-
- //
- if (!that.type.equals(this.type))
- {
- return false;
- }
-
- //
- if (!that.name.equals(this.name))
- {
- return false;
- }
-
- //
- return that.properties.equals(this.properties);
- }
- return false;
- }
-}
Modified: modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/WindowNode.java
===================================================================
--- modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/WindowNode.java 2008-06-03 11:44:57 UTC (rev 10910)
+++ modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/WindowNode.java 2008-06-03 13:02:14 UTC (rev 10911)
@@ -39,7 +39,7 @@
/** . */
private Content content;
- public WindowNode(String name, StructuralStateContextImpl structuralStateContext)
+ public WindowNode(String name, PortalNodeManager structuralStateContext)
{
super(name, structuralStateContext);
}
Added: modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/structural/StructuralAdapter.java
===================================================================
--- modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/structural/StructuralAdapter.java (rev 0)
+++ modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/structural/StructuralAdapter.java 2008-06-03 13:02:14 UTC (rev 10911)
@@ -0,0 +1,61 @@
+/******************************************************************************
+ * 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.presentation.portal.model.structural;
+
+import org.jboss.portal.presentation.model.ui.UIObject;
+import org.jboss.portal.presentation.state.structural.StructuralState;
+
+import java.util.Collection;
+import java.util.Map;
+import java.io.Serializable;
+
+/**
+ * @author <a href="mailto:julien@jboss-portal.org">Julien Viet</a>
+ * @version $Revision: 630 $
+ */
+public interface StructuralAdapter<N>
+{
+
+ String getRootId();
+
+ N getNode(String id);
+
+ N getParent(N n);
+
+ Collection<? extends N> getChilren(N n);
+
+ String getId(N n);
+
+ Class<? extends UIObject> getType(N n);
+
+ String getName(N n);
+
+ Map<String, Serializable> getProperties(N n);
+
+ StructuralState getState(N n);
+
+ void lock(N n);
+
+ void unlock(N n);
+
+}
Added: modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/structural/StructuralObjectImpl.java
===================================================================
--- modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/structural/StructuralObjectImpl.java (rev 0)
+++ modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/structural/StructuralObjectImpl.java 2008-06-03 13:02:14 UTC (rev 10911)
@@ -0,0 +1,121 @@
+/******************************************************************************
+ * 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.presentation.portal.model.structural;
+
+import org.jboss.portal.presentation.state.structural.StructuralObject;
+import org.jboss.portal.presentation.state.structural.StructuralState;
+
+import java.util.Set;
+
+/**
+ * @author <a href="mailto:julien@jboss-portal.org">Julien Viet</a>
+ * @version $Revision: 630 $
+ */
+public class StructuralObjectImpl implements StructuralObject
+{
+
+ /** . */
+ private final String id;
+
+ /** . */
+ private final StructuralState state;
+
+ /** . */
+ private final String parentId;
+
+ /** . */
+ private final Set<String> childrenIds;
+
+ public StructuralObjectImpl(
+ String id,
+ String parentId,
+ Set<String> childrenIds,
+ StructuralState state)
+ {
+ this.id = id;
+ this.parentId = parentId;
+ this.childrenIds = childrenIds;
+ this.state = state;
+ }
+
+ String getParentId()
+ {
+ return parentId;
+ }
+
+ Set<String> getChildrenIds()
+ {
+ return childrenIds;
+ }
+
+ public String getId()
+ {
+ return id;
+ }
+
+ public StructuralState getState()
+ {
+ return state;
+ }
+
+ public boolean equals(Object obj)
+ {
+ if (obj == this)
+ {
+ return true;
+ }
+ if (obj instanceof StructuralObjectImpl)
+ {
+ StructuralObjectImpl that = (StructuralObjectImpl)obj;
+
+ //
+ if (!that.id.equals(this.id))
+ {
+ return false;
+ }
+
+ //
+ if (!that.state.equals(this.state))
+ {
+ return false;
+ }
+
+ //
+ if (that.parentId == null)
+ {
+ if (this.parentId != null)
+ {
+ return false;
+ }
+ }
+ else if (!that.parentId.equals(this.parentId))
+ {
+ return false;
+ }
+
+ //
+ return that.childrenIds.equals(this.childrenIds);
+ }
+ return false;
+ }
+}
\ No newline at end of file
Added: modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/structural/StructuralStateContextImpl.java
===================================================================
--- modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/structural/StructuralStateContextImpl.java (rev 0)
+++ modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/structural/StructuralStateContextImpl.java 2008-06-03 13:02:14 UTC (rev 10911)
@@ -0,0 +1,267 @@
+/******************************************************************************
+ * 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.presentation.portal.model.structural;
+
+import org.jboss.portal.presentation.state.NoSuchStateException;
+import org.jboss.portal.presentation.state.StaleStateException;
+import org.jboss.portal.presentation.state.StateException;
+import org.jboss.portal.presentation.state.structural.StructuralObject;
+import org.jboss.portal.presentation.state.structural.StructuralStateContext;
+import org.jboss.portal.presentation.state.structural.StructuralState;
+
+import java.util.Collection;
+import java.util.Collections;
+import java.util.HashMap;
+import java.util.Set;
+import java.util.HashSet;
+import java.util.Map;
+
+/**
+ * @author <a href="mailto:julien@jboss-portal.org">Julien Viet</a>
+ * @version $Revision: 630 $
+ */
+public class StructuralStateContextImpl<N> implements StructuralStateContext
+{
+
+ /** . */
+ private final Set<String> EMPTY_STRING_SET = Collections.emptySet();
+
+ /** . */
+ private final StructuralAdapter<N> adapter;
+
+ public StructuralStateContextImpl(StructuralAdapter<N> adapter)
+ {
+ this.adapter = adapter;
+ }
+
+ public StructuralObject load(String objectId) throws IllegalArgumentException
+ {
+ if (objectId == null)
+ {
+ throw new IllegalArgumentException();
+ }
+
+ //
+ N node = adapter.getNode(objectId);
+
+ //
+ return node != null ? takeSnapshot(node) : null;
+ }
+
+ private StructuralObjectImpl takeSnapshot(N node)
+ {
+ adapter.lock(node);
+
+ //
+ try
+ {
+ StructuralState state = adapter.getState(node);
+
+ //
+ Set<String> childrenIds = new HashSet<String>();
+ for (N childNode : adapter.getChilren(node))
+ {
+ childrenIds.add(adapter.getId(childNode));
+ }
+
+ //
+ N parent = adapter.getParent(node);
+
+ //
+ String parentId = parent != null ? adapter.getId(parent) : null;
+
+ //
+ return new StructuralObjectImpl(adapter.getId(node), parentId, Collections.unmodifiableSet(childrenIds), state);
+ }
+ finally
+ {
+ adapter.unlock(node);
+ }
+ }
+
+ public Collection<StructuralObject> loadChildren(StructuralObject structuralParent) throws IllegalArgumentException, StateException
+ {
+ if (structuralParent == null)
+ {
+ throw new IllegalArgumentException();
+ }
+
+ //
+ N parentNode = adapter.getNode(structuralParent.getId());
+
+ //
+ if (parentNode == null)
+ {
+ throw new NoSuchStateException();
+ }
+
+ if (!takeSnapshot(parentNode).equals(structuralParent))
+ {
+ throw new StaleStateException();
+ }
+
+ // todo : the returned children node might have changed before we take the snapshot we need to find a way to prevent that
+
+ //
+ Set<StructuralObject> structuralChildren = new HashSet<StructuralObject>();
+ for (N childNode : adapter.getChilren(parentNode))
+ {
+ structuralChildren.add(takeSnapshot(childNode));
+ }
+
+ //
+ return structuralChildren;
+ }
+
+ public StructuralObject loadParent(StructuralObject structuralChild) throws IllegalArgumentException, StateException
+ {
+ if (structuralChild == null)
+ {
+ throw new IllegalArgumentException();
+ }
+
+ //
+ N childNode = adapter.getNode(structuralChild.getId());
+
+ //
+ if (childNode == null)
+ {
+ throw new NoSuchStateException();
+ }
+
+ //
+ if (!takeSnapshot(childNode).equals(structuralChild))
+ {
+ throw new StaleStateException();
+ }
+
+ //
+ N parentNode = adapter.getParent(childNode);
+
+ // todo : the returned parent node might have changed before we take the snapshot we need to find a way to prevent that
+
+ //
+ return parentNode != null ? takeSnapshot(parentNode) : null;
+ }
+
+ public String getRootId()
+ {
+ return adapter.getRootId();
+ }
+
+ public void validate(StructuralObject structuralObject) throws IllegalArgumentException, StateException
+ {
+ if (structuralObject == null)
+ {
+ throw new IllegalArgumentException();
+ }
+
+ //
+ N node = adapter.getNode(structuralObject.getId());
+
+ //
+ if (node == null)
+ {
+ throw new NoSuchStateException();
+ }
+
+ //
+ if (!takeSnapshot(node).equals(structuralObject))
+ {
+ throw new StaleStateException();
+ }
+ }
+
+ public StructuralObject.Refresh refresh(StructuralObject structuralObject) throws IllegalArgumentException, StateException
+ {
+ return refresh((StructuralObjectImpl)structuralObject);
+
+ }
+
+ /**
+ * todo : implement correct concurrency
+ */
+ private StructuralObject.Refresh refresh(StructuralObjectImpl structuralObject) throws IllegalArgumentException, StateException
+ {
+ if (structuralObject == null)
+ {
+ throw new IllegalArgumentException();
+ }
+
+ //
+ N node = adapter.getNode(structuralObject.getId());
+
+ //
+ if (node == null)
+ {
+ throw new NoSuchStateException();
+ }
+
+ //
+ StructuralObjectImpl nodeSnapshot = takeSnapshot(node);
+
+ Map<String, N> childrenMap = new HashMap<String, N>();
+ for (N childNode : adapter.getChilren(node))
+ {
+ childrenMap.put(adapter.getId(childNode), childNode);
+ }
+
+ //
+ Map<String, N> addedChildrenMap = new HashMap<String, N>(childrenMap);
+ addedChildrenMap.keySet().removeAll(structuralObject.getChildrenIds());
+
+ //
+ Map<String, N> staleChildren = new HashMap<String, N>(childrenMap);
+ staleChildren.keySet().retainAll(structuralObject.getChildrenIds());
+
+ //
+ Set<String> removedChildrenIds = new HashSet<String>(structuralObject.getChildrenIds());
+ removedChildrenIds.removeAll(staleChildren.keySet());
+
+ //
+ Set<StructuralObject> addedStructuralChildren = new HashSet<StructuralObject>();
+ for (N addedChild : addedChildrenMap.values())
+ {
+ addedStructuralChildren.add(takeSnapshot(addedChild));
+ }
+
+ //
+ Map<String, StructuralObject> staleStructuralChildren = new HashMap<String, StructuralObject>();
+ for (N staleChildNode : staleChildren.values())
+ {
+ staleStructuralChildren.put(adapter.getId(staleChildNode), takeSnapshot(staleChildNode));
+ }
+
+ //
+ N parentNode = adapter.getParent(node);
+
+ //
+ return new StructuralObject.Refresh(
+ parentNode != null ? takeSnapshot(parentNode) : null,
+ nodeSnapshot,
+ addedStructuralChildren,
+ removedChildrenIds,
+ staleStructuralChildren,
+ EMPTY_STRING_SET);
+ }
+}
\ No newline at end of file
Modified: modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/servlet/StructuralStateContextImporter.java
===================================================================
--- modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/servlet/StructuralStateContextImporter.java 2008-06-03 11:44:57 UTC (rev 10910)
+++ modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/servlet/StructuralStateContextImporter.java 2008-06-03 13:02:14 UTC (rev 10911)
@@ -22,7 +22,7 @@
******************************************************************************/
package org.jboss.portal.presentation.portal.servlet;
-import org.jboss.portal.presentation.portal.model.StructuralStateContextImpl;
+import org.jboss.portal.presentation.portal.model.PortalNodeManager;
import org.jboss.portal.presentation.portal.model.NodeImporter;
import org.jboss.portal.presentation.portal.model.ContextNode;
import org.jboss.portal.common.io.IOTools;
@@ -41,7 +41,7 @@
private ServletContext servletContext;
/** . */
- private StructuralStateContextImpl structuralStateContext;
+ private PortalNodeManager structuralStateContext;
public ServletContext getServletContext()
{
@@ -53,12 +53,12 @@
this.servletContext = servletContext;
}
- public StructuralStateContextImpl getStructuralStateContext()
+ public PortalNodeManager getStructuralStateContext()
{
return structuralStateContext;
}
- public void setStructuralStateContext(StructuralStateContextImpl structuralStateContext)
+ public void setStructuralStateContext(PortalNodeManager structuralStateContext)
{
this.structuralStateContext = structuralStateContext;
}
Modified: modules/presentation/trunk/portal/src/test/java/org/jboss/portal/presentation/portal/model/StructuralStateContextTestCase.java
===================================================================
--- modules/presentation/trunk/portal/src/test/java/org/jboss/portal/presentation/portal/model/StructuralStateContextTestCase.java 2008-06-03 11:44:57 UTC (rev 10910)
+++ modules/presentation/trunk/portal/src/test/java/org/jboss/portal/presentation/portal/model/StructuralStateContextTestCase.java 2008-06-03 13:02:14 UTC (rev 10911)
@@ -42,11 +42,11 @@
{
/** . */
- private StructuralStateContextImpl structuralStateContext;
+ private PortalNodeManager structuralStateContext;
protected StructuralStateContext getStructuralStateContext()
{
- return structuralStateContext;
+ return structuralStateContext.getStructuralStateContext();
}
protected PortalNode getRoot()
@@ -132,6 +132,6 @@
protected void setUp() throws Exception
{
- structuralStateContext = new StructuralStateContextImpl();
+ structuralStateContext = new PortalNodeManager();
}
}
17 years, 11 months
JBoss Portal SVN: r10910 - docs/branches/JBoss_Portal_Branch_2_6/referenceGuide/en/modules.
by portal-commits@lists.jboss.org
Author: mmcallis
Date: 2008-06-03 07:44:57 -0400 (Tue, 03 Jun 2008)
New Revision: 10910
Modified:
docs/branches/JBoss_Portal_Branch_2_6/referenceGuide/en/modules/installation.xml
docs/branches/JBoss_Portal_Branch_2_6/referenceGuide/en/modules/supported.xml
Log:
fixing oracle trademarks
(http://www.oracle.com/html/3party.html)
Modified: docs/branches/JBoss_Portal_Branch_2_6/referenceGuide/en/modules/installation.xml
===================================================================
--- docs/branches/JBoss_Portal_Branch_2_6/referenceGuide/en/modules/installation.xml 2008-06-03 11:30:56 UTC (rev 10909)
+++ docs/branches/JBoss_Portal_Branch_2_6/referenceGuide/en/modules/installation.xml 2008-06-03 11:44:57 UTC (rev 10910)
@@ -89,7 +89,7 @@
<sect3>
<title>Database Setup</title>
<para>
- A database is required for JBoss Portal to run. JBoss EAP and JBoss AS include an embedded Hypersonic SQL database that JBoss Portal can use; however, this is only recommended for developer use. The following databases are recommended for production use, and have had test suites run against them: MySQL 4, MySQL 5, <trademark class="registered">Microsoft SQL Server</trademark>, PostgreSQL 8, Oracle 9, and Oracle 10. JBoss Portal can use any database that is supported by Hibernate.
+ A database is required for JBoss Portal to run. JBoss EAP and JBoss AS include an embedded Hypersonic SQL database that JBoss Portal can use; however, this is only recommended for developer use. The following databases are recommended for production use, and have had test suites run against them: MySQL 4, MySQL 5, <trademark class="registered">Microsoft SQL Server</trademark>, PostgreSQL 8, <trademark class="registered">Oracle</trademark> Database 9, and <trademark class="registered">Oracle</trademark> Database 10. JBoss Portal can use any database that is supported by Hibernate.
</para>
<para>
To configure a database to use with JBoss Portal:
@@ -117,7 +117,7 @@
<sect3>
<title>Datasource Descriptors</title>
<para>
- The JBoss Portal binary download that was extracted in <xref linkend="install_binarydownload"/>, contains pre-configured Datasource descriptors for the more popular databases. Datasource descriptors are provided for the MySQL 4, MySQL 5, PostgreSQL, <trademark class="registered">Microsoft SQL Server</trademark>, and Oracle databases, and can be found in the <filename>setup</filename> subdirectory where the JBoss Portal binary was extracted to:
+ The JBoss Portal binary download that was extracted in <xref linkend="install_binarydownload"/>, contains pre-configured Datasource descriptors for the more popular databases. Datasource descriptors are provided for the MySQL 4, MySQL 5, PostgreSQL, <trademark class="registered">Microsoft SQL Server</trademark>, and <trademark class="registered">Oracle</trademark> databases, and can be found in the <filename>setup</filename> subdirectory where the JBoss Portal binary was extracted to:
</para>
<mediaobject>
<imageobject>
@@ -384,7 +384,7 @@
<sect2>
<title>Database Setup</title>
<para>
- A database is required for JBoss Portal to run. JBoss EAP and JBoss AS include an embedded Hypersonic SQL database that JBoss Portal can use; however, this is only recommended for developer use. The following databases are recommended for production use, and have had test suites run against them: MySQL 4, MySQL 5, <trademark class="registered">Microsoft SQL Server</trademark>, PostgreSQL 8, Oracle 9, and Oracle 10. JBoss Portal can use any database that is supported by Hibernate.
+ A database is required for JBoss Portal to run. JBoss EAP and JBoss AS include an embedded Hypersonic SQL database that JBoss Portal can use; however, this is only recommended for developer use. The following databases are recommended for production use, and have had test suites run against them: MySQL 4, MySQL 5, <trademark class="registered">Microsoft SQL Server</trademark>, PostgreSQL 8, <trademark class="registered">Oracle</trademark> Database 9, and <trademark class="registered">Oracle</trademark> Database 10. JBoss Portal can use any database that is supported by Hibernate.
</para>
<para>
To configure a database to use with JBoss Portal:
@@ -412,7 +412,7 @@
<sect2>
<title>Datasource Configuration</title>
<para>
- The JBoss Portal binary download that was extracted in <xref linkend="install_binarydownload"/>, contains pre-configured Datasource descriptors for the more popular databases. Datasource descriptors are provided for the MySQL 4, MySQL 5, PostgreSQL, <trademark class="registered">Microsoft SQL Server</trademark>, and Oracle databases, and can be found in the <filename>setup</filename> subdirectory where the JBoss Portal binary was extracted to:
+ The JBoss Portal binary download that was extracted in <xref linkend="install_binarydownload"/>, contains pre-configured Datasource descriptors for the more popular databases. Datasource descriptors are provided for the MySQL 4, MySQL 5, PostgreSQL, <trademark class="registered">Microsoft SQL Server</trademark>, and <trademark class="registered">Oracle</trademark> databases, and can be found in the <filename>setup</filename> subdirectory where the JBoss Portal binary was extracted to:
</para>
<mediaobject>
<imageobject>
Modified: docs/branches/JBoss_Portal_Branch_2_6/referenceGuide/en/modules/supported.xml
===================================================================
--- docs/branches/JBoss_Portal_Branch_2_6/referenceGuide/en/modules/supported.xml 2008-06-03 11:30:56 UTC (rev 10909)
+++ docs/branches/JBoss_Portal_Branch_2_6/referenceGuide/en/modules/supported.xml 2008-06-03 11:44:57 UTC (rev 10910)
@@ -53,7 +53,7 @@
<listitem>PostgreSQL 8.<replaceable>x</replaceable></listitem>
<listitem>Hypersonic SQL</listitem>
<listitem>Derby</listitem>
- <listitem>Oracle 9 and 10g (use the <ulink url="http://www.oracle.com/technology/software/tech/java/sqlj_jdbc/index.html">latest driver from the Oracle 10 branch</ulink> even if you are running Oracle 9)</listitem>
+ <listitem><trademark class="registered">Oracle</trademark> Database 9 and 10g (use the <ulink url="http://www.oracle.com/technology/software/tech/java/sqlj_jdbc/index.html">latest driver from the Oracle 10 branch</ulink> even if you are running Oracle 9)</listitem>
<listitem><trademark class="registered">Microsoft SQL Server</trademark></listitem>
<listitem>MaxDB</listitem>
</itemizedlist>
17 years, 11 months
JBoss Portal SVN: r10909 - docs/branches/JBoss_Portal_Branch_2_6/referenceGuide/en/modules.
by portal-commits@lists.jboss.org
Author: mmcallis
Date: 2008-06-03 07:30:56 -0400 (Tue, 03 Jun 2008)
New Revision: 10909
Modified:
docs/branches/JBoss_Portal_Branch_2_6/referenceGuide/en/modules/security.xml
Log:
fixing UNIX (UNIX(R)) trademarks
Modified: docs/branches/JBoss_Portal_Branch_2_6/referenceGuide/en/modules/security.xml
===================================================================
--- docs/branches/JBoss_Portal_Branch_2_6/referenceGuide/en/modules/security.xml 2008-06-03 11:25:42 UTC (rev 10908)
+++ docs/branches/JBoss_Portal_Branch_2_6/referenceGuide/en/modules/security.xml 2008-06-03 11:30:56 UTC (rev 10909)
@@ -206,7 +206,7 @@
<xmbean/>
<!--
NOTE: cmsRootUserName denotes a single Portal user that has access to everything in the CMS. Denote this user
- carefully and should be synonymous to the 'root' user in a Unix system. By default: this value is the built-in
+ carefully and should be synonymous to the 'root' user in a UNIX system. By default: this value is the built-in
'admin' user account. This can be changed to any other user account registered in your Portal
-->
<attribute name="CmsRootUserName">admin</attribute>
@@ -268,7 +268,7 @@
<title>CMS Super User</title>
<para>
A CMS Super User is a designated Portal User Account that has access to all resources/functions in the CMS. It is a concept similar to the
- super user concept in a Linux/Unix security system. This account should be carefully used and properly protected. By default, JBoss Portal designates the
+ super user concept in a Linux and <trademark class="registered">UNIX</trademark> security system. This account should be carefully used and properly protected. By default, JBoss Portal designates the
built-in 'admin' user account as a CMS Super User. This can be changed by modifying the <emphasis>cmsRootUserName</emphasis> value in the
<literal>jboss-portal.sar/portal-cms.sar/META-INF/jboss-service.xml</literal> configuration.
<programlisting>
@@ -281,7 +281,7 @@
<xmbean/>
<!--
NOTE: cmsRootUserName denotes a single Portal user that has access to everything in the CMS. Denote this user
- carefully and should be synonymous to the 'root' user in a Unix system. By default: this value is the built-in
+ carefully and should be synonymous to the 'root' user in a UNIX system. By default: this value is the built-in
'admin' user account. This can be changed to any other user account registered in your Portal
-->
<attribute name="CmsRootUserName">admin</attribute>
17 years, 11 months
JBoss Portal SVN: r10908 - docs/branches/JBoss_Portal_Branch_2_6/referenceGuide/en/modules.
by portal-commits@lists.jboss.org
Author: mmcallis
Date: 2008-06-03 07:25:42 -0400 (Tue, 03 Jun 2008)
New Revision: 10908
Modified:
docs/branches/JBoss_Portal_Branch_2_6/referenceGuide/en/modules/configuration.xml
docs/branches/JBoss_Portal_Branch_2_6/referenceGuide/en/modules/identityportlets.xml
docs/branches/JBoss_Portal_Branch_2_6/referenceGuide/en/modules/installation.xml
docs/branches/JBoss_Portal_Branch_2_6/referenceGuide/en/modules/supported.xml
docs/branches/JBoss_Portal_Branch_2_6/referenceGuide/en/modules/tutorials.xml
docs/branches/JBoss_Portal_Branch_2_6/referenceGuide/en/modules/xmldescriptors.xml
Log:
fixing microsoft trademark usage
(http://www.microsoft.com/library/toolbar/3.0/trademarks/en-us.mspx)
Modified: docs/branches/JBoss_Portal_Branch_2_6/referenceGuide/en/modules/configuration.xml
===================================================================
--- docs/branches/JBoss_Portal_Branch_2_6/referenceGuide/en/modules/configuration.xml 2008-06-02 20:18:26 UTC (rev 10907)
+++ docs/branches/JBoss_Portal_Branch_2_6/referenceGuide/en/modules/configuration.xml 2008-06-03 11:25:42 UTC (rev 10908)
@@ -274,7 +274,7 @@
</screen>
</para>
<para>
- On Microsoft Windows systems, run the following command:
+ On Windows-based systems, run the following command:
</para>
<para>
<screen>
Modified: docs/branches/JBoss_Portal_Branch_2_6/referenceGuide/en/modules/identityportlets.xml
===================================================================
--- docs/branches/JBoss_Portal_Branch_2_6/referenceGuide/en/modules/identityportlets.xml 2008-06-02 20:18:26 UTC (rev 10907)
+++ docs/branches/JBoss_Portal_Branch_2_6/referenceGuide/en/modules/identityportlets.xml 2008-06-03 11:25:42 UTC (rev 10908)
@@ -818,7 +818,7 @@
<title>Enabling the Identity Portlets</title>
<para>
When migrating from former versions of JBoss Portal the Identity User Portlets won't be displayed by default,
- but Windows can be created on basis of the existing Portlet Instances which are deployed by default. (The instances
+ but windows can be created on basis of the existing Portlet Instances which are deployed by default. (The instances
names being <literal>IdentityUserPortletInstance</literal> and <literal>IdentityAdminPortletInstance</literal>.)
</para>
</sect2>
Modified: docs/branches/JBoss_Portal_Branch_2_6/referenceGuide/en/modules/installation.xml
===================================================================
--- docs/branches/JBoss_Portal_Branch_2_6/referenceGuide/en/modules/installation.xml 2008-06-02 20:18:26 UTC (rev 10907)
+++ docs/branches/JBoss_Portal_Branch_2_6/referenceGuide/en/modules/installation.xml 2008-06-03 11:25:42 UTC (rev 10908)
@@ -20,12 +20,12 @@
</listitem>
<listitem>
<para>
- <emphasis role="bold">Extract the bundle:</emphasis> extract the ZIP archive. It does not matter which directory is used. On Microsoft Windows, the recommended directory is <filename>C:\jboss-<replaceable>version-number</replaceable></filename>.
+ <emphasis role="bold">Extract the bundle:</emphasis> extract the ZIP archive. It does not matter which directory is used. On Windows-based systems, the recommended directory is <filename>C:\jboss-<replaceable>version-number</replaceable></filename>.
</para>
</listitem>
<listitem>
<para>
- <emphasis role="bold">Start the server:</emphasis> change into the <filename>JBOSS_PORTAL_INSTALLATION_DIRECTORY/bin/</filename> directory. On Microsoft Windows, execute <command>run.bat</command>. On Linux, run the <command>sh run.sh</command> command. To specify a configuration to use, for example, the default configuration, append the <command> -c default</command> option to the <command>run.bat</command> or <command>sh run.sh</command> commands.
+ <emphasis role="bold">Start the server:</emphasis> change into the <filename>JBOSS_PORTAL_INSTALLATION_DIRECTORY/bin/</filename> directory. On Windows-based systems, execute <command>run.bat</command>. On Linux, run the <command>sh run.sh</command> command. To specify a configuration to use, for example, the default configuration, append the <command> -c default</command> option to the <command>run.bat</command> or <command>sh run.sh</command> commands.
</para>
</listitem>
<listitem>
@@ -89,7 +89,7 @@
<sect3>
<title>Database Setup</title>
<para>
- A database is required for JBoss Portal to run. JBoss EAP and JBoss AS include an embedded Hypersonic SQL database that JBoss Portal can use; however, this is only recommended for developer use. The following databases are recommended for production use, and have had test suites run against them: MySQL 4, MySQL 5, Microsoft SQL Server, PostgreSQL 8, Oracle 9, and Oracle 10. JBoss Portal can use any database that is supported by Hibernate.
+ A database is required for JBoss Portal to run. JBoss EAP and JBoss AS include an embedded Hypersonic SQL database that JBoss Portal can use; however, this is only recommended for developer use. The following databases are recommended for production use, and have had test suites run against them: MySQL 4, MySQL 5, <trademark class="registered">Microsoft SQL Server</trademark>, PostgreSQL 8, Oracle 9, and Oracle 10. JBoss Portal can use any database that is supported by Hibernate.
</para>
<para>
To configure a database to use with JBoss Portal:
@@ -117,7 +117,7 @@
<sect3>
<title>Datasource Descriptors</title>
<para>
- The JBoss Portal binary download that was extracted in <xref linkend="install_binarydownload"/>, contains pre-configured Datasource descriptors for the more popular databases. Datasource descriptors are provided for the MySQL 4, MySQL 5, PostgreSQL, Microsoft SQL Server, and Oracle databases, and can be found in the <filename>setup</filename> subdirectory where the JBoss Portal binary was extracted to:
+ The JBoss Portal binary download that was extracted in <xref linkend="install_binarydownload"/>, contains pre-configured Datasource descriptors for the more popular databases. Datasource descriptors are provided for the MySQL 4, MySQL 5, PostgreSQL, <trademark class="registered">Microsoft SQL Server</trademark>, and Oracle databases, and can be found in the <filename>setup</filename> subdirectory where the JBoss Portal binary was extracted to:
</para>
<mediaobject>
<imageobject>
@@ -161,7 +161,7 @@
</listitem>
<listitem>
<para>
- <emphasis role="bold">Start the server:</emphasis> change into the <filename>$JBOSS_HOME/bin/</filename> directory. On Microsoft Windows, execute <command>run.bat</command>. On Linux, run the <command>sh run.sh</command> command. To specify a configuration to use, for example, the default configuration, append the <command> -c default</command> option to the <command>run.bat</command> or <command>sh run.sh</command> commands.
+ <emphasis role="bold">Start the server:</emphasis> change into the <filename>$JBOSS_HOME/bin/</filename> directory. On Windows-based systems, execute <command>run.bat</command>. On Linux, run the <command>sh run.sh</command> command. To specify a configuration to use, for example, the default configuration, append the <command> -c default</command> option to the <command>run.bat</command> or <command>sh run.sh</command> commands.
</para>
</listitem>
<listitem>
@@ -265,7 +265,7 @@
<title>Operating System Environment Settings</title>
<para>For build targets to work, you must configure a <filename>JBOSS_HOME</filename> environment variable. This environment variable must point to the root directory of the JBoss EAP or JBoss AS installation directory, which is the directory where the JBoss EAP or JBoss AS files were extracted to.
</para>
- <para>When using Microsoft Windows, this is accomplished by going to
+ <para>On Windows-based systems, this is accomplished by going to
<emphasis>Start > Settings > Control Panel > System > Advanced > Environment Variables</emphasis>. Under the
<emphasis>System Variables</emphasis>
section, click
@@ -327,7 +327,7 @@
<para>
Replace <replaceable>proxy-hostname</replaceable> with the proxy server's hostname, and <replaceable>proxy-port</replaceable> with the correct proxy server port number.
</para>
- <para>To build and deploy JBoss Portal from the sources, change into the <filename>JBOSS_PORTAL_SOURCE_DIRECTORY/build/</filename> directory, where <filename>JBOSS_PORTAL_SOURCE_DIRECTORY</filename> is the directory where the JBoss Portal source code was downloaded to. Then, Microsoft Windows users need to run the <command>build.bat deploy</command> command, and Linux users need to run the <command>sh build.sh deploy</command> command.
+ <para>To build and deploy JBoss Portal from the sources, change into the <filename>JBOSS_PORTAL_SOURCE_DIRECTORY/build/</filename> directory, where <filename>JBOSS_PORTAL_SOURCE_DIRECTORY</filename> is the directory where the JBoss Portal source code was downloaded to. Then, <trademark class="registered">Windows</trademark> users need to run the <command>build.bat deploy</command> command, and Linux users need to run the <command>sh build.sh deploy</command> command.
</para>
<para>
At the end of the build process, the <filename>jboss-portal.sar</filename> file is copied into the <filename>$JBOSS_HOME/server/default/deploy/</filename> directory:
@@ -343,7 +343,7 @@
<note>
<title>Portal Modules</title>
<para>
- The previous steps install a bare version of JBoss Portal. In previous versions, several additional modules were deployed as well, but this has since been modularized to provide greater flexibility. To deploy additional modules, refer to the <ulink url="http://wiki.jboss.org/wiki/Wiki.jsp?page=PortalModules">Portal's module list</ulink> for more information. To deploy all modules at once, change into the <filename>build</filename> directory. If you are running Linux, run the <command>sh build.sh deploy-all</command> command. If you are running Microsoft Windows, run the <command>build.bat deploy-all</command> command.
+ The previous steps install a bare version of JBoss Portal. In previous versions, several additional modules were deployed as well, but this has since been modularized to provide greater flexibility. To deploy additional modules, refer to the <ulink url="http://wiki.jboss.org/wiki/Wiki.jsp?page=PortalModules">Portal's module list</ulink> for more information. To deploy all modules at once, change into the <filename>build</filename> directory. If you are running Linux, run the <command>sh build.sh deploy-all</command> command. On Windows-based systems, run the <command>build.bat deploy-all</command> command.
</para>
</note>
</para>
@@ -378,13 +378,13 @@
</orderedlist>
</para>
<para>
- To build the clustered version on Microsoft Windows, repeat the previous steps, replacing <command>sh build.sh</command> with <command>build.bat</command>.
+ To build the clustered version on Windows-based systems, repeat the previous steps, replacing <command>sh build.sh</command> with <command>build.bat</command>.
</para>
</sect2>
<sect2>
<title>Database Setup</title>
<para>
- A database is required for JBoss Portal to run. JBoss EAP and JBoss AS include an embedded Hypersonic SQL database that JBoss Portal can use; however, this is only recommended for developer use. The following databases are recommended for production use, and have had test suites run against them: MySQL 4, MySQL 5, Microsoft SQL Server, PostgreSQL 8, Oracle 9, and Oracle 10. JBoss Portal can use any database that is supported by Hibernate.
+ A database is required for JBoss Portal to run. JBoss EAP and JBoss AS include an embedded Hypersonic SQL database that JBoss Portal can use; however, this is only recommended for developer use. The following databases are recommended for production use, and have had test suites run against them: MySQL 4, MySQL 5, <trademark class="registered">Microsoft SQL Server</trademark>, PostgreSQL 8, Oracle 9, and Oracle 10. JBoss Portal can use any database that is supported by Hibernate.
</para>
<para>
To configure a database to use with JBoss Portal:
@@ -412,7 +412,7 @@
<sect2>
<title>Datasource Configuration</title>
<para>
- The JBoss Portal binary download that was extracted in <xref linkend="install_binarydownload"/>, contains pre-configured Datasource descriptors for the more popular databases. Datasource descriptors are provided for the MySQL 4, MySQL 5, PostgreSQL, Microsoft SQL Server, and Oracle databases, and can be found in the <filename>setup</filename> subdirectory where the JBoss Portal binary was extracted to:
+ The JBoss Portal binary download that was extracted in <xref linkend="install_binarydownload"/>, contains pre-configured Datasource descriptors for the more popular databases. Datasource descriptors are provided for the MySQL 4, MySQL 5, PostgreSQL, <trademark class="registered">Microsoft SQL Server</trademark>, and Oracle databases, and can be found in the <filename>setup</filename> subdirectory where the JBoss Portal binary was extracted to:
</para>
<mediaobject>
<imageobject>
@@ -456,7 +456,7 @@
</listitem>
<listitem>
<para>
- <emphasis role="bold">Start the server:</emphasis> change into the <filename>$JBOSS_HOME/bin/</filename> directory. On Microsoft Windows, execute <command>run.bat</command>. On Linux, run the <command>sh run.sh</command> command. To specify a configuration to use, for example, the default configuration, append the <command> -c default</command> option to the <command>run.bat</command> or <command>sh run.sh</command> commands.
+ <emphasis role="bold">Start the server:</emphasis> change into the <filename>$JBOSS_HOME/bin/</filename> directory. On Windows-based systems, execute <command>run.bat</command>. On Linux, run the <command>sh run.sh</command> command. To specify a configuration to use, for example, the default configuration, append the <command> -c default</command> option to the <command>run.bat</command> or <command>sh run.sh</command> commands.
</para>
</listitem>
<listitem>
Modified: docs/branches/JBoss_Portal_Branch_2_6/referenceGuide/en/modules/supported.xml
===================================================================
--- docs/branches/JBoss_Portal_Branch_2_6/referenceGuide/en/modules/supported.xml 2008-06-02 20:18:26 UTC (rev 10907)
+++ docs/branches/JBoss_Portal_Branch_2_6/referenceGuide/en/modules/supported.xml 2008-06-03 11:25:42 UTC (rev 10908)
@@ -32,7 +32,7 @@
<sect1>
<title>Supported Operating Systems</title>
<para>JBoss Portal is 100% pure Java, and therefore it is interoperable with most Operating Systems
- capable of running a Java Virtual Machine (JVM). These Operating Systems include but are not limited to: Linux, Microsoft Windows, UNIX, and Mac OS X.
+ capable of running a Java Virtual Machine (JVM). These Operating Systems include but are not limited to: Linux, <trademark class="registered">Windows</trademark>, <trademark class="registered">UNIX</trademark>, and Mac OS X.
</para>
</sect1>
<sect1>
@@ -54,7 +54,7 @@
<listitem>Hypersonic SQL</listitem>
<listitem>Derby</listitem>
<listitem>Oracle 9 and 10g (use the <ulink url="http://www.oracle.com/technology/software/tech/java/sqlj_jdbc/index.html">latest driver from the Oracle 10 branch</ulink> even if you are running Oracle 9)</listitem>
- <listitem>Microsoft SQL Server</listitem>
+ <listitem><trademark class="registered">Microsoft SQL Server</trademark></listitem>
<listitem>MaxDB</listitem>
</itemizedlist>
<note>
@@ -63,6 +63,6 @@
</sect1>
<sect1>
<title>Source building</title>
- <para>The source building mechanism works on Linux, Microsoft Windows, Mac OS X, and any UNIX-like Operating System.</para>
+ <para>The source building mechanism works on Linux, <trademark class="registered">Windows</trademark>, Mac OS X, and any UNIX-like operating system.</para>
</sect1>
</chapter>
Modified: docs/branches/JBoss_Portal_Branch_2_6/referenceGuide/en/modules/tutorials.xml
===================================================================
--- docs/branches/JBoss_Portal_Branch_2_6/referenceGuide/en/modules/tutorials.xml 2008-06-02 20:18:26 UTC (rev 10907)
+++ docs/branches/JBoss_Portal_Branch_2_6/referenceGuide/en/modules/tutorials.xml 2008-06-03 11:25:42 UTC (rev 10908)
@@ -538,7 +538,7 @@
</listitem>
<listitem>
<para>
- Change into <filename>HelloWorldPortlet/</filename> directory, and run the <command>ant deploy</command> command. On Microsoft Windows, the output will be similar to the following:
+ Change into <filename>HelloWorldPortlet/</filename> directory, and run the <command>ant deploy</command> command. On <trademark class="registered">Windows</trademark>, the output will be similar to the following:
</para>
<para>
<mediaobject>
@@ -565,7 +565,7 @@
</listitem>
<listitem>
<para>
- To expand the WAR file, change into the <filename>HelloWorldPortlet/</filename> directory, and run the <command>ant explode</command> command. On Microsoft Windows, the output will be similar to the following:
+ To expand the WAR file, change into the <filename>HelloWorldPortlet/</filename> directory, and run the <command>ant explode</command> command. On <trademark class="registered">Windows</trademark>, the output will be similar to the following:
</para>
<para>
<mediaobject>
Modified: docs/branches/JBoss_Portal_Branch_2_6/referenceGuide/en/modules/xmldescriptors.xml
===================================================================
--- docs/branches/JBoss_Portal_Branch_2_6/referenceGuide/en/modules/xmldescriptors.xml 2008-06-02 20:18:26 UTC (rev 10907)
+++ docs/branches/JBoss_Portal_Branch_2_6/referenceGuide/en/modules/xmldescriptors.xml 2008-06-03 11:25:42 UTC (rev 10908)
@@ -1556,7 +1556,7 @@
</mediaobject>
</para>
<para>
- The <filename>jboss-portal-<replaceable>version</replaceable>/setup/</filename> directory contains sample Datasource descriptors for the MySQL, Microsoft SQL Server, PostgreSQL, and Oracale databases, which can be customized for your own database:
+ The <filename>jboss-portal-<replaceable>version</replaceable>/setup/</filename> directory contains sample Datasource descriptors for the MySQL, <trademark class="registered">Microsoft SQL Server</trademark>, PostgreSQL, and Oracale databases, which can be customized for your own database:
</para>
<para>
<mediaobject>
@@ -1585,12 +1585,12 @@
</listitem>
<listitem>
<para>
- Change into the <filename>JBOSS_PORTAL_SOURCE_DIRECTORY/build/</filename> directory. To build the JBoss Portal source code on Linux, run the <command>sh build.sh deploy</command> command, or, if you are running Microsoft Windows, run the <command>build.bat deploy</command> command. If this is the first build, third-party libraries are obtained from an online repository, so you must be connected to the Internet. After building, if the <filename>JBOSS_PORTAL_SOURCE_DIRECTORY/thirdparty/</filename> directory does not exist, it is created, and populated with the files required for later steps. For further details, refer to <xref linkend="building_deploying_from_source" />.
+ Change into the <filename>JBOSS_PORTAL_SOURCE_DIRECTORY/build/</filename> directory. To build the JBoss Portal source code on Linux, run the <command>sh build.sh deploy</command> command, or, if you are running <trademark class="registered">Windows</trademark>, run the <command>build.bat deploy</command> command. If this is the first build, third-party libraries are obtained from an online repository, so you must be connected to the Internet. After building, if the <filename>JBOSS_PORTAL_SOURCE_DIRECTORY/thirdparty/</filename> directory does not exist, it is created, and populated with the files required for later steps. For further details, refer to <xref linkend="building_deploying_from_source" />.
</para>
</listitem>
<listitem>
<para>
- Change into the <filename>JBOSS_PORTAL_SOURCE_DIRECTORY/core/</filename> directory, and run the <command>sh build.sh datasource</command> command, or, if you are running Microsoft Windows, run the <command>build.bat datasource</command> command:
+ Change into the <filename>JBOSS_PORTAL_SOURCE_DIRECTORY/core/</filename> directory, and run the <command>sh build.sh datasource</command> command, or, if you are running <trademark class="registered">Windows</trademark>, run the <command>build.bat datasource</command> command:
</para>
<para>
<mediaobject>
17 years, 11 months
JBoss Portal SVN: r10906 - in modules/presentation/trunk/portal/src: main/java/org/jboss/portal/presentation/portal/content/portlet/controller and 2 other directories.
by portal-commits@lists.jboss.org
Author: julien(a)jboss.com
Date: 2008-06-02 16:16:56 -0400 (Mon, 02 Jun 2008)
New Revision: 10906
Added:
modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/PortalNode.java
Modified:
modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/PresentationServerImpl.java
modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/content/portlet/controller/PresentationPortletControllerContext.java
modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/ContextNode.java
modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/NodeImporter.java
modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/PageNode.java
modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/PaneNode.java
modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/StructuralStateContextImpl.java
modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/WindowNode.java
modules/presentation/trunk/portal/src/test/java/org/jboss/portal/presentation/portal/model/StructuralStateContextTestCase.java
Log:
rename structural node to portal node as it is more correct
Modified: modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/PresentationServerImpl.java
===================================================================
--- modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/PresentationServerImpl.java 2008-06-02 19:08:03 UTC (rev 10905)
+++ modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/PresentationServerImpl.java 2008-06-02 20:16:56 UTC (rev 10906)
@@ -23,7 +23,7 @@
package org.jboss.portal.presentation.portal;
import org.jboss.portal.presentation.client.PresentationClient;
-import org.jboss.portal.presentation.portal.model.StructuralNode;
+import org.jboss.portal.presentation.portal.model.PortalNode;
import org.jboss.portal.presentation.portal.model.StructuralStateContextImpl;
import org.jboss.portal.presentation.portal.model.WindowNode;
import org.jboss.portal.presentation.portal.model.PageNode;
@@ -94,7 +94,7 @@
String targetId = objectAction.getTargetId();
//
- StructuralNode targetNode = structuralStateContext.getNode(targetId);
+ PortalNode targetNode = structuralStateContext.getNode(targetId);
//
if (targetNode == null)
Modified: modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/content/portlet/controller/PresentationPortletControllerContext.java
===================================================================
--- modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/content/portlet/controller/PresentationPortletControllerContext.java 2008-06-02 19:08:03 UTC (rev 10905)
+++ modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/content/portlet/controller/PresentationPortletControllerContext.java 2008-06-02 20:16:56 UTC (rev 10906)
@@ -49,7 +49,7 @@
import org.jboss.portal.presentation.portal.content.portlet.spi.PresentationSecurityContext;
import org.jboss.portal.presentation.portal.content.portlet.PortletContent;
import org.jboss.portal.presentation.portal.model.PageNode;
-import org.jboss.portal.presentation.portal.model.StructuralNode;
+import org.jboss.portal.presentation.portal.model.PortalNode;
import org.jboss.portal.presentation.portal.model.WindowNode;
import org.jboss.portal.presentation.client.PresentationClient;
@@ -96,7 +96,7 @@
Map<String, WindowNode> windows = new HashMap<String, WindowNode>();
//
- for (StructuralNode child : page.getChildren())
+ for (PortalNode child : page.getChildren())
{
if (child instanceof WindowNode)
{
Modified: modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/ContextNode.java
===================================================================
--- modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/ContextNode.java 2008-06-02 19:08:03 UTC (rev 10905)
+++ modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/ContextNode.java 2008-06-02 20:16:56 UTC (rev 10906)
@@ -29,7 +29,7 @@
* @author <a href="mailto:julien@jboss-portal.org">Julien Viet</a>
* @version $Revision: 630 $
*/
-public class ContextNode extends StructuralNode
+public class ContextNode extends PortalNode
{
public ContextNode(String name, StructuralStateContextImpl structuralStateContext)
{
Modified: modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/NodeImporter.java
===================================================================
--- modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/NodeImporter.java 2008-06-02 19:08:03 UTC (rev 10905)
+++ modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/NodeImporter.java 2008-06-02 20:16:56 UTC (rev 10906)
@@ -73,9 +73,9 @@
}
/** The root to import the children to. */
- private final StructuralNode root;
+ private final PortalNode root;
- public NodeImporter(StructuralNode root)
+ public NodeImporter(PortalNode root)
{
this.root = root;
}
@@ -133,7 +133,7 @@
}
}
- private PageNode importPageDef(StructuralNode parentNode, Element pageDefElt)
+ private PageNode importPageDef(PortalNode parentNode, Element pageDefElt)
{
PageNode pageNode = createStructuralNode(parentNode, PageNode.class, pageDefElt);
@@ -156,7 +156,7 @@
return pageNode;
}
- private void importLayout(StructuralNode paneNode, Element layoutElt)
+ private void importLayout(PortalNode paneNode, Element layoutElt)
{
if ("simple-layout".equals(layoutElt.getNodeName()))
{
@@ -179,7 +179,7 @@
}
}
- private WindowNode importWindowDef(StructuralNode parentNode, Element windowDefElt)
+ private WindowNode importWindowDef(PortalNode parentNode, Element windowDefElt)
{
WindowNode windowNode = createStructuralNode(parentNode, WindowNode.class, windowDefElt);
@@ -208,7 +208,7 @@
return windowNode;
}
- private <T extends StructuralNode> T createStructuralNode(StructuralNode parent, Class<T> type, Element nodeDefElt)
+ private <T extends PortalNode> T createStructuralNode(PortalNode parent, Class<T> type, Element nodeDefElt)
{
String nodeName = nodeDefElt.getAttribute("name");
Modified: modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/PageNode.java
===================================================================
--- modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/PageNode.java 2008-06-02 19:08:03 UTC (rev 10905)
+++ modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/PageNode.java 2008-06-02 20:16:56 UTC (rev 10906)
@@ -33,7 +33,7 @@
* @author <a href="mailto:julien@jboss-portal.org">Julien Viet</a>
* @version $Revision: 630 $
*/
-public class PageNode extends StructuralNode
+public class PageNode extends PortalNode
{
public PageNode(String name, StructuralStateContextImpl structuralStateContext)
{
@@ -56,7 +56,7 @@
return windows;
}
- private void collectWindows(StructuralNode node, List<WindowNode> windows)
+ private void collectWindows(PortalNode node, List<WindowNode> windows)
{
if (node instanceof WindowNode)
{
@@ -64,7 +64,7 @@
}
else if (node instanceof PaneNode)
{
- for (StructuralNode child : node.getChildren())
+ for (PortalNode child : node.getChildren())
{
collectWindows(child, windows);
}
Modified: modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/PaneNode.java
===================================================================
--- modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/PaneNode.java 2008-06-02 19:08:03 UTC (rev 10905)
+++ modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/PaneNode.java 2008-06-02 20:16:56 UTC (rev 10906)
@@ -29,7 +29,7 @@
* @author <a href="mailto:julien@jboss-portal.org">Julien Viet</a>
* @version $Revision: 630 $
*/
-public class PaneNode extends StructuralNode
+public class PaneNode extends PortalNode
{
public PaneNode(String name, StructuralStateContextImpl structuralStateContext)
Copied: modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/PortalNode.java (from rev 10905, modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/StructuralNode.java)
===================================================================
--- modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/PortalNode.java (rev 0)
+++ modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/PortalNode.java 2008-06-02 20:16:56 UTC (rev 10906)
@@ -0,0 +1,353 @@
+/******************************************************************************
+ * 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.presentation.portal.model;
+
+import org.jboss.portal.presentation.model.ui.UIObject;
+import org.jboss.portal.presentation.state.StaleStateException;
+import org.jboss.portal.presentation.state.structural.StructuralObject;
+
+import java.lang.reflect.Constructor;
+import java.lang.reflect.InvocationTargetException;
+import java.util.ArrayList;
+import java.util.Collection;
+import java.util.Collections;
+import java.util.HashMap;
+import java.util.HashSet;
+import java.util.Map;
+import java.util.Set;
+import java.io.Serializable;
+
+/**
+ * @author <a href="mailto:julien@jboss-portal.org">Julien Viet</a>
+ * @version $Revision: 630 $
+ */
+public abstract class PortalNode
+{
+
+ /** . */
+ private final Set<String> EMPTY_STRING_SET = Collections.emptySet();
+
+ /** . */
+ private PortalNode parent;
+
+ /** . */
+ private final Map<String, PortalNode> children = new HashMap<String, PortalNode>();
+
+ /** . */
+ private final StructuralStateContextImpl structuralStateContext;
+
+ /** . */
+ private final String id;
+
+ /** . */
+ private final String name;
+
+ /** . */
+ private boolean valid;
+
+ /** . */
+ private final Map<String, Serializable> properties;
+
+ protected PortalNode(String name, StructuralStateContextImpl structuralStateContext)
+ {
+ this.name = name;
+ this.id = structuralStateContext.nextId();
+ this.structuralStateContext = structuralStateContext;
+ this.properties = new HashMap<String, Serializable>();
+ this.valid = true;
+ }
+
+ public abstract Class<? extends UIObject> getType();
+
+ Collection<StructuralObject> takeChildrenSnapshot(StructuralObject structuralObject)
+ {
+ synchronized (this)
+ {
+ if (!takeSnapshot().equals(structuralObject))
+ {
+ throw new StaleStateException();
+ }
+
+ //
+ Set<StructuralObject> structuralChildren = new HashSet<StructuralObject>();
+ for (PortalNode child : children.values())
+ {
+ structuralChildren.add(child.takeSnapshot());
+ }
+
+ //
+ return structuralChildren;
+ }
+ }
+
+ StructuralObject takeParentSnapshot(StructuralObject structuralObject)
+ {
+ synchronized (this)
+ {
+ if (!takeSnapshot().equals(structuralObject))
+ {
+ throw new StaleStateException();
+ }
+
+ //
+ return parent != null ? parent.takeSnapshot() : null;
+ }
+ }
+
+ StructuralObject takeSnapshot()
+ {
+ synchronized (this)
+ {
+ StructuralStateImpl state = new StructuralStateImpl(
+ getType(),
+ name,
+ Collections.unmodifiableMap(new HashMap<String, Serializable>(properties)));
+
+ //
+ Set<String> childrenIds = new HashSet<String>();
+ for (PortalNode child : children.values())
+ {
+ childrenIds.add(child.id);
+ }
+
+ //
+ String parentId = parent != null ? parent.id : null;
+
+ //
+ return new StructuralObjectImpl(id, parentId, Collections.unmodifiableSet(childrenIds), state);
+ }
+ }
+
+ StructuralObject.Refresh refresh(StructuralObjectImpl structuralObject)
+ {
+ synchronized (this)
+ {
+ Map<String, PortalNode> childrenMap = new HashMap<String, PortalNode>();
+ for (PortalNode child : children.values())
+ {
+ childrenMap.put(child.getId(), child);
+ }
+
+ //
+ Map<String, PortalNode> addedChildrenMap = new HashMap<String, PortalNode>(childrenMap);
+ addedChildrenMap.keySet().removeAll(structuralObject.getChildrenIds());
+
+ //
+ Map<String, PortalNode> staleChildren = new HashMap<String, PortalNode>(childrenMap);
+ staleChildren.keySet().retainAll(structuralObject.getChildrenIds());
+
+ //
+ Set<String> removedChildrenIds = new HashSet<String>(structuralObject.getChildrenIds());
+ removedChildrenIds.removeAll(staleChildren.keySet());
+
+ //
+ Set<StructuralObject> addedStructuralChildren = new HashSet<StructuralObject>();
+ for (PortalNode addedChild : addedChildrenMap.values())
+ {
+ addedStructuralChildren.add(addedChild.takeSnapshot());
+ }
+
+ //
+ Map<String, StructuralObject> staleStructuralChildren = new HashMap<String, StructuralObject>();
+ for (PortalNode stateChild : staleChildren.values())
+ {
+ staleStructuralChildren.put(stateChild.getId(), stateChild.takeSnapshot());
+ }
+
+ //
+ return new StructuralObject.Refresh(
+ parent != null ? parent.takeSnapshot() : null,
+ takeSnapshot(),
+ addedStructuralChildren,
+ removedChildrenIds,
+ staleStructuralChildren,
+ EMPTY_STRING_SET);
+ }
+ }
+
+ public boolean isValid()
+ {
+ return valid;
+ }
+
+ public String getId()
+ {
+ return id;
+ }
+
+ public String getName()
+ {
+ return name;
+ }
+
+ public PortalNode getParent()
+ {
+ return parent;
+ }
+
+ public Set<String> getPropertyNames()
+ {
+ return Collections.unmodifiableSet(properties.keySet());
+ }
+
+ public Serializable getProperty(String propertyName)
+ {
+ if (propertyName == null)
+ {
+ throw new IllegalArgumentException("No null property name");
+ }
+
+ //
+ synchronized (this)
+ {
+ return properties.get(propertyName);
+ }
+ }
+
+ public void setProperty(String propertyName, Serializable propertyValue)
+ {
+ if (propertyName == null)
+ {
+ throw new IllegalArgumentException("No null property name");
+ }
+
+ //
+ synchronized (this)
+ {
+ if (propertyValue != null)
+ {
+ properties.put(propertyName, propertyValue);
+ }
+ else
+ {
+ properties.remove(propertyName);
+ }
+ }
+ }
+
+ public Collection<? extends PortalNode> getChildren()
+ {
+ return Collections.unmodifiableCollection(children.values());
+ }
+
+ public <T extends PortalNode> T addChild(String name, Class<T> type)
+ {
+ if (name == null)
+ {
+ throw new IllegalArgumentException();
+ }
+ if (type == null)
+ {
+ throw new IllegalArgumentException();
+ }
+
+ //
+ T child;
+ try
+ {
+ Constructor<T> ctor = type.getConstructor(String.class, StructuralStateContextImpl.class);
+ child = ctor.newInstance(name, structuralStateContext);
+ }
+ catch (InstantiationException e)
+ {
+ throw new AssertionError(e);
+ }
+ catch (IllegalAccessException e)
+ {
+ throw new AssertionError(e);
+ }
+ catch (NoSuchMethodException e)
+ {
+ throw new AssertionError(e);
+ }
+ catch (InvocationTargetException e)
+ {
+ throw new AssertionError(e);
+ }
+
+ //
+ synchronized (this)
+ {
+ if (children.containsKey(name))
+ {
+ throw new IllegalArgumentException("Child already exist");
+ }
+ children.put(name, child);
+ child.parent = this;
+ }
+
+ //
+ structuralStateContext.nodes.put(child.id, child);
+
+ //
+ return child;
+ }
+
+ public void destroyChild(String name)
+ {
+ if (name == null)
+ {
+ throw new IllegalArgumentException();
+ }
+
+ //
+ PortalNode child;
+ synchronized (this)
+ {
+ if (!children.containsKey(name))
+ {
+ throw new IllegalArgumentException("No such child " + name);
+ }
+
+ child = children.get(name);
+
+ //
+ for (String blah : new ArrayList<String>(child.children.keySet()))
+ {
+ child.destroyChild(blah);
+ }
+
+ //
+ children.remove(name);
+ structuralStateContext.nodes.remove(child.id);
+
+ //
+ child.valid = false;
+ child.parent = null;
+ }
+ }
+
+ public PortalNode getChild(String name)
+ {
+ if (name == null)
+ {
+ throw new IllegalArgumentException();
+ }
+
+ //
+ synchronized (this)
+ {
+ return children.get(name);
+ }
+ }
+}
Modified: modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/StructuralStateContextImpl.java
===================================================================
--- modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/StructuralStateContextImpl.java 2008-06-02 19:08:03 UTC (rev 10905)
+++ modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/StructuralStateContextImpl.java 2008-06-02 20:16:56 UTC (rev 10906)
@@ -44,7 +44,7 @@
private final AtomicLong sequence = new AtomicLong();
/** . */
- final ConcurrentMap<String, StructuralNode> nodes = new ConcurrentHashMap<String, StructuralNode>();
+ final ConcurrentMap<String, PortalNode> nodes = new ConcurrentHashMap<String, PortalNode>();
/** . */
private final ContextNode root = new ContextNode("", this);
@@ -59,7 +59,7 @@
return Long.toString(sequence.getAndIncrement());
}
- public StructuralNode getNode(String nodeId)
+ public PortalNode getNode(String nodeId)
{
if (nodeId == null)
{
@@ -83,10 +83,10 @@
}
//
- StructuralNode node = nodes.get(objectId);
+ PortalNode node = nodes.get(objectId);
//
- StructuralNode parent = node.getParent();
+ PortalNode parent = node.getParent();
//
if (parent == null)
@@ -106,7 +106,7 @@
}
//
- StructuralNode node = nodes.get(objectId);
+ PortalNode node = nodes.get(objectId);
//
return node != null ? node.takeSnapshot() : null;
@@ -120,7 +120,7 @@
}
//
- StructuralNode parentNode = nodes.get(structuralParent.getId());
+ PortalNode parentNode = nodes.get(structuralParent.getId());
//
if (parentNode == null)
@@ -140,7 +140,7 @@
}
//
- StructuralNode childNode = nodes.get(structuralChild.getId());
+ PortalNode childNode = nodes.get(structuralChild.getId());
//
if (childNode == null)
@@ -165,16 +165,16 @@
}
//
- StructuralNode structuralNode = nodes.get(structuralObject.getId());
+ PortalNode portalNode = nodes.get(structuralObject.getId());
//
- if (structuralNode == null)
+ if (portalNode == null)
{
throw new NoSuchStateException();
}
//
- if (!structuralNode.takeSnapshot().equals(structuralObject))
+ if (!portalNode.takeSnapshot().equals(structuralObject))
{
throw new StaleStateException();
}
@@ -188,15 +188,15 @@
}
//
- StructuralNode structuralNode = nodes.get(structuralObject.getId());
+ PortalNode portalNode = nodes.get(structuralObject.getId());
//
- if (structuralNode == null)
+ if (portalNode == null)
{
throw new NoSuchStateException();
}
//
- return structuralNode.refresh((StructuralObjectImpl)structuralObject);
+ return portalNode.refresh((StructuralObjectImpl)structuralObject);
}
}
Modified: modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/WindowNode.java
===================================================================
--- modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/WindowNode.java 2008-06-02 19:08:03 UTC (rev 10905)
+++ modules/presentation/trunk/portal/src/main/java/org/jboss/portal/presentation/portal/model/WindowNode.java 2008-06-02 20:16:56 UTC (rev 10906)
@@ -33,7 +33,7 @@
* @author <a href="mailto:julien@jboss-portal.org">Julien Viet</a>
* @version $Revision: 630 $
*/
-public class WindowNode extends StructuralNode
+public class WindowNode extends PortalNode
{
/** . */
@@ -51,7 +51,7 @@
public PageNode getPage()
{
- for (StructuralNode current = getParent();current != null;current = current.getParent())
+ for (PortalNode current = getParent();current != null;current = current.getParent())
{
if (current instanceof PageNode)
{
Modified: modules/presentation/trunk/portal/src/test/java/org/jboss/portal/presentation/portal/model/StructuralStateContextTestCase.java
===================================================================
--- modules/presentation/trunk/portal/src/test/java/org/jboss/portal/presentation/portal/model/StructuralStateContextTestCase.java 2008-06-02 19:08:03 UTC (rev 10905)
+++ modules/presentation/trunk/portal/src/test/java/org/jboss/portal/presentation/portal/model/StructuralStateContextTestCase.java 2008-06-02 20:16:56 UTC (rev 10906)
@@ -38,7 +38,7 @@
* @author <a href="mailto:julien@jboss-portal.org">Julien Viet</a>
* @version $Revision: 630 $
*/
-public class StructuralStateContextTestCase extends AbstractModelTestCase<StructuralNode>
+public class StructuralStateContextTestCase extends AbstractModelTestCase<PortalNode>
{
/** . */
@@ -49,49 +49,49 @@
return structuralStateContext;
}
- protected StructuralNode getRoot()
+ protected PortalNode getRoot()
{
return structuralStateContext.getRoot();
}
- protected Set<String> getPropertyNames(StructuralNode structuralNode)
+ protected Set<String> getPropertyNames(PortalNode portalNode)
{
- return structuralNode.getPropertyNames();
+ return portalNode.getPropertyNames();
}
- protected StructuralNode getParent(StructuralNode structuralNode)
+ protected PortalNode getParent(PortalNode portalNode)
{
- return structuralNode.getParent();
+ return portalNode.getParent();
}
- protected List<? extends StructuralNode> getChildren(StructuralNode structuralNode)
+ protected List<? extends PortalNode> getChildren(PortalNode portalNode)
{
- return new ArrayList<StructuralNode>(structuralNode.getChildren());
+ return new ArrayList<PortalNode>(portalNode.getChildren());
}
- protected String getName(StructuralNode structuralNode)
+ protected String getName(PortalNode portalNode)
{
- return structuralNode.getName();
+ return portalNode.getName();
}
- protected boolean isValid(StructuralNode structuralNode)
+ protected boolean isValid(PortalNode portalNode)
{
- return structuralNode.isValid();
+ return portalNode.isValid();
}
- protected Class<? extends UIObject> getType(StructuralNode structuralNode)
+ protected Class<? extends UIObject> getType(PortalNode portalNode)
{
- return structuralNode.getType();
+ return portalNode.getType();
}
- protected String getId(StructuralNode structuralNode)
+ protected String getId(PortalNode portalNode)
{
- return structuralNode.getId();
+ return portalNode.getId();
}
- protected StructuralNode addChild(StructuralNode structuralNode, String name, Class<? extends UIObject> modelType)
+ protected PortalNode addChild(PortalNode portalNode, String name, Class<? extends UIObject> modelType)
{
- Class<? extends StructuralNode> structuralNodeType;
+ Class<? extends PortalNode> structuralNodeType;
//
if (modelType == UIContext.class)
@@ -112,22 +112,22 @@
}
//
- return structuralNode.addChild(name, structuralNodeType);
+ return portalNode.addChild(name, structuralNodeType);
}
- protected void setProperty(StructuralNode structuralNode, String propertyName, String propertyValue)
+ protected void setProperty(PortalNode portalNode, String propertyName, String propertyValue)
{
- structuralNode.setProperty(propertyName, propertyValue);
+ portalNode.setProperty(propertyName, propertyValue);
}
- protected Serializable getProperty(StructuralNode structuralNode, String name)
+ protected Serializable getProperty(PortalNode portalNode, String name)
{
- return structuralNode.getProperty(name);
+ return portalNode.getProperty(name);
}
- protected void destroy(StructuralNode structuralNode)
+ protected void destroy(PortalNode portalNode)
{
- structuralStateContext.destroy(structuralNode.getId());
+ structuralStateContext.destroy(portalNode.getId());
}
protected void setUp() throws Exception
17 years, 11 months