站内搜索: 请输入搜索关键词
当前页面: 在线文档首页 > NetBeans API Javadoc 5.0.0

NodeModel (NetBeans View Model) - NetBeans API Javadoc 5.0.0

 

org.netbeans.spi.viewmodel
Interface NodeModel

All Superinterfaces:
Model
All Known Implementing Classes:
Models.CompoundModel

public interface NodeModel
extends Model

Provides display name, icon and tooltip value for some type of objects. Designed to be used with TreeModel.


Method Summary
 void addModelListener(ModelListener l)
          Registers given listener.
 String getDisplayName(Object node)
          Returns display name for given node.
 String getIconBase(Object node)
          Returns icon for given node.
 String getShortDescription(Object node)
          Returns tooltip for given node.
 void removeModelListener(ModelListener l)
          Unregisters given listener.
 

Method Detail

getDisplayName

public String getDisplayName(Object node)
                      throws UnknownTypeException
Returns display name for given node.

Returns:
display name for given node
Throws:
UnknownTypeException

getIconBase

public String getIconBase(Object node)
                   throws UnknownTypeException
Returns icon for given node.

Returns:
icon for given node
Throws:
UnknownTypeException - if this NodeModel implementation is not able to resolve icon for given node type

getShortDescription

public String getShortDescription(Object node)
                           throws UnknownTypeException
Returns tooltip for given node.

Returns:
tooltip for given node
Throws:
UnknownTypeException - if this NodeModel implementation is not able to resolve tooltip for given node type

addModelListener

public void addModelListener(ModelListener l)
Registers given listener.

Parameters:
l - the listener to add

removeModelListener

public void removeModelListener(ModelListener l)
Unregisters given listener.

Parameters:
l - the listener to remove

 

Built on May 3 2007.  |  Portions Copyright 1997-2005 Sun Microsystems, Inc. All rights reserved.