01: /* Copyright 2002 The JA-SIG Collaborative. All rights reserved.
02: * See license distributed with this file and
03: * available online at http://www.uportal.org/license.html
04: */
05:
06: package org.jasig.portal.layout.alm;
07:
08: import java.util.Set;
09: import org.jasig.portal.PortalException;
10: import org.jasig.portal.layout.IUserLayout;
11:
12: /**
13: * An aggregated-layout specific extension of the user layout interface
14: *
15: * Prior to uPortal 2.5, this class existed in the package org.jasig.portal.layout.
16: * It was moved to its present package to reflect that it is part of Aggregated
17: * Layouts.
18: *
19: * @author <a href="mailto:mvi@immagic.com">Michael Ivanov</a>
20: * @version 1.1 $Revision: 35724 $ $Date: 2005-05-03 13:40:47 -0700 (Tue, 03 May 2005) $
21: */
22: public interface IAggregatedLayout extends IUserLayout {
23:
24: // the tag names constants
25: public static final String LAYOUT = "layout";
26: public static final String FRAGMENT = "fragment";
27: public static final String FOLDER = "folder";
28: public static final String CHANNEL = "channel";
29: public static final String PARAMETER = "parameter";
30: public static final String RESTRICTION = "restriction";
31: // The names for marking nodes
32: public static final String ADD_TARGET = "add_target";
33: public static final String MOVE_TARGET = "move_target";
34:
35: /**
36: * Returns a list of fragment Ids existing in the layout.
37: *
38: * @return a <code>Set</code> of <code>String</code> fragment Ids.
39: * @exception PortalException if an error occurs
40: */
41: public Set getFragmentIds() throws PortalException;
42:
43: /**
44: * Returns an fragment Id for a given node.
45: * Returns null if the node is not part of any fragments.
46: *
47: * @param nodeId a <code>String</code> value
48: * @return a <code>String</code> fragment Id
49: * @exception PortalException if an error occurs
50: */
51: public String getFragmentId(String nodeId) throws PortalException;
52:
53: /**
54: * Returns an fragment root Id for a given fragment.
55: *
56: * @param fragmentId a <code>String</code> value
57: * @return a <code>String</code> fragment root Id
58: * @exception PortalException if an error occurs
59: */
60: public String getFragmentRootId(String fragmentId)
61: throws PortalException;
62:
63: /**
64: * Returns the node by a given node ID.
65: *
66: * @param nodeId a <code>String</code> value
67: * @return a <code>ALNode</code> instance
68: */
69: public ALNode getLayoutNode(String nodeId);
70:
71: /**
72: * Returns the folder by a given folder ID.
73: *
74: * @param folderId a <code>String</code> value
75: * @return a <code>ALFolder</code> instance
76: */
77: public ALFolder getLayoutFolder(String folderId);
78:
79: /**
80: * Gets the tree depth for a given node
81: * @param nodeId a <code>String</code> node ID
82: * @return a depth value
83: * @exception PortalException if an error occurs
84: */
85: public int getDepth(String nodeId) throws PortalException;
86:
87: }
|