blob: 2dbfdfbdd99684ecba46bab00bf58c83c7d869c7 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
|
/*******************************************************************************
* Copyright (c) 2006, 2007 IBM Corporation and others.
* All rights reserved. This program and the accompanying materials
* are made available under the terms of the Eclipse Public License v1.0
* which accompanies this distribution, and is available at
* http://www.eclipse.org/legal/epl-v10.html
*
* Contributors:
* IBM Corporation - initial API and implementation
*******************************************************************************/
package org.eclipse.debug.ui;
import java.util.Set;
import org.eclipse.jface.viewers.IStructuredSelection;
/**
* A detail pane factory creates one or more types of detail panes.
* <p>
* Detail pane factories are contributed via the <code>org.eclipse.debug.ui.detailPaneFactories</code>
* extension point. Following is an example of a detail pane factory extension:
* <pre>
* <extension point="org.eclipse.debug.ui.detailPaneFactories">
* <detailFactories
* class="org.eclipse.temp.TableDetailPaneFactory"
* name="Table Detail Factory">
* </detailFactories>
* </extension>
* </pre>
* </p>
* <p>
* <p>
* Clients contributing a detail pane factory are intended to implement this interface.
* @see IDetailPane
* @since 3.3
*
*/
public interface IDetailPaneFactory {
/**
* Returns all possible types detail panes that this factory can
* create for the given selection, possibly empty. Detail panes are returned
* as a set of detail pane identifiers.
*
* @param selection The current selection
* @return Set of String IDs for possible detail pane types, possibly empty
*/
public Set getDetailPaneTypes(IStructuredSelection selection);
/**
* Returns the identifier of the default detail pane type to use for the given
* selection, or <code>null</code> if this factory has no preference.
* A factory can override the platform's default detail pane by returning
* a non-<code>null</code> value.
*
* @param selection The current selection
* @return a detail pane type identifier or <code>null</code>
*/
public String getDefaultDetailPane(IStructuredSelection selection);
/**
* Creates and returns a detail pane corresponding to the given detail pane
* type identifier that this factory can produce (according to
* <code>getDetailPaneTypes(IStructuredSelection selection)</code>).
*
* @param paneID The id of the detain pane type to be created
* @return detail pane or <code>null</code> if one could not be created
*/
public IDetailPane createDetailPane(String paneID);
/**
* Returns a name for the detail pane type associated with the given ID
* or <code>null</code> if none. Used to
* populate the context menu with meaningful names of the pane types.
*
* @param paneID detail pane type identifier
* @return detail pane name or <code>null</code> if none
*/
public String getDetailPaneName(String paneID);
/**
* Returns a description for the detail pane type associated with the given ID
* or <code>null</code> if none.
*
* @param paneID detail pane type identifier
* @return detail pane description or <code>null</code> if none
*/
public String getDetailPaneDescription(String paneID);
}
|