com.sdm.quasar.client.swing.systeminfo
Class InfoTreeNodeDefinition

java.lang.Object
  extended bycom.sdm.quasar.client.swing.systeminfo.InfoTreeNodeDefinition
Direct Known Subclasses:
DialogInfoTreeNodeDefinition, FeatureTreeNodeDefinition

public class InfoTreeNodeDefinition
extends java.lang.Object

Version:
1.$Revision$
Author:
Thomas Wolf

Constructor Summary
InfoTreeNodeDefinition(ResourceAccessService resourceAccessService, ImageProviderService imageProviderService)
          Creates a new InfoTreeNodeDefinition.
 
Method Summary
 NodeInfo[] createChildNodeInfos(SystemInfoNode node, InfoTreeModel model)
           
 NodeInfo createNodeInfo(SystemInfoNode node, InfoTreeModel model)
           
 javax.swing.ImageIcon getImageIcon(java.lang.String id)
          Returns the ImageIcon associated with the given id.
 ImageProviderService getImageProviderService()
          Returns the ImageProviderService.
protected  java.lang.String getNodeText(SystemInfoNode node)
           
protected  SystemInfoNode getOriginal(SystemInfoNode node, InfoTreeModel model)
           
 ResourceAccessService getResourceAccessService()
          Returns the ResourceAccessService.
protected  java.lang.String getResourcePrefix()
          Returns the resource prefix for this definition.
 java.lang.String translate(java.lang.String original)
          Translates the given original text to get translated by a resource entry.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

InfoTreeNodeDefinition

public InfoTreeNodeDefinition(ResourceAccessService resourceAccessService,
                              ImageProviderService imageProviderService)
Creates a new InfoTreeNodeDefinition.

Parameters:
resourceAccessService - a ResourceAccessService to access resources
imageProviderService - a ImageProviderService to access images
Method Detail

getResourceAccessService

public ResourceAccessService getResourceAccessService()
Returns the ResourceAccessService.


getImageProviderService

public ImageProviderService getImageProviderService()
Returns the ImageProviderService.


getResourcePrefix

protected java.lang.String getResourcePrefix()
Returns the resource prefix for this definition.


translate

public java.lang.String translate(java.lang.String original)
Translates the given original text to get translated by a resource entry.

Parameters:
original - the orginal key text
Returns:
the translated value - if any, otherwise the original text

getImageIcon

public javax.swing.ImageIcon getImageIcon(java.lang.String id)
Returns the ImageIcon associated with the given id.

Parameters:
id - the id of the image
Returns:
the ImageIcon or null, if no icon was found

getOriginal

protected final SystemInfoNode getOriginal(SystemInfoNode node,
                                           InfoTreeModel model)

createNodeInfo

public NodeInfo createNodeInfo(SystemInfoNode node,
                               InfoTreeModel model)

createChildNodeInfos

public NodeInfo[] createChildNodeInfos(SystemInfoNode node,
                                       InfoTreeModel model)

getNodeText

protected java.lang.String getNodeText(SystemInfoNode node)