Follow Techotopia on Twitter

On-line Guides
All Guides
eBook Store
iOS / Android
Linux for Beginners
Office Productivity
Linux Installation
Linux Security
Linux Utilities
Linux Virtualization
Linux Kernel
System/Network Admin
Programming
Scripting Languages
Development Tools
Web Development
GUI Toolkits/Desktop
Databases
Mail Systems
openSolaris
Eclipse Documentation
Techotopia.com
Virtuatopia.com

How To Guides
Virtualization
General System Admin
Linux Security
Linux Filesystems
Web Servers
Graphics & Desktop
PC Hardware
Windows
Problem Solutions
Privacy Policy

  




 

 


Eclipse Platform
Release 3.5

org.eclipse.jface.databinding.viewers
Class TreeStructureAdvisor

java.lang.Object
  extended by 
org.eclipse.jface.databinding.viewers.TreeStructureAdvisor

public abstract class TreeStructureAdvisor
extends Object

Instances of this class can be used to improve accuracy and performance of an ObservableListTreeContentProvider or an ObservableSetTreeContentProvider. This class is intended to be subclassed by clients.

Since:
1.2

Constructor Summary
TreeStructureAdvisor ()
           
 
Method Summary
  Object getParent ( Object element)
          Returns the parent for the given element, or null indicating that the parent can't be computed.
  Boolean hasChildren ( Object element)
          Returns whether the given element has children, or null if the actual children collection should be consulted.
 
Methods inherited from class java.lang. Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TreeStructureAdvisor

public TreeStructureAdvisor()
Method Detail

getParent

public 
Object getParent(
Object element)
Returns the parent for the given element, or null indicating that the parent can't be computed. In this case the tree-structured viewer can't expand a given node correctly if requested. The default implementation returns null; clients should override.

Parameters:
element - the element
Returns:
the parent element, or null if it has none or if the parent cannot be computed

hasChildren

public 
Boolean hasChildren(
Object element)
Returns whether the given element has children, or null if the actual children collection should be consulted. The default implementation returns null; clients should override.

Intended as an optimization for when the viewer does not need the actual children. Clients may be able to implement this more efficiently than getChildren.

Parameters:
element - the element
Returns:
Boolean.TRUE if the given element has children, Boolean.FALSE if the given element never has children, or null if the children collection should be consulted.

Eclipse Platform
Release 3.5

Guidelines for using Eclipse APIs.

Copyright (c) Eclipse contributors and others 2000, 2008. All rights reserved.


 
 
  Published under the terms of the Eclipse Public License Version 1.0 ("EPL") Design by Interspire