Class TreeTableNodeType


  • public class TreeTableNodeType
    extends java.lang.Object
    The node type represents the generic properties of tree table nodes.
    • Field Summary

      Fields 
      Modifier and Type Field Description
      protected java.util.List actions
      The supported popup actions.
      protected java.lang.String[] columnnames
      The display names of the columns.
      protected java.lang.String[] columns
      The columns (internal names of properties).
      protected boolean[] editable
      The editability of the columns.
      protected boolean[] excludes
      The excluded columns of this type.
      protected javax.swing.Icon[] icons
      The icon.
      protected java.lang.String name
      The type name.
      protected TreeTableNodeType supertype
      The supertype (if any).
    • Constructor Summary

      Constructors 
      Constructor Description
      TreeTableNodeType​(java.lang.String name, javax.swing.Icon[] icons, TreeTableNodeType supertype)
      Create a treetable node type inheriting from some other type.
      TreeTableNodeType​(java.lang.String name, javax.swing.Icon[] icons, java.lang.String[] columns, java.lang.String[] columnnames)
      Create a treetable node type.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void addExclude​(java.lang.String column)
      Exclude a column.
      void addIcon​(javax.swing.Icon icon)
      Add an icon.
      void addPopupAction​(javax.swing.Action action)
      Add a popup action.
      java.lang.String[] getColumnNames()
      Get the column names (display names).
      java.lang.String[] getColumns()
      Get the columns (internal property names).
      javax.swing.Icon getIcon​(java.lang.Object value)
      Get the icon.
      java.lang.String getName()
      Get the type name.
      javax.swing.Action[] getPopupActions()
      Get all popup actions (also from supertypes).
      TreeTableNodeType getSupertype()
      Get the supertype.
      boolean isColumnEditable​(int column)
      Get the editability of the column.
      boolean isColumnExcluded​(int column)
      Check if nodes of this type should have a value for the given column.
      javax.swing.Icon selectIcon​(java.lang.Object value)
      Select an icon.
      void setEditable​(java.lang.String column)
      Make a column editable.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • name

        protected java.lang.String name
        The type name.
      • icons

        protected javax.swing.Icon[] icons
        The icon.
      • columns

        protected java.lang.String[] columns
        The columns (internal names of properties).
      • columnnames

        protected java.lang.String[] columnnames
        The display names of the columns.
      • editable

        protected boolean[] editable
        The editability of the columns.
      • excludes

        protected boolean[] excludes
        The excluded columns of this type.
      • actions

        protected java.util.List actions
        The supported popup actions.
    • Constructor Detail

      • TreeTableNodeType

        public TreeTableNodeType​(java.lang.String name,
                                 javax.swing.Icon[] icons,
                                 TreeTableNodeType supertype)
        Create a treetable node type inheriting from some other type.
        Parameters:
        name - The type name.
        icons - The icons.
        supertype - The supertype.
      • TreeTableNodeType

        public TreeTableNodeType​(java.lang.String name,
                                 javax.swing.Icon[] icons,
                                 java.lang.String[] columns,
                                 java.lang.String[] columnnames)
        Create a treetable node type.
    • Method Detail

      • getSupertype

        public TreeTableNodeType getSupertype()
        Get the supertype.
        Returns:
        The supertype.
      • getName

        public java.lang.String getName()
        Get the type name.
        Returns:
        The name of the node type.
      • addIcon

        public void addIcon​(javax.swing.Icon icon)
        Add an icon.
        Parameters:
        icon - The icon for the node.
      • getIcon

        public javax.swing.Icon getIcon​(java.lang.Object value)
        Get the icon.
        Returns:
        The icon for the node.
      • selectIcon

        public javax.swing.Icon selectIcon​(java.lang.Object value)
        Select an icon.
        Parameters:
        value - The selection criterium.
        Returns:
        The icon to be used.
      • getColumns

        public java.lang.String[] getColumns()
        Get the columns (internal property names).
        Returns:
        The columns.
      • getColumnNames

        public java.lang.String[] getColumnNames()
        Get the column names (display names).
        Returns:
        The column namess.
      • isColumnEditable

        public boolean isColumnEditable​(int column)
        Get the editability of the column.
        Parameters:
        column - The column to check for editability.
        Returns:
        The editablility.
      • isColumnExcluded

        public boolean isColumnExcluded​(int column)
        Check if nodes of this type should have a value for the given column.
        Parameters:
        column - The column to check for.
        Returns:
        True, if there is no value for the given column.
      • addExclude

        public void addExclude​(java.lang.String column)
        Exclude a column.
        Parameters:
        column - The column to exclude.
      • setEditable

        public void setEditable​(java.lang.String column)
        Make a column editable.
        Parameters:
        column - The column to be editable.
      • addPopupAction

        public void addPopupAction​(javax.swing.Action action)
        Add a popup action.
        Parameters:
        action - The action.
        name - The (display) name of the action.
      • getPopupActions

        public javax.swing.Action[] getPopupActions()
        Get all popup actions (also from supertypes).
        Returns:
        The popup actions.