(incubating) | The Free and Open Productivity Suite

Developer's Guide

API

SDK

Tips 'n' Tricks

Miscellaneous

Content for OpenOffice.org version 3.3.

:: com :: sun :: star :: awt :: tree ::

unpublished interface XTreeDataModel
Base Interfaces
XTreeDataModel
┗ ::com::sun::star::lang::XComponent

::com::sun::star::lang::XComponent
(referenced interface's summary:)
allows to exclicitly free resources and break cyclic references.
Usage Restrictions
not published
Description
An instance of this interface is used by the TreeControl to retrieve the hierarchical outline data that is displayed in the actual control.

If you implement your own XTreeDataModel you need to notify registered XTreeDataModelListener if your model changes after the control is created. If this is not done correctly the TreeControl will not update the data properly.

If you do not need your own model implementation, you can also use the MutableTreeDataModel.

Methods' Summary
getRoot Returns the root of the tree.  
addTreeDataModelListener Adds a listener for the TreeDataModelEvent posted after the tree changes.  
removeTreeDataModelListener Removes a listener previously added with addTreeDataModelListener().  
Methods' Details
getRoot
XTreeNode
getRoot();

Description
Returns the root of the tree.

Returns null only if the tree has no nodes.

Returns
the root of the tree
addTreeDataModelListener
void
addTreeDataModelListener( [in] XTreeDataModelListener  Listener );

Description
Adds a listener for the TreeDataModelEvent posted after the tree changes.
Parameter Listener
the listener to add.
removeTreeDataModelListener
void
removeTreeDataModelListener( [in] XTreeDataModelListener  Listener );

Description
Removes a listener previously added with addTreeDataModelListener().
Parameter Listener
the listener to remove.
Top of Page

Apache OpenOffice is an effort undergoing incubation at The Apache Software Foundation (ASF), sponsored by the Apache Incubator. Incubation is required of all newly accepted projects until a further review indicates that the infrastructure, communications, and decision making process have stabilized in a manner consistent with other successful ASF projects. While incubation status is not necessarily a reflection of the completeness or stability of the code, it does indicate that the project has yet to be fully endorsed by the ASF.

Copyright & License
Apache and the Apache feather logos are trademarks of The Apache Software Foundation. OpenOffice.org and the seagull logo are registered trademarks of The Apache Software Foundation. Other names appearing on the site may be trademarks of their respective owners.