Package org.eclipse.handly.ui.search
Class AbstractSearchTreeContentProvider
java.lang.Object
org.eclipse.handly.ui.search.AbstractSearchTreeContentProvider
- All Implemented Interfaces:
ISearchContentProvider,org.eclipse.jface.viewers.IContentProvider,org.eclipse.jface.viewers.IStructuredContentProvider,org.eclipse.jface.viewers.ITreeContentProvider
public abstract class AbstractSearchTreeContentProvider
extends Object
implements org.eclipse.jface.viewers.ITreeContentProvider
A partial implementation of
ISearchContentProvider
for the tree viewer. Subclasses need to implement ITreeContentProvider.getParent(Object) to complete the implementation.-
Constructor Summary
ConstructorsConstructorDescriptionCreates a new content provider for the given search result page. -
Method Summary
Modifier and TypeMethodDescriptionvoidclear()Notifies that all elements have been removed from the displayed search result.voidelementsChanged(Object[] elements) Notifies that the set of matches for the given elements has changed.Object[]getChildren(Object parentElement) Object[]getElements(Object inputElement) protected AbstractSearchResultPagegetPage()Returns the search result page passed into the constructor.booleanhasChildren(Object element) voidinputChanged(org.eclipse.jface.viewers.Viewer viewer, Object oldInput, Object newInput) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.eclipse.jface.viewers.IContentProvider
disposeMethods inherited from interface org.eclipse.jface.viewers.ITreeContentProvider
getParent
-
Constructor Details
-
AbstractSearchTreeContentProvider
Creates a new content provider for the given search result page.- Parameters:
page- notnull
-
-
Method Details
-
inputChanged
- Specified by:
inputChangedin interfaceorg.eclipse.jface.viewers.IContentProvider
-
getElements
- Specified by:
getElementsin interfaceorg.eclipse.jface.viewers.IStructuredContentProvider- Specified by:
getElementsin interfaceorg.eclipse.jface.viewers.ITreeContentProvider
-
getChildren
- Specified by:
getChildrenin interfaceorg.eclipse.jface.viewers.ITreeContentProvider
-
hasChildren
- Specified by:
hasChildrenin interfaceorg.eclipse.jface.viewers.ITreeContentProvider
-
elementsChanged
Description copied from interface:ISearchContentProviderNotifies that the set of matches for the given elements has changed.This method is guaranteed to be called in the UI thread. Note that this notification is asynchronous, i.e., further changes may have occurred by the time this method is called. They will be described in a future call.
- Specified by:
elementsChangedin interfaceISearchContentProvider- Parameters:
elements- nevernull
-
clear
public void clear()Description copied from interface:ISearchContentProviderNotifies that all elements have been removed from the displayed search result.This method is guaranteed to be called in the UI thread. Note that this notification is asynchronous, i.e., further changes may have occurred by the time this method is called. They will be described in a future call.
- Specified by:
clearin interfaceISearchContentProvider
-
getPage
Returns the search result page passed into the constructor.- Returns:
- the search result page (never
null)
-