public abstract class SelectionContextProvider extends Object implements org.eclipse.help.IContextProvider
Constructor and Description |
---|
SelectionContextProvider(org.eclipse.jface.viewers.ISelectionProvider selectionProvider,
String defaultContextId)
Create a context provider
|
Modifier and Type | Method and Description |
---|---|
org.eclipse.help.IContext |
getContext(Object target) |
int |
getContextChangeMask() |
protected abstract String |
getContextId(Object object)
Get the context ID for the given selected object.
|
String |
getSearchExpression(Object target) |
protected org.eclipse.help.IContext |
getSelectionContext(Object object)
Get the context for the given selected object.
|
public SelectionContextProvider(org.eclipse.jface.viewers.ISelectionProvider selectionProvider, String defaultContextId)
selectionProvider
- the selection provider to use to retrieve the
selectiondefaultContextId
- the ID of the default context that is
supplemented with the selection contexts, may be
null
public int getContextChangeMask()
getContextChangeMask
in interface org.eclipse.help.IContextProvider
IContextProvider.getContextChangeMask()
public org.eclipse.help.IContext getContext(Object target)
getContext
in interface org.eclipse.help.IContextProvider
IContextProvider.getContext(Object)
protected org.eclipse.help.IContext getSelectionContext(Object object)
object
- the selected objectnull
protected abstract String getContextId(Object object)
object
- the selected objectnull
if none is availableBuild 2013-10-07_11-27-38
Revision 99b27713a799a59a21b0b166eaaea8aaefbf125a