01: /******************************************************************************
02: * JBoss, a division of Red Hat *
03: * Copyright 2006, Red Hat Middleware, LLC, and individual *
04: * contributors as indicated by the @authors tag. See the *
05: * copyright.txt in the distribution for a full listing of *
06: * individual contributors. *
07: * *
08: * This is free software; you can redistribute it and/or modify it *
09: * under the terms of the GNU Lesser General Public License as *
10: * published by the Free Software Foundation; either version 2.1 of *
11: * the License, or (at your option) any later version. *
12: * *
13: * This software is distributed in the hope that it will be useful, *
14: * but WITHOUT ANY WARRANTY; without even the implied warranty of *
15: * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU *
16: * Lesser General Public License for more details. *
17: * *
18: * You should have received a copy of the GNU Lesser General Public *
19: * License along with this software; if not, write to the Free *
20: * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA *
21: * 02110-1301 USA, or see the FSF site: http://www.fsf.org. *
22: ******************************************************************************/package org.jboss.portal.api.navstate;
23:
24: import org.jboss.portal.Mode;
25: import org.jboss.portal.WindowState;
26: import org.jboss.portal.api.node.PortalNode;
27:
28: /**
29: * Provide access to a portion of the navigational state managed by the portal.
30: *
31: * @author <a href="mailto:julien@jboss.org">Julien Viet</a>
32: * @version $Revision: 8785 $
33: */
34: public interface NavigationalStateContext {
35: /**
36: * Returns the window state of a window or null if it is not found.
37: *
38: * @param window the window from which the window state is returned
39: * @return the window state
40: * @throws IllegalArgumentException
41: */
42: WindowState getWindowState(PortalNode window)
43: throws IllegalArgumentException;
44:
45: /**
46: * Updates the window state of a window.
47: *
48: * @param window the window to update
49: * @param windowState the new window state value
50: * @throws IllegalArgumentException
51: */
52: void setWindowState(PortalNode window, WindowState windowState)
53: throws IllegalArgumentException;
54:
55: /**
56: * Returns the mode of a window or null if it is not found.
57: *
58: * @param window the window from which the mode is returned
59: * @return the mode
60: * @throws IllegalArgumentException
61: */
62: Mode getMode(PortalNode window) throws IllegalArgumentException;
63:
64: /**
65: * Updates the mode of a window.
66: *
67: * @param window the window to update
68: * @param mode the new mode value
69: * @throws IllegalArgumentException
70: */
71: void setMode(PortalNode window, Mode mode)
72: throws IllegalArgumentException;
73: }
|