01: /*******************************************************************************
02: * Copyright (c) 2005, 2006 IBM Corporation and others.
03: * All rights reserved. This program and the accompanying materials
04: * are made available under the terms of the Eclipse Public License v1.0
05: * which accompanies this distribution, and is available at
06: * http://www.eclipse.org/legal/epl-v10.html
07: *
08: * Contributors:
09: * IBM Corporation - initial API and implementation
10: *******************************************************************************/package org.eclipse.ui.navigator;
11:
12: import org.eclipse.core.runtime.IAdaptable;
13: import org.eclipse.jface.viewers.ILabelProvider;
14: import org.eclipse.jface.viewers.ITreeContentProvider;
15:
16: /**
17: * The content extension represents the components of a <b>navigatorContent</b>
18: * extension. These handles are managed by a content service
19: * {@link INavigatorContentService}.
20: *
21: * <p>
22: * There is one {@link INavigatorContentExtension} for each content service.
23: * There is only one {@link INavigatorContentDescriptor} for each extension.
24: * </p>
25: *
26: *
27: *<p>
28: * This interface is not intended to be implemented by clients.
29: *</p>
30: * @since 3.2
31: *
32: */
33: public interface INavigatorContentExtension extends IAdaptable {
34:
35: /**
36: *
37: * @return The id attribute of the navigatorContent extension.
38: */
39: String getId();
40:
41: /**
42: * There is one descriptor for all instances of a
43: * INavigatorContentExtension.
44: *
45: *
46: * @return A handle to the descriptor used to manage this extension.
47: */
48: INavigatorContentDescriptor getDescriptor();
49:
50: /**
51: * Clients may choose to implement {@link ICommonContentProvider}, but are
52: * only required to supply an implementation of {@link ITreeContentProvider}.
53: *
54: * @return The content provider defined by the <b>navigatorContent</b>
55: * extension.
56: * @see ICommonContentProvider
57: * @see ITreeContentProvider
58: */
59: ITreeContentProvider getContentProvider();
60:
61: /**
62: * The real underlying implementation may only support the
63: * {@link ILabelProvider} interface, but a simple delegate is used when this
64: * is the case to ensure that clients may anticpate an
65: * {@link ICommonLabelProvider} interface.
66: *
67: * @return The content provider defined by the <b>navigatorContent</b>
68: * extension.
69: * @see ICommonLabelProvider
70: * @see ILabelProvider
71: */
72: ICommonLabelProvider getLabelProvider();
73:
74: /**
75: *
76: * @return True if any class has been instantiated by this extension.
77: */
78: boolean isLoaded();
79:
80: /**
81: *
82: * @return The state model associated with this content extension.
83: * @see IExtensionStateModel
84: */
85: IExtensionStateModel getStateModel();
86:
87: }
|