// selected device to itself or a descendent of itself.
// We can do this by wrapping the hierarchy content provider
// in a FilteringTreeContentProvider that filters out the
// selected device.
ITreeContentProvider filteringContentProvider =
new FilteringTreeContentProvider(
CONTENT_PROVIDER,
new FilteringTreeContentProvider.NodeFilter() {
// To store the filtered nodes
List filtered = new ArrayList();