public class ParseTreeTableModel extends Object implements TreeModel
Constructor and Description |
---|
ParseTreeTableModel(DetailAST parseTree)
Initialise pModel.
|
Modifier and Type | Method and Description |
---|---|
void |
addTreeModelListener(TreeModelListener listener) |
Object |
getChild(Object parent,
int index) |
int |
getChildCount(Object parent) |
Class<?> |
getColumnClass(int column)
Returns type of specified column number.
|
int |
getColumnCount()
Returns number of available column.
|
String |
getColumnName(int column)
Returns column name of specified column number.
|
int |
getIndexOfChild(Object parent,
Object child) |
Object |
getRoot() |
Object |
getValueAt(Object node,
int column)
Returns the value to be displayed for node at column number.
|
boolean |
isCellEditable(int column)
Indicates whether the the value for node
node ,
at column number column is editable. |
boolean |
isLeaf(Object node) |
void |
removeTreeModelListener(TreeModelListener listener) |
protected void |
setParseMode(MainFrameModel.ParseMode mode)
Set parse mode.
|
protected void |
setParseTree(DetailAST parseTree)
Sets parse tree.
|
void |
valueForPathChanged(TreePath path,
Object newValue) |
public ParseTreeTableModel(DetailAST parseTree)
parseTree
- DetailAST parse tree.protected final void setParseTree(DetailAST parseTree)
parseTree
- DetailAST parse tree.protected void setParseMode(MainFrameModel.ParseMode mode)
mode
- ParseMode enumpublic int getColumnCount()
public String getColumnName(int column)
column
- the column numbercolumn
.public Class<?> getColumnClass(int column)
column
- the column numbercolumn
.public Object getValueAt(Object node, int column)
node
- the nodecolumn
- the column numbernode
,
at column number column
.public int getChildCount(Object parent)
getChildCount
in interface TreeModel
public void valueForPathChanged(TreePath path, Object newValue)
valueForPathChanged
in interface TreeModel
public int getIndexOfChild(Object parent, Object child)
getIndexOfChild
in interface TreeModel
public void addTreeModelListener(TreeModelListener listener)
addTreeModelListener
in interface TreeModel
public void removeTreeModelListener(TreeModelListener listener)
removeTreeModelListener
in interface TreeModel
public boolean isCellEditable(int column)
node
,
at column number column
is editable.column
- the column numberCopyright © 2001–2018. All rights reserved.