001: /*
002: * Copyright 2002 Sun Microsystems, Inc. All
003: * rights reserved. Use of this product is subject
004: * to license terms. Federal Acquisitions:
005: * Commercial Software -- Government Users
006: * Subject to Standard License Terms and
007: * Conditions.
008: *
009: * Sun, Sun Microsystems, the Sun logo, and Sun ONE
010: * are trademarks or registered trademarks of Sun Microsystems,
011: * Inc. in the United States and other countries.
012: */
013: package com.sun.portal.providers.containers.jsp.tab;
014:
015: import java.util.List;
016: import com.sun.portal.providers.ProviderException;
017:
018: /**
019: * <code>TabContainer</code> defines the interface for
020: * implementing a Tab Container provider.
021: *
022: * A TabContainerProvider must implement this interface.
023: *
024: * This interface contains methods to query information
025: * about a TabContainer and to set the properties
026: * of a TabContainer
027: *
028: *
029: */
030: public interface TabContainer {
031:
032: /**
033: * Gets the maximum number of tabs allowed on the user's desktop.
034: *
035: * @return the maximum number of tabs.
036: *
037: * @exception ProviderException If the maximum number cannot be
038: * returned.
039: */
040: public int getMaxTabs() throws ProviderException;
041:
042: /**
043: * Gets the List of selected tabs.
044: *
045: * @return The list of selected tabs, a list of UnmodifiableTabs.
046: *
047: * @exception ProviderException If the list of selected tabs cannot be
048: * returned.
049: *
050: * @see com.sun.portal.providers.containers.jsp.tab.UnmodifiableTab
051: */
052: public List getSelectedTabs() throws ProviderException;
053:
054: /**
055: * Gets the List of available tabs.
056: *
057: * @return The list of available tabs, a list of UnmodifiableTabs.
058: *
059: * @exception ProviderException If the list of available tabs cannot be
060: * returned.
061: *
062: * @see com.sun.portal.providers.containers.jsp.tab.UnmodifiableTab
063: */
064: public List getAvailableTabs() throws ProviderException;
065:
066: /**
067: * Gets the start tab, the tab to be displayed when the user logs in.
068: *
069: * @return The start tab, UnmodifiableTab.
070: *
071: * @exception ProviderException If the start tab cannot be
072: * returned.
073: *
074: * @see com.sun.portal.providers.containers.jsp.tab.UnmodifiableTab
075: */
076: public UnmodifiableTab getStartTab() throws ProviderException;
077:
078: /**
079: * Gets the start tab Name, the name of the tab to be displayed when the user logs in.
080: *
081: * @return The start tab name as a string.
082: *
083: * @exception ProviderException If the start tab name cannot be
084: * returned.
085: *
086: */
087: public String getStartTabName() throws ProviderException;
088:
089: /**
090: * Gets the make tab, the tab spec to be used for 'Make My Own tab' creation by the user .
091: *
092: * @return The make tab,UnmodifiableTab .
093: *
094: * @exception ProviderException If the make tab cannot be
095: * returned.
096: *
097: * @see com.sun.portal.providers.containers.jsp.tab.UnmodifiableTab
098: */
099: public UnmodifiableTab getMakeTab() throws ProviderException;
100:
101: /**
102: * Gets the make tab channel Name, the tab spec to be used for 'Make My Own tab' creation by the user .
103: *
104: * @return The make tab channel name as a string.
105: *
106: * @exception ProviderException If the make tab name cannot be
107: * returned.
108: */
109: public String getMakeTabName() throws ProviderException;
110:
111: /**
112: * Gets the make tab provider Name, the tab spec to be used for 'Make My Own tab' creation by the user .
113: *
114: * @return The make tab provider name as a string.
115: *
116: * @exception ProviderException If the make tab provider name cannot be
117: * returned.
118: *
119: */
120: public String getMakeTabProviderName() throws ProviderException;
121:
122: /**
123: * Gets the selected tab Name, the current selected tab in the user's session .
124: *
125: * @return The selected tab name as a string.
126: *
127: * @exception ProviderException If the selected tab name cannot be
128: * returned.
129: *
130: */
131: public String getSelectedTabName() throws ProviderException;
132:
133: /**
134: * Gets the selected tab, the current selected tab in the user's session .
135: *
136: * @return The selected tab, UnmodifiableTab.
137: *
138: * @exception ProviderException If the selected tab cannot be
139: * returned.
140: *
141: * @see com.sun.portal.providers.containers.jsp.tab.UnmodifiableTab
142: */
143: public UnmodifiableTab getSelectedTab() throws ProviderException;
144:
145: /**
146: * Gets a tab.
147: * This method returns an instance of the <code>UnmodifiableTab</code> for the named channel.
148: *
149: * @param name The name of the channel for which the tab Object is requested.
150: *
151: * @return The tab, UnmodifiableTab.
152: *
153: * @exception ProviderException If the tab cannot be
154: * returned.
155: *
156: * @see com.sun.portal.providers.containers.jsp.tab.UnmodifiableTab
157: */
158: public UnmodifiableTab getTab(String name) throws ProviderException;
159:
160: /**
161: * Sets a tab.
162: *
163: * @param b Tab that needs to be set.
164: *
165: * This method adds the ModifiableTab to the selected tabs list.
166: *
167: * @exception ProviderException If the tab cannot be set
168: *
169: * @see com.sun.portal.providers.containers.jsp.tab.UnmodifiableTab
170: * @see com.sun.portal.providers.containers.jsp.tab.ModifiableTab
171: */
172: public void setTab(ModifiableTab t) throws ProviderException;
173:
174: /**
175: * Sets a tab.
176: *
177: * @param b A <code>ModifiableTab</code> Tab that needs to be set.
178: * @param selected If true sets the tab to the current
179: * selected tab on the user's desktop.
180: *
181: * This method adds the ModifiableTab to the selected tabs list
182: *
183: * @exception ProviderException If the tab cannot be set
184: *
185: * @see com.sun.portal.providers.containers.jsp.tab.UnmodifiableTab
186: * @see com.sun.portal.providers.containers.jsp.tab.ModifiableTab
187: */
188: public void setTab(ModifiableTab t, boolean selected)
189: throws ProviderException;
190:
191: /**
192: * Sets the start tab Name, the name of the tab to be displayed when the user logs in.
193: *
194: * This method sets the current selected tab name in the user's session to the start tab.
195: *
196: * @exception ProviderException If the start tab name cannot be
197: * returned.
198: *
199: */
200: public void setStartTabName() throws ProviderException;
201:
202: /**
203: * Sets the start tab Name, the name of the tab to be displayed when the user logs in.
204: *
205: * @param t A <code>UnmodifiableTab</code> Whose tab name needs to be set as the start tab name.
206: *
207: * This method sets the start tab name to the name of UnmodifiableTab that was passed in.
208: *
209: * @exception ProviderException If the start tab name cannot be set
210: *
211: * @see com.sun.portal.providers.containers.jsp.tab.UnmodifiableTab
212: */
213: public void setStartTabName(UnmodifiableTab t)
214: throws ProviderException;
215:
216: /**
217: * Sets the start tab Name, the name of the tab to be displayed when the user logs in.
218: *
219: * @param name The name of the channel which needs to be set as the start tab.
220: * This method sets the start tab to the name passed in..
221: *
222: * @exception ProviderException If the start tab name cannot be set.
223: *
224: */
225: public void setStartTabName(String name) throws ProviderException;
226:
227: /**
228: * Sets the selected tab Name in the session.
229: *
230: * @param t A <code>ModifiableTab</code>.Whose tab name needs to be set as the selected tab name.
231: *
232: * This method sets the current selected tab name to the name of
233: * ModifiableTab that was passed in.
234: *
235: * @exception ProviderException If the start tab name cannot be set
236: *
237: * @see com.sun.portal.providers.containers.jsp.tab.ModifiableTab
238: */
239: public void setSelectedTab(ModifiableTab t)
240: throws ProviderException;
241:
242: /**
243: * Sets the selected tab Name in the session
244: *
245: * @param tabName The name of the channel which needs to be set as the selected tab.
246: *
247: * This method sets the current selected tab on the user's desktop
248: * to the name passed in..
249: *
250: * @exception ProviderException If the selected tab name cannot be set.
251: *
252: */
253: public void setSelectedTabName(String tabName)
254: throws ProviderException;
255:
256: }
|