Package org.opentrafficsim.editor
Class XsdTreeTableModel
java.lang.Object
de.javagl.treetable.AbstractTreeTableModel
org.opentrafficsim.editor.XsdTreeTableModel
- All Implemented Interfaces:
de.javagl.treetable.TreeTableModel
,TreeModel
public class XsdTreeTableModel
extends de.javagl.treetable.AbstractTreeTableModel
Defines the columns in the
JTreeTable
. Most functionality is forwarded to the tree with XsdTreeNode
's.
Copyright (c) 2023-2024 Delft University of Technology, PO Box 5, 2600 AA, Delft, the Netherlands. All rights reserved.
BSD-style license. See OpenTrafficSim License.
- Author:
- Wouter Schakel
-
Field Summary
Fields inherited from class de.javagl.treetable.AbstractTreeTableModel
root
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic void
applyColumnWidth
(de.javagl.treetable.JTreeTable treeTable) Apply the column widths to a newly created tree table.int
getChildCount
(Object parent) Class<?>
getColumnClass
(int column) int
getColumnName
(int column) getValueAt
(Object node, int column) boolean
isCellEditable
(Object node, int column) occurs
(int minOccurs, int maxOccurs) Creates a string to display minOccurs and maxOccurs.void
setTreeTable
(de.javagl.treetable.JTreeTable treeTable) Sets the tree table.void
setValueAt
(Object aValue, Object node, int column) Methods inherited from class de.javagl.treetable.AbstractTreeTableModel
addTreeModelListener, fireTreeNodesChanged, fireTreeNodesInserted, fireTreeNodesRemoved, fireTreeStructureChanged, getIndexOfChild, getRoot, isLeaf, removeTreeModelListener, valueForPathChanged
-
Constructor Details
-
XsdTreeTableModel
Constructor.- Parameters:
document
- Document; XSD document.- Throws:
RemoteException
- when unable to listen for created nodes.
-
-
Method Details
-
setTreeTable
public void setTreeTable(de.javagl.treetable.JTreeTable treeTable) Sets the tree table.- Parameters:
treeTable
- JTreeTable; tree table.
-
getColumnCount
public int getColumnCount() -
getColumnName
-
getColumnClass
-
getValueAt
-
occurs
Creates a string to display minOccurs and maxOccurs.- Parameters:
minOccurs
- int; minOccurs.maxOccurs
- int; maxOccurs.- Returns:
- String; string to display minOccurs and maxOccurs.
-
getChild
-
getChildCount
-
isCellEditable
- Specified by:
isCellEditable
in interfacede.javagl.treetable.TreeTableModel
- Overrides:
isCellEditable
in classde.javagl.treetable.AbstractTreeTableModel
-
setValueAt
- Specified by:
setValueAt
in interfacede.javagl.treetable.TreeTableModel
- Overrides:
setValueAt
in classde.javagl.treetable.AbstractTreeTableModel
-
applyColumnWidth
public static void applyColumnWidth(de.javagl.treetable.JTreeTable treeTable) Apply the column widths to a newly created tree table.- Parameters:
treeTable
- JTreeTable; tree table.
-