org.apache.jmeter.gui.tree

Class JMeterTreeModel


public class JMeterTreeModel
extends DefaultTreeModel

Constructor Summary

JMeterTreeModel()
JMeterTreeModel(Object o)
Deprecated. - only for use by JMeter class!
JMeterTreeModel(TestElement tp, TestElement wb)

Method Summary

JMeterTreeNode
addComponent(TestElement component, JMeterTreeNode node)
HashTree
addSubTree(HashTree subTree, JMeterTreeNode current)
Adds the sub tree at the given node.
void
clearTestPlan()
Clear the test plan, and use default node for test plan and workbench.
void
clearTestPlan(TestElement testPlan)
Clear the test plan, and use specified node for test plan and default node for workbench N.B.
HashTree
getCurrentSubTree(JMeterTreeNode node)
JMeterTreeNode
getNodeOf(TestElement userObject)
Get the node for a given TestElement object.
List
getNodesOfType(Class type)
Returns a list of tree nodes that hold objects of the given class type.
HashTree
getTestPlan()
void
removeNodeFromParent(JMeterTreeNode node)

Constructor Details

JMeterTreeModel

public JMeterTreeModel()

JMeterTreeModel

public JMeterTreeModel(Object o)

Deprecated. - only for use by JMeter class!

Hack to allow TreeModel to be used in non-GUI and headless mode.
Parameters:
o - - dummy

JMeterTreeModel

public JMeterTreeModel(TestElement tp,
                       TestElement wb)

Method Details

addComponent

public JMeterTreeNode addComponent(TestElement component,
                                   JMeterTreeNode node)
            throws IllegalUserActionException

addSubTree

public HashTree addSubTree(HashTree subTree,
                           JMeterTreeNode current)
            throws IllegalUserActionException
Adds the sub tree at the given node. Returns a boolean indicating whether the added sub tree was a full test plan.

clearTestPlan

public void clearTestPlan()

clearTestPlan

public void clearTestPlan(TestElement testPlan)
Clear the test plan, and use specified node for test plan and default node for workbench N.B. Should only be called by GuiPackage.clearTestPlan(TestElement)
Parameters:
testPlan - the node to use as the testplan top node

getCurrentSubTree

public HashTree getCurrentSubTree(JMeterTreeNode node)

getNodeOf

public JMeterTreeNode getNodeOf(TestElement userObject)
Get the node for a given TestElement object.

getNodesOfType

public List getNodesOfType(Class type)
Returns a list of tree nodes that hold objects of the given class type. If none are found, an empty list is returned.

getTestPlan

public HashTree getTestPlan()

removeNodeFromParent

public void removeNodeFromParent(JMeterTreeNode node)

Copyright © 1998-2010 Apache Software Foundation. All Rights Reserved.