KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > eclipse > help > internal > base > IHelpActivitySupport


1 /*******************************************************************************
2  * Copyright (c) 2000, 2006 IBM Corporation and others.
3  * All rights reserved. This program and the accompanying materials
4  * are made available under the terms of the Eclipse Public License v1.0
5  * which accompanies this distribution, and is available at
6  * http://www.eclipse.org/legal/epl-v10.html
7  *
8  * Contributors:
9  * IBM Corporation - initial API and implementation
10  *******************************************************************************/

11
12 package org.eclipse.help.internal.base;
13
14 /**
15  * @since 3.0
16  */

17 public interface IHelpActivitySupport {
18
19     /**
20      * Checks if href matches an enabled activity. If it does not match any
21      * defined activites, it is assumed to be enabled. If Help role filtering is
22      * disabled, this method always returns <code>true</code>.
23      *
24      * @param href
25      * @return
26      */

27     public boolean isEnabled(String JavaDoc href);
28
29     /**
30      * Checks if href is matches an enabled activity. If it does not match any
31      * defined activites, it is assumed to be enabled.
32      *
33      * @param href
34      * the topic href
35      * @return <code>true</code> if role for this href is enabled,
36      * <code>false</code> otherwise.
37      */

38     public boolean isRoleEnabled(String JavaDoc href);
39
40     /**
41      * Checks whether topic belongs to a TOC that mathes enabled activity.
42      * Enabled children TOCs are searched if linked by also enabled TOCs.
43      * Additionally topic may match description topic of a root TOC.
44      *
45      * @return true if topic belongs to an enabled TOC
46      * @param href
47      * @param locale
48      * locale for which TOCs are checked
49      */

50     public boolean isEnabledTopic(String JavaDoc href, String JavaDoc locale);
51
52     /**
53      * Enables activities with patterns matching the href
54      *
55      * @param href
56      */

57     public void enableActivities(String JavaDoc href);
58
59     public boolean isFilteringEnabled();
60
61     public void setFilteringEnabled(boolean enabled);
62
63     public boolean isUserCanToggleFiltering();
64
65     /**
66      * Returns the message to show in the warning dialog when filtering is
67      * toggled off.
68      *
69      * @return the message for the filtering warning dialog
70      */

71     public String JavaDoc getShowAllMessage();
72
73     /**
74      * Returns document message for disabled activities.
75      *
76      * @param embedded
77      * if <code>true</code>, the message will be added to a
78      * document in the workbench window. Otherwise, it will be shown
79      * in a separate Help window.
80      * @return the document message with Java script string substituted if
81      * found.
82      */

83     public String JavaDoc getDocumentMessage(boolean embedded);
84
85     /**
86      * Returns the label for the checkbox in the local scope page
87      * that allows search hits from disabled activities to be shown.
88      * @return the checkbox label
89      */

90     public String JavaDoc getLocalScopeCheckboxLabel();
91
92     /**
93      * @param embedded
94      * if <code>true</code>, the message will be added to a
95      * document in the workbench window. Otherwise, it will be shown
96      * in a separate Help window.
97      * @return <code>true</code> if the document message uses live help and
98      * requires live help Java script header, or <code>false</code>
99      * otherwise.
100      */

101     public boolean getDocumentMessageUsesLiveHelp(boolean embedded);
102 }
103
Popular Tags