KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > eclipse > debug > internal > ui > viewers > provisional > IPresentationContext


1 /*******************************************************************************
2  * Copyright (c) 2005, 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 package org.eclipse.debug.internal.ui.viewers.provisional;
12
13 import org.eclipse.jface.util.IPropertyChangeListener;
14 import org.eclipse.ui.IWorkbenchPart;
15
16 /**
17  * Context in which an asynchronous request has been made.
18  * <p>
19  * Clients may implement and extend this interface to provide
20  * special contexts. Implementations must subclass {@link PresentationContext}.
21  * </p>
22  * @since 3.2
23  */

24 public interface IPresentationContext {
25     
26     /**
27      * Property name used for property change notification when the columns
28      * in a presentation context change.
29      */

30     public static final String JavaDoc PROPERTY_COLUMNS = "PROPERTY_COLUMNS"; //$NON-NLS-1$
31

32     /**
33      * Returns the part for which a request is being made
34      * or <code>null</code> if none.
35      *
36      * @return the part for which a request is being made
37      * or <code>null</code>
38      */

39     public IWorkbenchPart getPart();
40     
41     /**
42      * Returns identifiers of the visible columns in the order
43      * labels should be provided, or <code>null</code> if columns
44      * are not being displayed. Label providers use this
45      * information.
46      *
47      * @return visible column identifiers or <code>null</code>
48      * @see IColumnPresentation
49      */

50     public String JavaDoc[] getColumns();
51     
52     /**
53      * Registers the given listener for property change notification.
54      *
55      * @param listener property listener
56      */

57     public void addPropertyChangeListener(IPropertyChangeListener listener);
58     
59     /**
60      * Unregisters the given listener from property change notification.
61      *
62      * @param listener property listener.
63      */

64     public void removePropertyChangeListener(IPropertyChangeListener listener);
65     
66 }
67
Popular Tags