JBoss Portal SVN: r7056 - trunk/core/src/main/org/jboss/portal/core/impl/model/content.
by portal-commits@lists.jboss.org
Author: julien(a)jboss.com
Date: 2007-04-25 15:52:47 -0400 (Wed, 25 Apr 2007)
New Revision: 7056
Modified:
trunk/core/src/main/org/jboss/portal/core/impl/model/content/InternalContentProvider.java
Log:
inline trivial method
Modified: trunk/core/src/main/org/jboss/portal/core/impl/model/content/InternalContentProvider.java
===================================================================
--- trunk/core/src/main/org/jboss/portal/core/impl/model/content/InternalContentProvider.java 2007-04-25 19:50:57 UTC (rev 7055)
+++ trunk/core/src/main/org/jboss/portal/core/impl/model/content/InternalContentProvider.java 2007-04-25 19:52:47 UTC (rev 7056)
@@ -209,7 +209,7 @@
PortletInvocationResponse response;
try
{
- response = invoke(instance, invocation);
+ response = instance.invoke(invocation);
}
catch (PortletInvokerException e)
{
@@ -392,11 +392,6 @@
return null;
}
- protected PortletInvocationResponse invoke(Instance instance, PortletInvocation invocation) throws PortletInvokerException
- {
- return instance.invoke(invocation);
- }
-
/**
* Create the action URLs for the allowed window states of the rendered portlet window and add them to the provided
* actionMap.
17 years, 2 months
JBoss Portal SVN: r7055 - trunk/core/src/main/org/jboss/portal/core/model/portal/command/render.
by portal-commits@lists.jboss.org
Author: julien(a)jboss.com
Date: 2007-04-25 15:50:57 -0400 (Wed, 25 Apr 2007)
New Revision: 7055
Modified:
trunk/core/src/main/org/jboss/portal/core/model/portal/command/render/RenderPageCommand.java
Log:
handle Layout on RenderPageCommand the same way that Theme is handled, makes core more compact and symetric
Modified: trunk/core/src/main/org/jboss/portal/core/model/portal/command/render/RenderPageCommand.java
===================================================================
--- trunk/core/src/main/org/jboss/portal/core/model/portal/command/render/RenderPageCommand.java 2007-04-25 19:42:25 UTC (rev 7054)
+++ trunk/core/src/main/org/jboss/portal/core/model/portal/command/render/RenderPageCommand.java 2007-04-25 19:50:57 UTC (rev 7055)
@@ -74,9 +74,6 @@
private Collection windows;
/** . */
- private PortalLayout layout;
-
- /** . */
private boolean personalizable;
public RenderPageCommand(PortalObjectId pageId)
@@ -95,16 +92,6 @@
}
/**
- * Get the layout that was determined for this request (based on portal and page properties)
- *
- * @return the layout to use for this request
- */
- public PortalLayout getLayout()
- {
- return layout;
- }
-
- /**
* Returns the modifiable list of windows.
*
* @return the windows on the page
@@ -125,10 +112,6 @@
// All windows on the page
windows = new ArrayList(getPage().getChildren(PortalObject.WINDOW_MASK));
-
- //
- LayoutService layoutService = context.getController().getPageService().getLayoutService();
- layout = getLayout(layoutService, page);
}
public void enforceSecurity(PortalAuthorizationManager pam) throws ControllerSecurityException, PortalSecurityException
@@ -154,11 +137,15 @@
//
PageService pageService = context.getController().getPageService();
ThemeService themeService = pageService.getThemeService();
+ LayoutService layoutService = pageService.getLayoutService();
+ //
+ PortalLayout layout = getLayout(layoutService, page);
+
// The theme for the page
PortalTheme theme = null;
- //
+ // Determine theme
if (personalizable)
{
ControllerContext controllerCtx = (ControllerContext)getContext();
@@ -186,10 +173,9 @@
}
}
}
-
- // If nothing get it from the object properties
if (theme == null)
{
+ // If nothing get it from the object properties
String themeId = page.getProperty(ThemeConstants.PORTAL_PROP_THEME);
theme = themeService.getThemeById(themeId);
}
17 years, 2 months
JBoss Portal SVN: r7054 - trunk/core/src/main/org/jboss/portal/core/model/portal/command/render.
by portal-commits@lists.jboss.org
Author: julien(a)jboss.com
Date: 2007-04-25 15:42:25 -0400 (Wed, 25 Apr 2007)
New Revision: 7054
Modified:
trunk/core/src/main/org/jboss/portal/core/model/portal/command/render/RenderPageCommand.java
Log:
inline trivial method
Modified: trunk/core/src/main/org/jboss/portal/core/model/portal/command/render/RenderPageCommand.java
===================================================================
--- trunk/core/src/main/org/jboss/portal/core/model/portal/command/render/RenderPageCommand.java 2007-04-25 19:40:14 UTC (rev 7053)
+++ trunk/core/src/main/org/jboss/portal/core/model/portal/command/render/RenderPageCommand.java 2007-04-25 19:42:25 UTC (rev 7054)
@@ -46,6 +46,7 @@
import org.jboss.portal.theme.PortalTheme;
import org.jboss.portal.theme.ThemeConstants;
import org.jboss.portal.theme.PageService;
+import org.jboss.portal.theme.ThemeService;
import org.jboss.portal.theme.page.PageResult;
import org.jboss.portal.theme.page.WindowResult;
import org.jboss.portal.theme.page.WindowContext;
@@ -152,6 +153,7 @@
{
//
PageService pageService = context.getController().getPageService();
+ ThemeService themeService = pageService.getThemeService();
// The theme for the page
PortalTheme theme = null;
@@ -180,7 +182,7 @@
if (themeId != null)
{
- theme = getTheme(themeId);
+ theme = themeService.getThemeById(themeId);
}
}
}
@@ -189,7 +191,7 @@
if (theme == null)
{
String themeId = page.getProperty(ThemeConstants.PORTAL_PROP_THEME);
- theme = getTheme(themeId);
+ theme = themeService.getThemeById(themeId);
}
// Call the portlet container to create the markup fragment(s) for each portlet that needs to render itself
@@ -257,11 +259,6 @@
return null;
}
- private PortalTheme getTheme(String themeIdString)
- {
- return context.getController().getPageService().getThemeService().getThemeById(themeIdString);
- }
-
/**
* Get the portal layout to use for the provided page. <p>The name of the layout to use can be defined as a property
* in the portal, or the individual page. The page property overwrites the portal property. If no property was set, a
17 years, 2 months
JBoss Portal SVN: r7053 - in trunk: theme/src/main/org/jboss/portal/theme and 1 other directories.
by portal-commits@lists.jboss.org
Author: julien(a)jboss.com
Date: 2007-04-25 15:40:14 -0400 (Wed, 25 Apr 2007)
New Revision: 7053
Modified:
trunk/core/src/main/org/jboss/portal/core/model/portal/command/render/RenderPageCommand.java
trunk/theme/src/main/org/jboss/portal/theme/LayoutServiceInfo.java
trunk/theme/src/main/org/jboss/portal/theme/ThemeServiceInfo.java
trunk/theme/src/main/org/jboss/portal/theme/impl/LayoutServiceImpl.java
trunk/theme/src/main/org/jboss/portal/theme/impl/ThemeServiceImpl.java
Log:
moved theme code to theme place
Modified: trunk/core/src/main/org/jboss/portal/core/model/portal/command/render/RenderPageCommand.java
===================================================================
--- trunk/core/src/main/org/jboss/portal/core/model/portal/command/render/RenderPageCommand.java 2007-04-25 19:19:43 UTC (rev 7052)
+++ trunk/core/src/main/org/jboss/portal/core/model/portal/command/render/RenderPageCommand.java 2007-04-25 19:40:14 UTC (rev 7053)
@@ -44,9 +44,7 @@
import org.jboss.portal.core.theme.WindowRendition;
import org.jboss.portal.theme.PortalLayout;
import org.jboss.portal.theme.PortalTheme;
-import org.jboss.portal.theme.ServerRegistrationID;
import org.jboss.portal.theme.ThemeConstants;
-import org.jboss.portal.theme.ThemeService;
import org.jboss.portal.theme.PageService;
import org.jboss.portal.theme.page.PageResult;
import org.jboss.portal.theme.page.WindowResult;
@@ -58,8 +56,6 @@
import java.util.Collection;
import java.util.HashMap;
import java.util.Iterator;
-import java.util.List;
-import java.util.StringTokenizer;
/**
* Render a full page.
@@ -263,41 +259,7 @@
private PortalTheme getTheme(String themeIdString)
{
- //
- ThemeService service = context.getController().getPageService().getThemeService();
-
- PortalTheme theme;
-
- // If the id is provided in the form of context.name then look up the theme via a registration id
- if (themeIdString == null)
- {
- theme = service.getDefaultTheme();
- }
- else if (themeIdString.lastIndexOf(".") > 0)
- {
- ServerRegistrationID themeId = ServerRegistrationID.createID(ServerRegistrationID.TYPE_THEME, parseId(themeIdString));
- theme = service.getTheme(themeId, true);
- }
- else
- {
- // Otherwise use the ordinary theme name provided and lookup the theme via the name
- theme = service.getTheme(themeIdString, true);
- }
-
- // Last Chance
- if (theme == null)
- {
- theme = service.getTheme("renaissance", true);
- }
-
- // We don't like that situation
- if (theme == null)
- {
- throw new IllegalStateException("No Theme found for " + themeIdString);
- }
-
- //
- return theme;
+ return context.getController().getPageService().getThemeService().getThemeById(themeIdString);
}
/**
@@ -312,67 +274,6 @@
public static PortalLayout getLayout(LayoutService layoutService, Page page)
{
String layoutIdString = page.getProperty(ThemeConstants.PORTAL_PROP_LAYOUT);
-
- //
- PortalLayout layout;
-
- if (layoutIdString == null)
- {
- layout = layoutService.getDefaultLayout();
- }
- else if (layoutIdString.lastIndexOf(".") > 0)
- {
- // if the id is provided in the form of context.name then look up the layout via a registration id
- ServerRegistrationID layoutID = ServerRegistrationID.createID(ServerRegistrationID.TYPE_LAYOUT, parseId(layoutIdString));
- layout = layoutService.getLayout(layoutID, true);
- }
- else
- {
- // otherwise use the ordinary layout name provided and lookup the layout via the name
- layout = layoutService.getLayout(layoutIdString, true);
- }
-
- // Last Chance
- if (layout == null)
- {
- layout = layoutService.getLayout("generic", true);
- }
-
- // We don't like that situation
- if (layout == null)
- {
- throw new IllegalStateException("NO LAYOUT FOUND FOR " + layoutIdString);
- }
-
- //
- return layout;
+ return layoutService.getLayoutById(layoutIdString);
}
-
- /**
- * parse the provided String for '.' as a separator. For each token, add an entry to a String[] that will be returned
- * as the result
- *
- * @param layoutIDString the string to be examined
- * @return an array of Strings
- */
- private static String[] parseId(String layoutIDString)
- {
- List names = new ArrayList();
- StringTokenizer tokens = new StringTokenizer(layoutIDString, ".");
- if (tokens.countTokens() > 1)
- {
- while (tokens.hasMoreElements())
- {
- names.add(tokens.nextToken());
- }
- }
- else
- {
- names.add(layoutIDString);
- }
-
- String[] id = new String[names.size()];
- names.toArray(id);
- return id;
- }
}
Modified: trunk/theme/src/main/org/jboss/portal/theme/LayoutServiceInfo.java
===================================================================
--- trunk/theme/src/main/org/jboss/portal/theme/LayoutServiceInfo.java 2007-04-25 19:19:43 UTC (rev 7052)
+++ trunk/theme/src/main/org/jboss/portal/theme/LayoutServiceInfo.java 2007-04-25 19:40:14 UTC (rev 7053)
@@ -25,7 +25,6 @@
import org.jboss.portal.common.util.MediaType;
import org.jboss.portal.common.util.ContentInfo;
-import org.jboss.portal.theme.PortalRenderSet;
import java.util.Collection;
@@ -57,6 +56,8 @@
*/
PortalLayout getLayout(String name, boolean defaultOnNull);
+ PortalLayout getLayoutById(String layoutIdString);
+
/**
* Get the render set for the provided layout.
*
Modified: trunk/theme/src/main/org/jboss/portal/theme/ThemeServiceInfo.java
===================================================================
--- trunk/theme/src/main/org/jboss/portal/theme/ThemeServiceInfo.java 2007-04-25 19:19:43 UTC (rev 7052)
+++ trunk/theme/src/main/org/jboss/portal/theme/ThemeServiceInfo.java 2007-04-25 19:40:14 UTC (rev 7053)
@@ -54,6 +54,14 @@
PortalTheme getTheme(String name, boolean defaultOnNull);
/**
+ *
+ *
+ * @param themeId
+ * @return
+ */
+ PortalTheme getThemeById(String themeId);
+
+ /**
* Get a Collection of all registered themes.
*
* @return a Collection of all registered themes
Modified: trunk/theme/src/main/org/jboss/portal/theme/impl/LayoutServiceImpl.java
===================================================================
--- trunk/theme/src/main/org/jboss/portal/theme/impl/LayoutServiceImpl.java 2007-04-25 19:19:43 UTC (rev 7052)
+++ trunk/theme/src/main/org/jboss/portal/theme/impl/LayoutServiceImpl.java 2007-04-25 19:40:14 UTC (rev 7053)
@@ -233,6 +233,43 @@
return null;
}
+ public PortalLayout getLayoutById(String layoutIdString)
+ {
+ //
+ PortalLayout layout;
+
+ if (layoutIdString == null)
+ {
+ layout = getDefaultLayout();
+ }
+ else if (layoutIdString.lastIndexOf(".") > 0)
+ {
+ // if the id is provided in the form of context.name then look up the layout via a registration id
+ ServerRegistrationID layoutID = ServerRegistrationID.createID(ServerRegistrationID.TYPE_LAYOUT, ThemeServiceImpl.parseId(layoutIdString));
+ layout = getLayout(layoutID, true);
+ }
+ else
+ {
+ // otherwise use the ordinary layout name provided and lookup the layout via the name
+ layout = getLayout(layoutIdString, true);
+ }
+
+ // Last Chance
+ if (layout == null)
+ {
+ layout = getLayout("generic", true);
+ }
+
+ // We don't like that situation
+ if (layout == null)
+ {
+ throw new IllegalStateException("NO LAYOUT FOUND FOR " + layoutIdString);
+ }
+
+ //
+ return layout;
+ }
+
/**
* Remove the layout identified by the provided registration id.
*
Modified: trunk/theme/src/main/org/jboss/portal/theme/impl/ThemeServiceImpl.java
===================================================================
--- trunk/theme/src/main/org/jboss/portal/theme/impl/ThemeServiceImpl.java 2007-04-25 19:19:43 UTC (rev 7052)
+++ trunk/theme/src/main/org/jboss/portal/theme/impl/ThemeServiceImpl.java 2007-04-25 19:40:14 UTC (rev 7053)
@@ -24,8 +24,6 @@
import org.jboss.logging.Logger;
import org.jboss.portal.jems.as.system.AbstractJBossService;
-import org.jboss.portal.theme.LayoutService;
-import org.jboss.portal.theme.PortalLayout;
import org.jboss.portal.theme.PortalTheme;
import org.jboss.portal.theme.RuntimeContext;
import org.jboss.portal.theme.ServerRegistrationID;
@@ -42,6 +40,7 @@
import java.util.Iterator;
import java.util.List;
import java.util.Map;
+import java.util.StringTokenizer;
/**
* TODO: A description of this class.
@@ -314,6 +313,42 @@
return null;
}
+ public PortalTheme getThemeById(String themeIdString)
+ {
+ PortalTheme theme;
+
+ // If the id is provided in the form of context.name then look up the theme via a registration id
+ if (themeIdString == null)
+ {
+ theme = getDefaultTheme();
+ }
+ else if (themeIdString.lastIndexOf(".") > 0)
+ {
+ ServerRegistrationID themeId = ServerRegistrationID.createID(ServerRegistrationID.TYPE_THEME, parseId(themeIdString));
+ theme = getTheme(themeId, true);
+ }
+ else
+ {
+ // Otherwise use the ordinary theme name provided and lookup the theme via the name
+ theme = getTheme(themeIdString, true);
+ }
+
+ // Last Chance
+ if (theme == null)
+ {
+ theme = getTheme("renaissance", true);
+ }
+
+ // We don't like that situation
+ if (theme == null)
+ {
+ throw new IllegalStateException("No Theme found for " + themeIdString);
+ }
+
+ //
+ return theme;
+ }
+
/** @see org.jboss.portal.theme.ThemeService#getThemes() */
public Collection getThemes()
{
@@ -325,4 +360,32 @@
{
return Collections.unmodifiableCollection(themeNames.keySet());
}
+
+ /**
+ * parse the provided String for '.' as a separator. For each token, add an entry to a String[] that will be returned
+ * as the result
+ *
+ * @param layoutIDString the string to be examined
+ * @return an array of Strings
+ */
+ public static String[] parseId(String layoutIDString)
+ {
+ List names = new ArrayList();
+ StringTokenizer tokens = new StringTokenizer(layoutIDString, ".");
+ if (tokens.countTokens() > 1)
+ {
+ while (tokens.hasMoreElements())
+ {
+ names.add(tokens.nextToken());
+ }
+ }
+ else
+ {
+ names.add(layoutIDString);
+ }
+
+ String[] id = new String[names.size()];
+ names.toArray(id);
+ return id;
+ }
}
17 years, 2 months
JBoss Portal SVN: r7052 - in trunk/core/src/main/org/jboss/portal/core: controller and 6 other directories.
by portal-commits@lists.jboss.org
Author: julien(a)jboss.com
Date: 2007-04-25 15:19:43 -0400 (Wed, 25 Apr 2007)
New Revision: 7052
Added:
trunk/core/src/main/org/jboss/portal/core/model/portal/navstate/
Removed:
trunk/core/src/main/org/jboss/portal/core/model/portal/ns/
Modified:
trunk/core/src/main/org/jboss/portal/core/aspects/controller/NavigationalStateInterceptor.java
trunk/core/src/main/org/jboss/portal/core/controller/ControllerContext.java
trunk/core/src/main/org/jboss/portal/core/controller/ajax/AjaxInterceptor.java
trunk/core/src/main/org/jboss/portal/core/controller/ajax/AjaxResponseHandler.java
trunk/core/src/main/org/jboss/portal/core/impl/api/CoreNavigationalStateContext.java
trunk/core/src/main/org/jboss/portal/core/impl/model/content/InternalContentProvider.java
trunk/core/src/main/org/jboss/portal/core/model/portal/PortalObjectCommandFactory.java
trunk/core/src/main/org/jboss/portal/core/model/portal/command/action/InvokePortletWindowRenderCommand.java
trunk/core/src/main/org/jboss/portal/core/model/portal/navstate/PortalObjectNavigationalStateContext.java
trunk/core/src/main/org/jboss/portal/core/model/portal/navstate/WindowNavigationalState.java
Log:
renamed package ns to navstate
Modified: trunk/core/src/main/org/jboss/portal/core/aspects/controller/NavigationalStateInterceptor.java
===================================================================
--- trunk/core/src/main/org/jboss/portal/core/aspects/controller/NavigationalStateInterceptor.java 2007-04-25 17:13:56 UTC (rev 7051)
+++ trunk/core/src/main/org/jboss/portal/core/aspects/controller/NavigationalStateInterceptor.java 2007-04-25 19:19:43 UTC (rev 7052)
@@ -26,7 +26,7 @@
import org.jboss.portal.core.controller.ControllerCommand;
import org.jboss.portal.core.controller.ControllerContext;
import org.jboss.portal.core.controller.ControllerResponse;
-import org.jboss.portal.core.model.portal.ns.PortalObjectNavigationalStateContext;
+import org.jboss.portal.core.model.portal.navstate.PortalObjectNavigationalStateContext;
import org.jboss.portal.common.invocation.InvocationException;
/**
Modified: trunk/core/src/main/org/jboss/portal/core/controller/ControllerContext.java
===================================================================
--- trunk/core/src/main/org/jboss/portal/core/controller/ControllerContext.java 2007-04-25 17:13:56 UTC (rev 7051)
+++ trunk/core/src/main/org/jboss/portal/core/controller/ControllerContext.java 2007-04-25 19:19:43 UTC (rev 7052)
@@ -31,7 +31,7 @@
import org.jboss.portal.server.request.URLFormat;
import org.jboss.portal.identity.User;
import org.jboss.portal.core.aspects.server.UserInterceptor;
-import org.jboss.portal.core.model.portal.ns.PortalObjectNavigationalStateContext;
+import org.jboss.portal.core.model.portal.navstate.PortalObjectNavigationalStateContext;
import javax.servlet.http.HttpServletRequest;
import java.util.Map;
Modified: trunk/core/src/main/org/jboss/portal/core/controller/ajax/AjaxInterceptor.java
===================================================================
--- trunk/core/src/main/org/jboss/portal/core/controller/ajax/AjaxInterceptor.java 2007-04-25 17:13:56 UTC (rev 7051)
+++ trunk/core/src/main/org/jboss/portal/core/controller/ajax/AjaxInterceptor.java 2007-04-25 19:19:43 UTC (rev 7052)
@@ -28,7 +28,7 @@
import org.jboss.portal.core.controller.ControllerContext;
import org.jboss.portal.core.controller.ControllerResponse;
import org.jboss.portal.core.model.portal.command.render.RenderPageCommand;
-import org.jboss.portal.core.model.portal.ns.PortalObjectNavigationalStateContext;
+import org.jboss.portal.core.model.portal.navstate.PortalObjectNavigationalStateContext;
import org.jboss.portal.core.theme.PageRendition;
import org.jboss.portal.theme.impl.render.dynamic.DynaConstants;
import org.jboss.portal.theme.impl.render.dynamic.DynaRenderOptions;
Modified: trunk/core/src/main/org/jboss/portal/core/controller/ajax/AjaxResponseHandler.java
===================================================================
--- trunk/core/src/main/org/jboss/portal/core/controller/ajax/AjaxResponseHandler.java 2007-04-25 17:13:56 UTC (rev 7051)
+++ trunk/core/src/main/org/jboss/portal/core/controller/ajax/AjaxResponseHandler.java 2007-04-25 19:19:43 UTC (rev 7052)
@@ -43,8 +43,8 @@
import org.jboss.portal.core.model.portal.PortalObject;
import org.jboss.portal.core.model.portal.PortalObjectId;
import org.jboss.portal.core.model.portal.PortalObjectContainer;
-import org.jboss.portal.core.model.portal.ns.PortalObjectNavigationalStateContext;
-import org.jboss.portal.core.model.portal.ns.WindowNavigationalState;
+import org.jboss.portal.core.model.portal.navstate.PortalObjectNavigationalStateContext;
+import org.jboss.portal.core.model.portal.navstate.WindowNavigationalState;
import org.jboss.portal.core.navstate.NavigationalStateChange;
import org.jboss.portal.core.navstate.NavigationalStateObjectChange;
import org.jboss.portal.core.navstate.NavigationalStateKey;
Modified: trunk/core/src/main/org/jboss/portal/core/impl/api/CoreNavigationalStateContext.java
===================================================================
--- trunk/core/src/main/org/jboss/portal/core/impl/api/CoreNavigationalStateContext.java 2007-04-25 17:13:56 UTC (rev 7051)
+++ trunk/core/src/main/org/jboss/portal/core/impl/api/CoreNavigationalStateContext.java 2007-04-25 19:19:43 UTC (rev 7052)
@@ -24,7 +24,7 @@
import org.jboss.portal.api.navstate.NavigationalStateContext;
import org.jboss.portal.core.navstate.NavigationalStateKey;
-import org.jboss.portal.core.model.portal.ns.WindowNavigationalState;
+import org.jboss.portal.core.model.portal.navstate.WindowNavigationalState;
import org.jboss.portal.api.node.PortalNode;
import org.jboss.portal.Mode;
import org.jboss.portal.WindowState;
Modified: trunk/core/src/main/org/jboss/portal/core/impl/model/content/InternalContentProvider.java
===================================================================
--- trunk/core/src/main/org/jboss/portal/core/impl/model/content/InternalContentProvider.java 2007-04-25 17:13:56 UTC (rev 7051)
+++ trunk/core/src/main/org/jboss/portal/core/impl/model/content/InternalContentProvider.java 2007-04-25 19:19:43 UTC (rev 7052)
@@ -32,7 +32,7 @@
import org.jboss.portal.core.model.portal.Window;
import org.jboss.portal.core.model.portal.Portal;
import org.jboss.portal.core.model.portal.PortalObjectId;
-import org.jboss.portal.core.model.portal.ns.WindowNavigationalState;
+import org.jboss.portal.core.model.portal.navstate.WindowNavigationalState;
import org.jboss.portal.core.model.portal.content.ContentRenderer;
import org.jboss.portal.core.controller.ControllerContext;
import org.jboss.portal.core.controller.ResourceNotFoundException;
Modified: trunk/core/src/main/org/jboss/portal/core/model/portal/PortalObjectCommandFactory.java
===================================================================
--- trunk/core/src/main/org/jboss/portal/core/model/portal/PortalObjectCommandFactory.java 2007-04-25 17:13:56 UTC (rev 7051)
+++ trunk/core/src/main/org/jboss/portal/core/model/portal/PortalObjectCommandFactory.java 2007-04-25 19:19:43 UTC (rev 7052)
@@ -31,7 +31,7 @@
import org.jboss.portal.core.model.portal.command.action.InvokePortletWindowRenderCommand;
import org.jboss.portal.core.model.portal.command.action.ImportPageToDashboardCommand;
import org.jboss.portal.core.model.portal.command.view.ViewPageCommand;
-import org.jboss.portal.core.model.portal.ns.WindowNavigationalState;
+import org.jboss.portal.core.model.portal.navstate.WindowNavigationalState;
import org.jboss.portal.core.controller.command.mapper.AbstractCommandFactory;
import org.jboss.portal.core.navstate.NavigationalStateKey;
import org.jboss.portal.portlet.impl.PortletRequestDecoder;
Modified: trunk/core/src/main/org/jboss/portal/core/model/portal/command/action/InvokePortletWindowRenderCommand.java
===================================================================
--- trunk/core/src/main/org/jboss/portal/core/model/portal/command/action/InvokePortletWindowRenderCommand.java 2007-04-25 17:13:56 UTC (rev 7051)
+++ trunk/core/src/main/org/jboss/portal/core/model/portal/command/action/InvokePortletWindowRenderCommand.java 2007-04-25 19:19:43 UTC (rev 7052)
@@ -32,7 +32,7 @@
import org.jboss.portal.core.model.portal.command.response.UpdateWindowResponse;
import org.jboss.portal.core.model.portal.command.action.InvokeWindowCommand;
import org.jboss.portal.core.model.portal.PortalObjectId;
-import org.jboss.portal.core.model.portal.ns.WindowNavigationalState;
+import org.jboss.portal.core.model.portal.navstate.WindowNavigationalState;
import org.jboss.portal.core.navstate.NavigationalStateKey;
import org.jboss.portal.portlet.StateString;
Copied: trunk/core/src/main/org/jboss/portal/core/model/portal/navstate (from rev 7048, trunk/core/src/main/org/jboss/portal/core/model/portal/ns)
Modified: trunk/core/src/main/org/jboss/portal/core/model/portal/navstate/PortalObjectNavigationalStateContext.java
===================================================================
--- trunk/core/src/main/org/jboss/portal/core/model/portal/ns/PortalObjectNavigationalStateContext.java 2007-04-25 15:57:31 UTC (rev 7048)
+++ trunk/core/src/main/org/jboss/portal/core/model/portal/navstate/PortalObjectNavigationalStateContext.java 2007-04-25 19:19:43 UTC (rev 7052)
@@ -20,7 +20,7 @@
* 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.core.model.portal.ns;
+package org.jboss.portal.core.model.portal.navstate;
import org.jboss.portal.core.navstate.NavigationalStateContext;
import org.jboss.portal.core.navstate.NavigationalStateKey;
Modified: trunk/core/src/main/org/jboss/portal/core/model/portal/navstate/WindowNavigationalState.java
===================================================================
--- trunk/core/src/main/org/jboss/portal/core/model/portal/ns/WindowNavigationalState.java 2007-04-25 15:57:31 UTC (rev 7048)
+++ trunk/core/src/main/org/jboss/portal/core/model/portal/navstate/WindowNavigationalState.java 2007-04-25 19:19:43 UTC (rev 7052)
@@ -20,7 +20,7 @@
* 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.core.model.portal.ns;
+package org.jboss.portal.core.model.portal.navstate;
import org.jboss.portal.WindowState;
import org.jboss.portal.Mode;
17 years, 2 months
JBoss Portal SVN: r7051 - in trunk/build: ide/intellij/idea60/modules/test and 1 other directories.
by portal-commits@lists.jboss.org
Author: julien(a)jboss.com
Date: 2007-04-25 13:13:56 -0400 (Wed, 25 Apr 2007)
New Revision: 7051
Modified:
trunk/build/build.xml
trunk/build/ide/intellij/idea60/modules/test/test.iml
trunk/build/ide/intellij/idea60/modules/theme/theme.iml
Log:
update javadoc generation
Modified: trunk/build/build.xml
===================================================================
--- trunk/build/build.xml 2007-04-25 16:55:18 UTC (rev 7050)
+++ trunk/build/build.xml 2007-04-25 17:13:56 UTC (rev 7051)
@@ -13,7 +13,7 @@
<!--+======================================================================+-->
<!--| JBoss Portal: The OpenSource Portal |-->
<!--| |-->
-<!--| Distributable under GPL license. |-->
+<!--| Distributable under LGPL license. |-->
<!--| See terms of license at http://www.gnu.org. |-->
<!--| |-->
<!--| This file has been designed to work with the 'tools' module and |-->
@@ -172,8 +172,8 @@
<target name="modules-tests" depends="_buildmagic:modules:tests"/>
<target name="modules-clean" depends="_buildmagic:modules:clean"/>
<target name="modules-clobber" depends="_buildmagic:modules:clobber"/>
+ <target name="modules-package-tests" depends="_buildmagic:modules:package-tests"/>
-
<!--+====================================================================+-->
<!--| Module Pass-through Hooks |-->
<!--| |-->
@@ -259,7 +259,6 @@
<target name="help" depends="_buildmagic:help:build"
description="Show this help message."/>
-
<!--
| Deploy the application
-->
@@ -307,6 +306,9 @@
<packageset dir="../common/src/main">
<exclude name="org/jboss/portal/test/**"/>
</packageset>
+ <packageset dir="../web/src/main">
+ <exclude name="org/jboss/portal/test/**"/>
+ </packageset>
<packageset dir="../server/src/main">
<exclude name="org/jboss/portal/test/**"/>
</packageset>
@@ -316,6 +318,9 @@
<packageset dir="../portlet/src/main">
<exclude name="org/jboss/portal/test/**"/>
</packageset>
+ <packageset dir="../portlet-server/src/main">
+ <exclude name="org/jboss/portal/test/**"/>
+ </packageset>
<packageset dir="../jems/src/main">
<exclude name="org/jboss/portal/test/**"/>
</packageset>
@@ -343,6 +348,15 @@
<packageset dir="../core/src/main">
<exclude name="org/jboss/portal/test/**"/>
</packageset>
+ <packageset dir="../core-admin/src/main">
+ <exclude name="org/jboss/portal/test/**"/>
+ </packageset>
+ <packageset dir="../core-cms/src/main">
+ <exclude name="org/jboss/portal/test/**"/>
+ </packageset>
+ <packageset dir="../core-management/src/main">
+ <exclude name="org/jboss/portal/test/**"/>
+ </packageset>
<packageset dir="../security/src/main">
<exclude name="org/jboss/portal/test/**"/>
</packageset>
@@ -355,6 +369,15 @@
<packageset dir="../registration/src/main">
<exclude name="org/jboss/portal/test/**"/>
</packageset>
+ <packageset dir="../widget/src/main">
+ <exclude name="org/jboss/portal/test/**"/>
+ </packageset>
+ <packageset dir="../workflow/src/main">
+ <exclude name="org/jboss/portal/test/**"/>
+ </packageset>
+ <packageset dir="../search/src/main">
+ <exclude name="org/jboss/portal/test/**"/>
+ </packageset>
</javadoc>
</target>
Modified: trunk/build/ide/intellij/idea60/modules/test/test.iml
===================================================================
--- trunk/build/ide/intellij/idea60/modules/test/test.iml 2007-04-25 16:55:18 UTC (rev 7050)
+++ trunk/build/ide/intellij/idea60/modules/test/test.iml 2007-04-25 17:13:56 UTC (rev 7051)
@@ -290,6 +290,15 @@
<SOURCES />
</library>
</orderEntry>
+ <orderEntry type="module-library">
+ <library>
+ <CLASSES>
+ <root url="jar://$MODULE_DIR$/../../../../../../test/selenium-java-client-driver-backport.jar!/" />
+ </CLASSES>
+ <JAVADOC />
+ <SOURCES />
+ </library>
+ </orderEntry>
<orderEntryProperties />
</component>
<component name="VcsManagerConfiguration">
Modified: trunk/build/ide/intellij/idea60/modules/theme/theme.iml
===================================================================
--- trunk/build/ide/intellij/idea60/modules/theme/theme.iml 2007-04-25 16:55:18 UTC (rev 7050)
+++ trunk/build/ide/intellij/idea60/modules/theme/theme.iml 2007-04-25 17:13:56 UTC (rev 7051)
@@ -97,6 +97,7 @@
</orderEntry>
<orderEntry type="module" module-name="jems" />
<orderEntry type="module" module-name="web" />
+ <orderEntry type="module" module-name="test" />
<orderEntryProperties />
</component>
<component name="VcsManagerConfiguration">
17 years, 2 months
JBoss Portal SVN: r7050 - in trunk/core/src: main/org/jboss/portal/core/controller/ajax and 6 other directories.
by portal-commits@lists.jboss.org
Author: julien(a)jboss.com
Date: 2007-04-25 12:55:18 -0400 (Wed, 25 Apr 2007)
New Revision: 7050
Added:
trunk/core/src/main/org/jboss/portal/core/controller/handler/ResponseHandlerException.java
trunk/core/src/main/org/jboss/portal/core/controller/handler/ResponseHandlerSelector.java
Removed:
trunk/core/src/main/org/jboss/portal/core/controller/ResponseHandlerException.java
trunk/core/src/main/org/jboss/portal/core/controller/ResponseHandlerSelector.java
Modified:
trunk/core/src/main/org/jboss/portal/core/controller/Controller.java
trunk/core/src/main/org/jboss/portal/core/controller/ajax/AjaxResponseHandler.java
trunk/core/src/main/org/jboss/portal/core/controller/classic/ClassicResponseHandler.java
trunk/core/src/main/org/jboss/portal/core/controller/classic/ThrowableResponseHandler.java
trunk/core/src/main/org/jboss/portal/core/controller/handler/ResponseHandler.java
trunk/core/src/main/org/jboss/portal/core/controller/portlet/PortletResponseHandler.java
trunk/core/src/main/org/jboss/portal/core/model/instance/PortletInstanceResponseHandler.java
trunk/core/src/main/org/jboss/portal/core/model/portal/PortalObjectResponseHandler.java
trunk/core/src/resources/portal-core-sar/META-INF/jboss-service.xml
Log:
move ResponseHandler related class to the handler package
Modified: trunk/core/src/main/org/jboss/portal/core/controller/Controller.java
===================================================================
--- trunk/core/src/main/org/jboss/portal/core/controller/Controller.java 2007-04-25 15:59:51 UTC (rev 7049)
+++ trunk/core/src/main/org/jboss/portal/core/controller/Controller.java 2007-04-25 16:55:18 UTC (rev 7050)
@@ -32,6 +32,7 @@
import org.jboss.portal.core.controller.handler.CommandForward;
import org.jboss.portal.core.controller.handler.ResponseHandler;
import org.jboss.portal.core.controller.handler.AjaxResponse;
+import org.jboss.portal.core.controller.handler.ResponseHandlerException;
import org.jboss.portal.core.model.portal.PortalObjectContainer;
import org.jboss.portal.core.model.portal.content.ContentRendererRegistry;
import org.jboss.portal.core.model.instance.InstanceContainer;
Deleted: trunk/core/src/main/org/jboss/portal/core/controller/ResponseHandlerException.java
===================================================================
--- trunk/core/src/main/org/jboss/portal/core/controller/ResponseHandlerException.java 2007-04-25 15:59:51 UTC (rev 7049)
+++ trunk/core/src/main/org/jboss/portal/core/controller/ResponseHandlerException.java 2007-04-25 16:55:18 UTC (rev 7050)
@@ -1,49 +0,0 @@
-/******************************************************************************
- * JBoss, a division of Red Hat *
- * Copyright 2006, Red Hat Middleware, LLC, and individual *
- * contributors as indicated by the @authors tag. See the *
- * copyright.txt in the distribution for a full listing of *
- * individual contributors. *
- * *
- * This is free software; you can redistribute it and/or modify it *
- * under the terms of the GNU Lesser General Public License as *
- * published by the Free Software Foundation; either version 2.1 of *
- * the License, or (at your option) any later version. *
- * *
- * This software is distributed in the hope that it will be useful, *
- * but WITHOUT ANY WARRANTY; without even the implied warranty of *
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU *
- * Lesser General Public License for more details. *
- * *
- * You should have received a copy of the GNU Lesser General Public *
- * License along with this software; if not, write to the Free *
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA *
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org. *
- ******************************************************************************/
-package org.jboss.portal.core.controller;
-
-/**
- * @author <a href="mailto:julien@jboss.org">Julien Viet</a>
- * @version $Revision: 1.1 $
- */
-public class ResponseHandlerException extends Exception
-{
- public ResponseHandlerException()
- {
- }
-
- public ResponseHandlerException(String message)
- {
- super(message);
- }
-
- public ResponseHandlerException(String message, Throwable cause)
- {
- super(message, cause);
- }
-
- public ResponseHandlerException(Throwable cause)
- {
- super(cause);
- }
-}
Deleted: trunk/core/src/main/org/jboss/portal/core/controller/ResponseHandlerSelector.java
===================================================================
--- trunk/core/src/main/org/jboss/portal/core/controller/ResponseHandlerSelector.java 2007-04-25 15:59:51 UTC (rev 7049)
+++ trunk/core/src/main/org/jboss/portal/core/controller/ResponseHandlerSelector.java 2007-04-25 16:55:18 UTC (rev 7050)
@@ -1,72 +0,0 @@
-/******************************************************************************
- * JBoss, a division of Red Hat *
- * Copyright 2006, Red Hat Middleware, LLC, and individual *
- * contributors as indicated by the @authors tag. See the *
- * copyright.txt in the distribution for a full listing of *
- * individual contributors. *
- * *
- * This is free software; you can redistribute it and/or modify it *
- * under the terms of the GNU Lesser General Public License as *
- * published by the Free Software Foundation; either version 2.1 of *
- * the License, or (at your option) any later version. *
- * *
- * This software is distributed in the hope that it will be useful, *
- * but WITHOUT ANY WARRANTY; without even the implied warranty of *
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU *
- * Lesser General Public License for more details. *
- * *
- * You should have received a copy of the GNU Lesser General Public *
- * License along with this software; if not, write to the Free *
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA *
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org. *
- ******************************************************************************/
-package org.jboss.portal.core.controller;
-
-import org.jboss.portal.core.controller.handler.ResponseHandler;
-import org.jboss.portal.core.controller.handler.HandlerResponse;
-
-/**
- * @author <a href="mailto:julien@jboss.org">Julien Viet</a>
- * @version $Revision: 1.1 $
- */
-public class ResponseHandlerSelector implements ResponseHandler
-{
-
- /** . */
- private ResponseHandler classicResponseHandler;
-
- /** . */
- private ResponseHandler ajaxResponseHandler;
-
- public ResponseHandler getClassicResponseHandler()
- {
- return classicResponseHandler;
- }
-
- public void setClassicResponseHandler(ResponseHandler classicResponseHandler)
- {
- this.classicResponseHandler = classicResponseHandler;
- }
-
- public ResponseHandler getAjaxResponseHandler()
- {
- return ajaxResponseHandler;
- }
-
- public void setAjaxResponseHandler(ResponseHandler ajaxResponseHandler)
- {
- this.ajaxResponseHandler = ajaxResponseHandler;
- }
-
- public HandlerResponse processCommandResponse(ControllerContext controllerContext, ControllerCommand command, ControllerResponse response) throws ResponseHandlerException
- {
- if (ControllerContext.AJAX_TYPE == controllerContext.getType())
- {
- return ajaxResponseHandler.processCommandResponse(controllerContext, command, response);
- }
- else
- {
- return classicResponseHandler.processCommandResponse(controllerContext, command, response);
- }
- }
-}
Modified: trunk/core/src/main/org/jboss/portal/core/controller/ajax/AjaxResponseHandler.java
===================================================================
--- trunk/core/src/main/org/jboss/portal/core/controller/ajax/AjaxResponseHandler.java 2007-04-25 15:59:51 UTC (rev 7049)
+++ trunk/core/src/main/org/jboss/portal/core/controller/ajax/AjaxResponseHandler.java 2007-04-25 16:55:18 UTC (rev 7050)
@@ -28,7 +28,7 @@
import org.jboss.portal.core.controller.ControllerContext;
import org.jboss.portal.core.controller.ControllerCommand;
import org.jboss.portal.core.controller.ControllerResponse;
-import org.jboss.portal.core.controller.ResponseHandlerException;
+import org.jboss.portal.core.controller.handler.ResponseHandlerException;
import org.jboss.portal.core.controller.handler.CommandForward;
import org.jboss.portal.core.controller.portlet.PortletResponseHandler;
import org.jboss.portal.core.model.portal.command.response.PortletWindowResponse;
Modified: trunk/core/src/main/org/jboss/portal/core/controller/classic/ClassicResponseHandler.java
===================================================================
--- trunk/core/src/main/org/jboss/portal/core/controller/classic/ClassicResponseHandler.java 2007-04-25 15:59:51 UTC (rev 7049)
+++ trunk/core/src/main/org/jboss/portal/core/controller/classic/ClassicResponseHandler.java 2007-04-25 16:55:18 UTC (rev 7050)
@@ -32,7 +32,7 @@
import org.jboss.portal.core.controller.command.info.ActionCommandInfo;
import org.jboss.portal.core.controller.ControllerCommand;
import org.jboss.portal.core.controller.ControllerContext;
-import org.jboss.portal.core.controller.ResponseHandlerException;
+import org.jboss.portal.core.controller.handler.ResponseHandlerException;
import org.jboss.portal.core.controller.ControllerResponse;
import org.jboss.portal.core.controller.handler.AbstractResponseHandler;
import org.jboss.portal.core.controller.handler.HTTPResponse;
Modified: trunk/core/src/main/org/jboss/portal/core/controller/classic/ThrowableResponseHandler.java
===================================================================
--- trunk/core/src/main/org/jboss/portal/core/controller/classic/ThrowableResponseHandler.java 2007-04-25 15:59:51 UTC (rev 7049)
+++ trunk/core/src/main/org/jboss/portal/core/controller/classic/ThrowableResponseHandler.java 2007-04-25 16:55:18 UTC (rev 7050)
@@ -25,9 +25,9 @@
import org.jboss.portal.core.controller.handler.ResponseHandler;
import org.jboss.portal.core.controller.handler.HandlerResponse;
import org.jboss.portal.core.controller.handler.HTTPResponse;
+import org.jboss.portal.core.controller.handler.ResponseHandlerException;
import org.jboss.portal.core.controller.ControllerContext;
import org.jboss.portal.core.controller.ControllerCommand;
-import org.jboss.portal.core.controller.ResponseHandlerException;
import org.jboss.portal.core.controller.ControllerSecurityException;
import org.jboss.portal.core.controller.ResourceNotFoundException;
import org.jboss.portal.core.controller.ControllerException;
Modified: trunk/core/src/main/org/jboss/portal/core/controller/handler/ResponseHandler.java
===================================================================
--- trunk/core/src/main/org/jboss/portal/core/controller/handler/ResponseHandler.java 2007-04-25 15:59:51 UTC (rev 7049)
+++ trunk/core/src/main/org/jboss/portal/core/controller/handler/ResponseHandler.java 2007-04-25 16:55:18 UTC (rev 7050)
@@ -24,7 +24,7 @@
import org.jboss.portal.core.controller.ControllerCommand;
import org.jboss.portal.core.controller.ControllerContext;
-import org.jboss.portal.core.controller.ResponseHandlerException;
+import org.jboss.portal.core.controller.handler.ResponseHandlerException;
import org.jboss.portal.core.controller.ControllerResponse;
/**
Copied: trunk/core/src/main/org/jboss/portal/core/controller/handler/ResponseHandlerException.java (from rev 7048, trunk/core/src/main/org/jboss/portal/core/controller/ResponseHandlerException.java)
===================================================================
--- trunk/core/src/main/org/jboss/portal/core/controller/handler/ResponseHandlerException.java (rev 0)
+++ trunk/core/src/main/org/jboss/portal/core/controller/handler/ResponseHandlerException.java 2007-04-25 16:55:18 UTC (rev 7050)
@@ -0,0 +1,49 @@
+/******************************************************************************
+ * JBoss, a division of Red Hat *
+ * Copyright 2006, Red Hat Middleware, LLC, and individual *
+ * contributors as indicated by the @authors tag. See the *
+ * copyright.txt in the distribution for a full listing of *
+ * individual contributors. *
+ * *
+ * This is free software; you can redistribute it and/or modify it *
+ * under the terms of the GNU Lesser General Public License as *
+ * published by the Free Software Foundation; either version 2.1 of *
+ * the License, or (at your option) any later version. *
+ * *
+ * This software is distributed in the hope that it will be useful, *
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of *
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU *
+ * Lesser General Public License for more details. *
+ * *
+ * You should have received a copy of the GNU Lesser General Public *
+ * License along with this software; if not, write to the Free *
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA *
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org. *
+ ******************************************************************************/
+package org.jboss.portal.core.controller.handler;
+
+/**
+ * @author <a href="mailto:julien@jboss.org">Julien Viet</a>
+ * @version $Revision: 1.1 $
+ */
+public class ResponseHandlerException extends Exception
+{
+ public ResponseHandlerException()
+ {
+ }
+
+ public ResponseHandlerException(String message)
+ {
+ super(message);
+ }
+
+ public ResponseHandlerException(String message, Throwable cause)
+ {
+ super(message, cause);
+ }
+
+ public ResponseHandlerException(Throwable cause)
+ {
+ super(cause);
+ }
+}
Copied: trunk/core/src/main/org/jboss/portal/core/controller/handler/ResponseHandlerSelector.java (from rev 7048, trunk/core/src/main/org/jboss/portal/core/controller/ResponseHandlerSelector.java)
===================================================================
--- trunk/core/src/main/org/jboss/portal/core/controller/handler/ResponseHandlerSelector.java (rev 0)
+++ trunk/core/src/main/org/jboss/portal/core/controller/handler/ResponseHandlerSelector.java 2007-04-25 16:55:18 UTC (rev 7050)
@@ -0,0 +1,75 @@
+/******************************************************************************
+ * JBoss, a division of Red Hat *
+ * Copyright 2006, Red Hat Middleware, LLC, and individual *
+ * contributors as indicated by the @authors tag. See the *
+ * copyright.txt in the distribution for a full listing of *
+ * individual contributors. *
+ * *
+ * This is free software; you can redistribute it and/or modify it *
+ * under the terms of the GNU Lesser General Public License as *
+ * published by the Free Software Foundation; either version 2.1 of *
+ * the License, or (at your option) any later version. *
+ * *
+ * This software is distributed in the hope that it will be useful, *
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of *
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU *
+ * Lesser General Public License for more details. *
+ * *
+ * You should have received a copy of the GNU Lesser General Public *
+ * License along with this software; if not, write to the Free *
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA *
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org. *
+ ******************************************************************************/
+package org.jboss.portal.core.controller.handler;
+
+import org.jboss.portal.core.controller.handler.ResponseHandler;
+import org.jboss.portal.core.controller.handler.HandlerResponse;
+import org.jboss.portal.core.controller.ControllerContext;
+import org.jboss.portal.core.controller.ControllerCommand;
+import org.jboss.portal.core.controller.ControllerResponse;
+
+/**
+ * @author <a href="mailto:julien@jboss.org">Julien Viet</a>
+ * @version $Revision: 1.1 $
+ */
+public class ResponseHandlerSelector implements ResponseHandler
+{
+
+ /** . */
+ private ResponseHandler classicResponseHandler;
+
+ /** . */
+ private ResponseHandler ajaxResponseHandler;
+
+ public ResponseHandler getClassicResponseHandler()
+ {
+ return classicResponseHandler;
+ }
+
+ public void setClassicResponseHandler(ResponseHandler classicResponseHandler)
+ {
+ this.classicResponseHandler = classicResponseHandler;
+ }
+
+ public ResponseHandler getAjaxResponseHandler()
+ {
+ return ajaxResponseHandler;
+ }
+
+ public void setAjaxResponseHandler(ResponseHandler ajaxResponseHandler)
+ {
+ this.ajaxResponseHandler = ajaxResponseHandler;
+ }
+
+ public HandlerResponse processCommandResponse(ControllerContext controllerContext, ControllerCommand command, ControllerResponse response) throws ResponseHandlerException
+ {
+ if (ControllerContext.AJAX_TYPE == controllerContext.getType())
+ {
+ return ajaxResponseHandler.processCommandResponse(controllerContext, command, response);
+ }
+ else
+ {
+ return classicResponseHandler.processCommandResponse(controllerContext, command, response);
+ }
+ }
+}
Modified: trunk/core/src/main/org/jboss/portal/core/controller/portlet/PortletResponseHandler.java
===================================================================
--- trunk/core/src/main/org/jboss/portal/core/controller/portlet/PortletResponseHandler.java 2007-04-25 15:59:51 UTC (rev 7049)
+++ trunk/core/src/main/org/jboss/portal/core/controller/portlet/PortletResponseHandler.java 2007-04-25 16:55:18 UTC (rev 7050)
@@ -25,7 +25,7 @@
import org.jboss.portal.core.controller.ControllerCommand;
import org.jboss.portal.core.controller.ControllerContext;
import org.jboss.portal.core.controller.ControllerResponse;
-import org.jboss.portal.core.controller.ResponseHandlerException;
+import org.jboss.portal.core.controller.handler.ResponseHandlerException;
import org.jboss.portal.core.controller.handler.HTTPResponse;
import org.jboss.portal.core.controller.handler.CommandForward;
import org.jboss.portal.core.controller.handler.AbstractResponseHandler;
Modified: trunk/core/src/main/org/jboss/portal/core/model/instance/PortletInstanceResponseHandler.java
===================================================================
--- trunk/core/src/main/org/jboss/portal/core/model/instance/PortletInstanceResponseHandler.java 2007-04-25 15:59:51 UTC (rev 7049)
+++ trunk/core/src/main/org/jboss/portal/core/model/instance/PortletInstanceResponseHandler.java 2007-04-25 16:55:18 UTC (rev 7050)
@@ -29,10 +29,9 @@
import org.jboss.portal.core.controller.handler.HTTPResponse;
import org.jboss.portal.core.controller.ControllerException;
import org.jboss.portal.core.controller.ControllerResponse;
-import org.jboss.portal.core.controller.ResponseHandlerException;
+import org.jboss.portal.core.controller.handler.ResponseHandlerException;
import org.jboss.portal.core.model.instance.command.response.UpdatePortletInstanceResponse;
import org.jboss.portal.core.model.instance.command.render.RenderPortletInstanceCommand;
-import org.jboss.portal.server.ServerException;
import org.jboss.portal.server.ServerInvocationContext;
import org.jboss.portal.server.ServerInvocation;
import org.jboss.portal.web.ServletContextDispatcher;
Modified: trunk/core/src/main/org/jboss/portal/core/model/portal/PortalObjectResponseHandler.java
===================================================================
--- trunk/core/src/main/org/jboss/portal/core/model/portal/PortalObjectResponseHandler.java 2007-04-25 15:59:51 UTC (rev 7049)
+++ trunk/core/src/main/org/jboss/portal/core/model/portal/PortalObjectResponseHandler.java 2007-04-25 16:55:18 UTC (rev 7050)
@@ -30,7 +30,7 @@
import org.jboss.portal.core.controller.ControllerContext;
import org.jboss.portal.core.controller.ControllerException;
import org.jboss.portal.core.controller.ControllerResponse;
-import org.jboss.portal.core.controller.ResponseHandlerException;
+import org.jboss.portal.core.controller.handler.ResponseHandlerException;
import org.jboss.portal.core.model.portal.command.response.UpdatePageResponse;
import org.jboss.portal.core.model.portal.command.response.UpdateWindowResponse;
import org.jboss.portal.core.model.portal.command.view.ViewPageCommand;
Modified: trunk/core/src/resources/portal-core-sar/META-INF/jboss-service.xml
===================================================================
--- trunk/core/src/resources/portal-core-sar/META-INF/jboss-service.xml 2007-04-25 15:59:51 UTC (rev 7049)
+++ trunk/core/src/resources/portal-core-sar/META-INF/jboss-service.xml 2007-04-25 16:55:18 UTC (rev 7050)
@@ -944,7 +944,7 @@
<!-- The response handler selector -->
<mbean
- code="org.jboss.portal.core.controller.ResponseHandlerSelector"
+ code="org.jboss.portal.core.controller.handler.ResponseHandlerSelector"
name="portal:service=ResponseHandler,type=Selector"
xmbean-dd=""
xmbean-code="org.jboss.portal.jems.as.system.JBossServiceModelMBean">
17 years, 2 months
JBoss Portal SVN: r7049 - in trunk: core/src/main/org/jboss/portal/core and 1 other directory.
by portal-commits@lists.jboss.org
Author: julien(a)jboss.com
Date: 2007-04-25 11:59:51 -0400 (Wed, 25 Apr 2007)
New Revision: 7049
Removed:
trunk/core/src/main/org/jboss/portal/core/ns/
Modified:
trunk/api/src/main/org/jboss/portal/api/PortalRuntimeContext.java
Log:
minor cleanup
Modified: trunk/api/src/main/org/jboss/portal/api/PortalRuntimeContext.java
===================================================================
--- trunk/api/src/main/org/jboss/portal/api/PortalRuntimeContext.java 2007-04-25 15:57:31 UTC (rev 7048)
+++ trunk/api/src/main/org/jboss/portal/api/PortalRuntimeContext.java 2007-04-25 15:59:51 UTC (rev 7049)
@@ -23,7 +23,6 @@
package org.jboss.portal.api;
import org.jboss.portal.api.navstate.NavigationalStateContext;
-import org.jboss.portal.api.PortalSession;
/**
* The portal runtime context which provides access to runtime objects.
17 years, 2 months
JBoss Portal SVN: r7048 - in trunk/core/src/main/org/jboss/portal/core: controller/ajax and 8 other directories.
by portal-commits@lists.jboss.org
Author: julien(a)jboss.com
Date: 2007-04-25 11:57:31 -0400 (Wed, 25 Apr 2007)
New Revision: 7048
Added:
trunk/core/src/main/org/jboss/portal/core/navstate/
trunk/core/src/main/org/jboss/portal/core/navstate/NavigationalStateChange.java
trunk/core/src/main/org/jboss/portal/core/navstate/NavigationalStateContext.java
trunk/core/src/main/org/jboss/portal/core/navstate/NavigationalStateKey.java
trunk/core/src/main/org/jboss/portal/core/navstate/NavigationalStateObjectChange.java
Removed:
trunk/core/src/main/org/jboss/portal/core/ns/NavigationalStateChange.java
trunk/core/src/main/org/jboss/portal/core/ns/NavigationalStateContext.java
trunk/core/src/main/org/jboss/portal/core/ns/NavigationalStateKey.java
trunk/core/src/main/org/jboss/portal/core/ns/NavigationalStateObjectChange.java
Modified:
trunk/core/src/main/org/jboss/portal/core/controller/ajax/AjaxResponseHandler.java
trunk/core/src/main/org/jboss/portal/core/impl/api/CoreNavigationalStateContext.java
trunk/core/src/main/org/jboss/portal/core/impl/model/content/InternalContentProvider.java
trunk/core/src/main/org/jboss/portal/core/impl/model/content/generic/InternalGenericContentProvider.java
trunk/core/src/main/org/jboss/portal/core/model/portal/PortalObjectCommandFactory.java
trunk/core/src/main/org/jboss/portal/core/model/portal/command/action/InvokePortletWindowRenderCommand.java
trunk/core/src/main/org/jboss/portal/core/model/portal/ns/PortalObjectNavigationalStateContext.java
Log:
renamed o.j.p.core.ns to o.j.p.core.navstate
Modified: trunk/core/src/main/org/jboss/portal/core/controller/ajax/AjaxResponseHandler.java
===================================================================
--- trunk/core/src/main/org/jboss/portal/core/controller/ajax/AjaxResponseHandler.java 2007-04-25 15:56:22 UTC (rev 7047)
+++ trunk/core/src/main/org/jboss/portal/core/controller/ajax/AjaxResponseHandler.java 2007-04-25 15:57:31 UTC (rev 7048)
@@ -45,9 +45,9 @@
import org.jboss.portal.core.model.portal.PortalObjectContainer;
import org.jboss.portal.core.model.portal.ns.PortalObjectNavigationalStateContext;
import org.jboss.portal.core.model.portal.ns.WindowNavigationalState;
-import org.jboss.portal.core.ns.NavigationalStateChange;
-import org.jboss.portal.core.ns.NavigationalStateObjectChange;
-import org.jboss.portal.core.ns.NavigationalStateKey;
+import org.jboss.portal.core.navstate.NavigationalStateChange;
+import org.jboss.portal.core.navstate.NavigationalStateObjectChange;
+import org.jboss.portal.core.navstate.NavigationalStateKey;
import org.jboss.portal.core.theme.WindowRendition;
import org.jboss.portal.server.ServerInvocation;
import org.jboss.portal.portlet.invocation.response.PortletInvocationResponse;
Modified: trunk/core/src/main/org/jboss/portal/core/impl/api/CoreNavigationalStateContext.java
===================================================================
--- trunk/core/src/main/org/jboss/portal/core/impl/api/CoreNavigationalStateContext.java 2007-04-25 15:56:22 UTC (rev 7047)
+++ trunk/core/src/main/org/jboss/portal/core/impl/api/CoreNavigationalStateContext.java 2007-04-25 15:57:31 UTC (rev 7048)
@@ -23,7 +23,7 @@
package org.jboss.portal.core.impl.api;
import org.jboss.portal.api.navstate.NavigationalStateContext;
-import org.jboss.portal.core.ns.NavigationalStateKey;
+import org.jboss.portal.core.navstate.NavigationalStateKey;
import org.jboss.portal.core.model.portal.ns.WindowNavigationalState;
import org.jboss.portal.api.node.PortalNode;
import org.jboss.portal.Mode;
Modified: trunk/core/src/main/org/jboss/portal/core/impl/model/content/InternalContentProvider.java
===================================================================
--- trunk/core/src/main/org/jboss/portal/core/impl/model/content/InternalContentProvider.java 2007-04-25 15:56:22 UTC (rev 7047)
+++ trunk/core/src/main/org/jboss/portal/core/impl/model/content/InternalContentProvider.java 2007-04-25 15:57:31 UTC (rev 7048)
@@ -40,7 +40,7 @@
import org.jboss.portal.core.controller.ResourceAccessDeniedException;
import org.jboss.portal.core.controller.ControllerResponse;
import org.jboss.portal.core.controller.portlet.PortletInvocationFactory;
-import org.jboss.portal.core.ns.NavigationalStateKey;
+import org.jboss.portal.core.navstate.NavigationalStateKey;
import org.jboss.portal.core.theme.WindowRendition;
import org.jboss.portal.core.aspects.portlet.AjaxInterceptor;
import org.jboss.portal.server.config.ServerConfig;
Modified: trunk/core/src/main/org/jboss/portal/core/impl/model/content/generic/InternalGenericContentProvider.java
===================================================================
--- trunk/core/src/main/org/jboss/portal/core/impl/model/content/generic/InternalGenericContentProvider.java 2007-04-25 15:56:22 UTC (rev 7047)
+++ trunk/core/src/main/org/jboss/portal/core/impl/model/content/generic/InternalGenericContentProvider.java 2007-04-25 15:57:31 UTC (rev 7048)
@@ -36,7 +36,7 @@
import org.jboss.portal.core.controller.ControllerContext;
import org.jboss.portal.core.controller.ControllerResponse;
import org.jboss.portal.core.impl.model.content.InternalContentProvider;
-import org.jboss.portal.core.ns.NavigationalStateKey;
+import org.jboss.portal.core.navstate.NavigationalStateKey;
import org.jboss.portal.core.theme.WindowRendition;
import org.jboss.portal.portlet.PortletParametersStateString;
import org.jboss.portal.portlet.StateString;
Modified: trunk/core/src/main/org/jboss/portal/core/model/portal/PortalObjectCommandFactory.java
===================================================================
--- trunk/core/src/main/org/jboss/portal/core/model/portal/PortalObjectCommandFactory.java 2007-04-25 15:56:22 UTC (rev 7047)
+++ trunk/core/src/main/org/jboss/portal/core/model/portal/PortalObjectCommandFactory.java 2007-04-25 15:57:31 UTC (rev 7048)
@@ -33,7 +33,7 @@
import org.jboss.portal.core.model.portal.command.view.ViewPageCommand;
import org.jboss.portal.core.model.portal.ns.WindowNavigationalState;
import org.jboss.portal.core.controller.command.mapper.AbstractCommandFactory;
-import org.jboss.portal.core.ns.NavigationalStateKey;
+import org.jboss.portal.core.navstate.NavigationalStateKey;
import org.jboss.portal.portlet.impl.PortletRequestDecoder;
import org.jboss.portal.server.ServerInvocation;
import org.jboss.portal.server.servlet.PathMapping;
Modified: trunk/core/src/main/org/jboss/portal/core/model/portal/command/action/InvokePortletWindowRenderCommand.java
===================================================================
--- trunk/core/src/main/org/jboss/portal/core/model/portal/command/action/InvokePortletWindowRenderCommand.java 2007-04-25 15:56:22 UTC (rev 7047)
+++ trunk/core/src/main/org/jboss/portal/core/model/portal/command/action/InvokePortletWindowRenderCommand.java 2007-04-25 15:57:31 UTC (rev 7048)
@@ -33,7 +33,7 @@
import org.jboss.portal.core.model.portal.command.action.InvokeWindowCommand;
import org.jboss.portal.core.model.portal.PortalObjectId;
import org.jboss.portal.core.model.portal.ns.WindowNavigationalState;
-import org.jboss.portal.core.ns.NavigationalStateKey;
+import org.jboss.portal.core.navstate.NavigationalStateKey;
import org.jboss.portal.portlet.StateString;
/**
Modified: trunk/core/src/main/org/jboss/portal/core/model/portal/ns/PortalObjectNavigationalStateContext.java
===================================================================
--- trunk/core/src/main/org/jboss/portal/core/model/portal/ns/PortalObjectNavigationalStateContext.java 2007-04-25 15:56:22 UTC (rev 7047)
+++ trunk/core/src/main/org/jboss/portal/core/model/portal/ns/PortalObjectNavigationalStateContext.java 2007-04-25 15:57:31 UTC (rev 7048)
@@ -22,9 +22,9 @@
******************************************************************************/
package org.jboss.portal.core.model.portal.ns;
-import org.jboss.portal.core.ns.NavigationalStateContext;
-import org.jboss.portal.core.ns.NavigationalStateKey;
-import org.jboss.portal.core.ns.NavigationalStateObjectChange;
+import org.jboss.portal.core.navstate.NavigationalStateContext;
+import org.jboss.portal.core.navstate.NavigationalStateKey;
+import org.jboss.portal.core.navstate.NavigationalStateObjectChange;
import org.jboss.portal.common.invocation.AttributeResolver;
import org.jboss.portal.WindowState;
import org.jboss.portal.Mode;
Copied: trunk/core/src/main/org/jboss/portal/core/navstate/NavigationalStateChange.java (from rev 7046, trunk/core/src/main/org/jboss/portal/core/ns/NavigationalStateChange.java)
===================================================================
--- trunk/core/src/main/org/jboss/portal/core/navstate/NavigationalStateChange.java (rev 0)
+++ trunk/core/src/main/org/jboss/portal/core/navstate/NavigationalStateChange.java 2007-04-25 15:57:31 UTC (rev 7048)
@@ -0,0 +1,33 @@
+/******************************************************************************
+ * JBoss, a division of Red Hat *
+ * Copyright 2006, Red Hat Middleware, LLC, and individual *
+ * contributors as indicated by the @authors tag. See the *
+ * copyright.txt in the distribution for a full listing of *
+ * individual contributors. *
+ * *
+ * This is free software; you can redistribute it and/or modify it *
+ * under the terms of the GNU Lesser General Public License as *
+ * published by the Free Software Foundation; either version 2.1 of *
+ * the License, or (at your option) any later version. *
+ * *
+ * This software is distributed in the hope that it will be useful, *
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of *
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU *
+ * Lesser General Public License for more details. *
+ * *
+ * You should have received a copy of the GNU Lesser General Public *
+ * License along with this software; if not, write to the Free *
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA *
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org. *
+ ******************************************************************************/
+package org.jboss.portal.core.navstate;
+
+/**
+ * Base navigational state change.
+ *
+ * @author <a href="mailto:julien@jboss.org">Julien Viet</a>
+ * @version $Revision: 1.1 $
+ */
+public abstract class NavigationalStateChange
+{
+}
Copied: trunk/core/src/main/org/jboss/portal/core/navstate/NavigationalStateContext.java (from rev 7046, trunk/core/src/main/org/jboss/portal/core/ns/NavigationalStateContext.java)
===================================================================
--- trunk/core/src/main/org/jboss/portal/core/navstate/NavigationalStateContext.java (rev 0)
+++ trunk/core/src/main/org/jboss/portal/core/navstate/NavigationalStateContext.java 2007-04-25 15:57:31 UTC (rev 7048)
@@ -0,0 +1,33 @@
+/******************************************************************************
+ * JBoss, a division of Red Hat *
+ * Copyright 2006, Red Hat Middleware, LLC, and individual *
+ * contributors as indicated by the @authors tag. See the *
+ * copyright.txt in the distribution for a full listing of *
+ * individual contributors. *
+ * *
+ * This is free software; you can redistribute it and/or modify it *
+ * under the terms of the GNU Lesser General Public License as *
+ * published by the Free Software Foundation; either version 2.1 of *
+ * the License, or (at your option) any later version. *
+ * *
+ * This software is distributed in the hope that it will be useful, *
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of *
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU *
+ * Lesser General Public License for more details. *
+ * *
+ * You should have received a copy of the GNU Lesser General Public *
+ * License along with this software; if not, write to the Free *
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA *
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org. *
+ ******************************************************************************/
+package org.jboss.portal.core.navstate;
+
+import org.jboss.portal.common.invocation.AttributeResolver;
+
+/**
+ * @author <a href="mailto:julien@jboss.org">Julien Viet</a>
+ * @version $Revision: 1.1 $
+ */
+public interface NavigationalStateContext extends AttributeResolver
+{
+}
Copied: trunk/core/src/main/org/jboss/portal/core/navstate/NavigationalStateKey.java (from rev 7046, trunk/core/src/main/org/jboss/portal/core/ns/NavigationalStateKey.java)
===================================================================
--- trunk/core/src/main/org/jboss/portal/core/navstate/NavigationalStateKey.java (rev 0)
+++ trunk/core/src/main/org/jboss/portal/core/navstate/NavigationalStateKey.java 2007-04-25 15:57:31 UTC (rev 7048)
@@ -0,0 +1,96 @@
+/******************************************************************************
+ * JBoss, a division of Red Hat *
+ * Copyright 2006, Red Hat Middleware, LLC, and individual *
+ * contributors as indicated by the @authors tag. See the *
+ * copyright.txt in the distribution for a full listing of *
+ * individual contributors. *
+ * *
+ * This is free software; you can redistribute it and/or modify it *
+ * under the terms of the GNU Lesser General Public License as *
+ * published by the Free Software Foundation; either version 2.1 of *
+ * the License, or (at your option) any later version. *
+ * *
+ * This software is distributed in the hope that it will be useful, *
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of *
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU *
+ * Lesser General Public License for more details. *
+ * *
+ * You should have received a copy of the GNU Lesser General Public *
+ * License along with this software; if not, write to the Free *
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA *
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org. *
+ ******************************************************************************/
+package org.jboss.portal.core.navstate;
+
+import java.io.Serializable;
+import java.io.Externalizable;
+
+/**
+ * A key for navigational state.
+ *
+ * @author <a href="mailto:julien@jboss.org">Julien Viet</a>
+ * @version $Revision: 1.1 $
+ */
+public final class NavigationalStateKey implements Serializable
+{
+
+ /** The type. */
+ private final Class type;
+
+ /** The id. */
+ private final Object id;
+
+ /**
+ * Construct a new navigational state key.
+ *
+ * @param type the type of state
+ * @param id the id
+ * @throws IllegalArgumentException if any argument is null or the id argument does not implement either Serializable or Externalizable
+ */
+ public NavigationalStateKey(Class type, Object id)
+ {
+ if (type == null)
+ {
+ throw new IllegalArgumentException("No type provided");
+ }
+ if (id == null)
+ {
+ throw new IllegalArgumentException("No id provided");
+ }
+ if (id instanceof Serializable == false && id instanceof Externalizable == false)
+ {
+ throw new IllegalArgumentException("Id should implement Serializable or Externalizable");
+ }
+ this.type = type;
+ this.id = id;
+ }
+
+ public Class getType()
+ {
+ return type;
+ }
+
+ public Object getId()
+ {
+ return id;
+ }
+
+ public boolean equals(Object obj)
+ {
+ if (obj == this)
+ {
+ return true;
+ }
+ if (obj instanceof NavigationalStateKey)
+ {
+ NavigationalStateKey that = (NavigationalStateKey)obj;
+ return type.equals(that.type) && id.equals(that.id);
+ }
+ return false;
+ }
+
+ public int hashCode()
+ {
+ return type.hashCode() + id.hashCode();
+ }
+}
Copied: trunk/core/src/main/org/jboss/portal/core/navstate/NavigationalStateObjectChange.java (from rev 7046, trunk/core/src/main/org/jboss/portal/core/ns/NavigationalStateObjectChange.java)
===================================================================
--- trunk/core/src/main/org/jboss/portal/core/navstate/NavigationalStateObjectChange.java (rev 0)
+++ trunk/core/src/main/org/jboss/portal/core/navstate/NavigationalStateObjectChange.java 2007-04-25 15:57:31 UTC (rev 7048)
@@ -0,0 +1,115 @@
+/******************************************************************************
+ * JBoss, a division of Red Hat *
+ * Copyright 2006, Red Hat Middleware, LLC, and individual *
+ * contributors as indicated by the @authors tag. See the *
+ * copyright.txt in the distribution for a full listing of *
+ * individual contributors. *
+ * *
+ * This is free software; you can redistribute it and/or modify it *
+ * under the terms of the GNU Lesser General Public License as *
+ * published by the Free Software Foundation; either version 2.1 of *
+ * the License, or (at your option) any later version. *
+ * *
+ * This software is distributed in the hope that it will be useful, *
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of *
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU *
+ * Lesser General Public License for more details. *
+ * *
+ * You should have received a copy of the GNU Lesser General Public *
+ * License along with this software; if not, write to the Free *
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA *
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org. *
+ ******************************************************************************/
+package org.jboss.portal.core.navstate;
+
+/**
+ * The change of the navigational state of a single object. If both old and new values are not null, it denotes
+ * an update. Whenever the old value is null, a creation occured and conversely if the new value is null, a
+ * destruction occured.
+ *
+ * @author <a href="mailto:julien@jboss.org">Julien Viet</a>
+ * @version $Revision: 1.1 $
+ */
+public class NavigationalStateObjectChange extends NavigationalStateChange
+{
+
+ /** . */
+ public static final int UPDATE = 0;
+
+ /** . */
+ public static final int CREATE = 1;
+
+ /** . */
+ public static final int DESTROY = 2;
+
+ /** . */
+ private final Object oldValue;
+
+ /** . */
+ private final Object newValue;
+
+ /** . */
+ private NavigationalStateKey key;
+
+ private NavigationalStateObjectChange(NavigationalStateKey key, Object oldValue, Object newValue)
+ {
+ if (key == null)
+ {
+ throw new IllegalArgumentException("No key provided");
+ }
+ this.key = key;
+ this.oldValue = oldValue;
+ this.newValue = newValue;
+ }
+
+ public int getType()
+ {
+ return oldValue == null ? CREATE : (newValue == null ? DESTROY : UPDATE);
+ }
+
+ public NavigationalStateKey getKey()
+ {
+ return key;
+ }
+
+ public Object getOldValue()
+ {
+ return oldValue;
+ }
+
+ public Object getNewValue()
+ {
+ return newValue;
+ }
+
+ public static NavigationalStateObjectChange newUpdate(NavigationalStateKey key, Object oldValue, Object newValue)
+ {
+ if (oldValue == null)
+ {
+ throw new IllegalArgumentException("No old value provided");
+ }
+ if (newValue == null)
+ {
+ throw new IllegalArgumentException("No new value provided");
+ }
+ return new NavigationalStateObjectChange(key, oldValue, newValue);
+ }
+
+ public static NavigationalStateObjectChange newCreate(NavigationalStateKey key, Object newValue)
+ {
+ if (newValue == null)
+ {
+ throw new IllegalArgumentException("No new value provided");
+ }
+ return new NavigationalStateObjectChange(key, null, newValue);
+ }
+
+ public static NavigationalStateObjectChange newDestroy(NavigationalStateKey key, Object oldValue)
+ {
+ if (oldValue == null)
+ {
+ throw new IllegalArgumentException("No old value provided");
+ }
+ return new NavigationalStateObjectChange(key, oldValue, null);
+ }
+}
Deleted: trunk/core/src/main/org/jboss/portal/core/ns/NavigationalStateChange.java
===================================================================
--- trunk/core/src/main/org/jboss/portal/core/ns/NavigationalStateChange.java 2007-04-25 15:56:22 UTC (rev 7047)
+++ trunk/core/src/main/org/jboss/portal/core/ns/NavigationalStateChange.java 2007-04-25 15:57:31 UTC (rev 7048)
@@ -1,33 +0,0 @@
-/******************************************************************************
- * JBoss, a division of Red Hat *
- * Copyright 2006, Red Hat Middleware, LLC, and individual *
- * contributors as indicated by the @authors tag. See the *
- * copyright.txt in the distribution for a full listing of *
- * individual contributors. *
- * *
- * This is free software; you can redistribute it and/or modify it *
- * under the terms of the GNU Lesser General Public License as *
- * published by the Free Software Foundation; either version 2.1 of *
- * the License, or (at your option) any later version. *
- * *
- * This software is distributed in the hope that it will be useful, *
- * but WITHOUT ANY WARRANTY; without even the implied warranty of *
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU *
- * Lesser General Public License for more details. *
- * *
- * You should have received a copy of the GNU Lesser General Public *
- * License along with this software; if not, write to the Free *
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA *
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org. *
- ******************************************************************************/
-package org.jboss.portal.core.ns;
-
-/**
- * Base navigational state change.
- *
- * @author <a href="mailto:julien@jboss.org">Julien Viet</a>
- * @version $Revision: 1.1 $
- */
-public abstract class NavigationalStateChange
-{
-}
Deleted: trunk/core/src/main/org/jboss/portal/core/ns/NavigationalStateContext.java
===================================================================
--- trunk/core/src/main/org/jboss/portal/core/ns/NavigationalStateContext.java 2007-04-25 15:56:22 UTC (rev 7047)
+++ trunk/core/src/main/org/jboss/portal/core/ns/NavigationalStateContext.java 2007-04-25 15:57:31 UTC (rev 7048)
@@ -1,33 +0,0 @@
-/******************************************************************************
- * JBoss, a division of Red Hat *
- * Copyright 2006, Red Hat Middleware, LLC, and individual *
- * contributors as indicated by the @authors tag. See the *
- * copyright.txt in the distribution for a full listing of *
- * individual contributors. *
- * *
- * This is free software; you can redistribute it and/or modify it *
- * under the terms of the GNU Lesser General Public License as *
- * published by the Free Software Foundation; either version 2.1 of *
- * the License, or (at your option) any later version. *
- * *
- * This software is distributed in the hope that it will be useful, *
- * but WITHOUT ANY WARRANTY; without even the implied warranty of *
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU *
- * Lesser General Public License for more details. *
- * *
- * You should have received a copy of the GNU Lesser General Public *
- * License along with this software; if not, write to the Free *
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA *
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org. *
- ******************************************************************************/
-package org.jboss.portal.core.ns;
-
-import org.jboss.portal.common.invocation.AttributeResolver;
-
-/**
- * @author <a href="mailto:julien@jboss.org">Julien Viet</a>
- * @version $Revision: 1.1 $
- */
-public interface NavigationalStateContext extends AttributeResolver
-{
-}
Deleted: trunk/core/src/main/org/jboss/portal/core/ns/NavigationalStateKey.java
===================================================================
--- trunk/core/src/main/org/jboss/portal/core/ns/NavigationalStateKey.java 2007-04-25 15:56:22 UTC (rev 7047)
+++ trunk/core/src/main/org/jboss/portal/core/ns/NavigationalStateKey.java 2007-04-25 15:57:31 UTC (rev 7048)
@@ -1,96 +0,0 @@
-/******************************************************************************
- * JBoss, a division of Red Hat *
- * Copyright 2006, Red Hat Middleware, LLC, and individual *
- * contributors as indicated by the @authors tag. See the *
- * copyright.txt in the distribution for a full listing of *
- * individual contributors. *
- * *
- * This is free software; you can redistribute it and/or modify it *
- * under the terms of the GNU Lesser General Public License as *
- * published by the Free Software Foundation; either version 2.1 of *
- * the License, or (at your option) any later version. *
- * *
- * This software is distributed in the hope that it will be useful, *
- * but WITHOUT ANY WARRANTY; without even the implied warranty of *
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU *
- * Lesser General Public License for more details. *
- * *
- * You should have received a copy of the GNU Lesser General Public *
- * License along with this software; if not, write to the Free *
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA *
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org. *
- ******************************************************************************/
-package org.jboss.portal.core.ns;
-
-import java.io.Serializable;
-import java.io.Externalizable;
-
-/**
- * A key for navigational state.
- *
- * @author <a href="mailto:julien@jboss.org">Julien Viet</a>
- * @version $Revision: 1.1 $
- */
-public final class NavigationalStateKey implements Serializable
-{
-
- /** The type. */
- private final Class type;
-
- /** The id. */
- private final Object id;
-
- /**
- * Construct a new navigational state key.
- *
- * @param type the type of state
- * @param id the id
- * @throws IllegalArgumentException if any argument is null or the id argument does not implement either Serializable or Externalizable
- */
- public NavigationalStateKey(Class type, Object id)
- {
- if (type == null)
- {
- throw new IllegalArgumentException("No type provided");
- }
- if (id == null)
- {
- throw new IllegalArgumentException("No id provided");
- }
- if (id instanceof Serializable == false && id instanceof Externalizable == false)
- {
- throw new IllegalArgumentException("Id should implement Serializable or Externalizable");
- }
- this.type = type;
- this.id = id;
- }
-
- public Class getType()
- {
- return type;
- }
-
- public Object getId()
- {
- return id;
- }
-
- public boolean equals(Object obj)
- {
- if (obj == this)
- {
- return true;
- }
- if (obj instanceof NavigationalStateKey)
- {
- NavigationalStateKey that = (NavigationalStateKey)obj;
- return type.equals(that.type) && id.equals(that.id);
- }
- return false;
- }
-
- public int hashCode()
- {
- return type.hashCode() + id.hashCode();
- }
-}
Deleted: trunk/core/src/main/org/jboss/portal/core/ns/NavigationalStateObjectChange.java
===================================================================
--- trunk/core/src/main/org/jboss/portal/core/ns/NavigationalStateObjectChange.java 2007-04-25 15:56:22 UTC (rev 7047)
+++ trunk/core/src/main/org/jboss/portal/core/ns/NavigationalStateObjectChange.java 2007-04-25 15:57:31 UTC (rev 7048)
@@ -1,115 +0,0 @@
-/******************************************************************************
- * JBoss, a division of Red Hat *
- * Copyright 2006, Red Hat Middleware, LLC, and individual *
- * contributors as indicated by the @authors tag. See the *
- * copyright.txt in the distribution for a full listing of *
- * individual contributors. *
- * *
- * This is free software; you can redistribute it and/or modify it *
- * under the terms of the GNU Lesser General Public License as *
- * published by the Free Software Foundation; either version 2.1 of *
- * the License, or (at your option) any later version. *
- * *
- * This software is distributed in the hope that it will be useful, *
- * but WITHOUT ANY WARRANTY; without even the implied warranty of *
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU *
- * Lesser General Public License for more details. *
- * *
- * You should have received a copy of the GNU Lesser General Public *
- * License along with this software; if not, write to the Free *
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA *
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org. *
- ******************************************************************************/
-package org.jboss.portal.core.ns;
-
-/**
- * The change of the navigational state of a single object. If both old and new values are not null, it denotes
- * an update. Whenever the old value is null, a creation occured and conversely if the new value is null, a
- * destruction occured.
- *
- * @author <a href="mailto:julien@jboss.org">Julien Viet</a>
- * @version $Revision: 1.1 $
- */
-public class NavigationalStateObjectChange extends NavigationalStateChange
-{
-
- /** . */
- public static final int UPDATE = 0;
-
- /** . */
- public static final int CREATE = 1;
-
- /** . */
- public static final int DESTROY = 2;
-
- /** . */
- private final Object oldValue;
-
- /** . */
- private final Object newValue;
-
- /** . */
- private NavigationalStateKey key;
-
- private NavigationalStateObjectChange(NavigationalStateKey key, Object oldValue, Object newValue)
- {
- if (key == null)
- {
- throw new IllegalArgumentException("No key provided");
- }
- this.key = key;
- this.oldValue = oldValue;
- this.newValue = newValue;
- }
-
- public int getType()
- {
- return oldValue == null ? CREATE : (newValue == null ? DESTROY : UPDATE);
- }
-
- public NavigationalStateKey getKey()
- {
- return key;
- }
-
- public Object getOldValue()
- {
- return oldValue;
- }
-
- public Object getNewValue()
- {
- return newValue;
- }
-
- public static NavigationalStateObjectChange newUpdate(NavigationalStateKey key, Object oldValue, Object newValue)
- {
- if (oldValue == null)
- {
- throw new IllegalArgumentException("No old value provided");
- }
- if (newValue == null)
- {
- throw new IllegalArgumentException("No new value provided");
- }
- return new NavigationalStateObjectChange(key, oldValue, newValue);
- }
-
- public static NavigationalStateObjectChange newCreate(NavigationalStateKey key, Object newValue)
- {
- if (newValue == null)
- {
- throw new IllegalArgumentException("No new value provided");
- }
- return new NavigationalStateObjectChange(key, null, newValue);
- }
-
- public static NavigationalStateObjectChange newDestroy(NavigationalStateKey key, Object oldValue)
- {
- if (oldValue == null)
- {
- throw new IllegalArgumentException("No old value provided");
- }
- return new NavigationalStateObjectChange(key, oldValue, null);
- }
-}
17 years, 2 months