Search in sources :

Example 1 with TreeTableExplorer

use of cern.gp.explorer.TreeTableExplorer in project ACS by ACS-Community.

the class TestTreeTableExplorer method main.

public static void main(String[] args) throws Exception {
    final SimpleDemoBean bean = new SimpleDemoBean("parent");
    GPNode root = NodeFactory.createNode(bean, new RecursiveChildrenListManager());
    TreeTableExplorer expl = new TreeTableExplorer();
    expl.setTableColumns(bean);
    expl.setRootNode(root);
    WindowUtils.openInMode(expl, "TestTreeTableExplorer");
    if (expl.getRootNode() != root) {
        System.err.println("bug:rootNode !+ getRootNode");
    }
}
Also used : SimpleDemoBean(cern.gp.explorer.test.helpers.SimpleDemoBean) TreeTableExplorer(cern.gp.explorer.TreeTableExplorer) RecursiveChildrenListManager(cern.gp.explorer.test.helpers.RecursiveChildrenListManager) GPNode(cern.gp.nodes.GPNode)

Example 2 with TreeTableExplorer

use of cern.gp.explorer.TreeTableExplorer in project ACS by ACS-Community.

the class TestTreeTableExplorerWithButtons method createExplorer.

public static TreeTableExplorer createExplorer() {
    TreeTableExplorer expl = null;
    try {
        final SimpleDemoBean bean = new SimpleDemoBean("parent");
        GPNode root = NodeFactory.createNode(bean, new RecursiveChildrenListManager());
        expl = new TreeTableExplorer();
        expl.setTableColumns(bean);
        expl.setRootNode(root);
    } catch (IntrospectionException ex) {
        ex.printStackTrace();
    }
    return expl;
}
Also used : SimpleDemoBean(cern.gp.explorer.test.helpers.SimpleDemoBean) TreeTableExplorer(cern.gp.explorer.TreeTableExplorer) RecursiveChildrenListManager(cern.gp.explorer.test.helpers.RecursiveChildrenListManager) IntrospectionException(java.beans.IntrospectionException) GPNode(cern.gp.nodes.GPNode)

Example 3 with TreeTableExplorer

use of cern.gp.explorer.TreeTableExplorer in project ACS by ACS-Community.

the class TestTreeTableExplorerWithButtons method main.

public static void main(String[] args) throws Exception {
    TreeTableExplorer expl = createExplorer();
    JPanel panel = ActionUtils.createJButtonPanel(new Class[] { PropertiesAction.class, OpenLocalExplorerAction.class });
    expl.add(panel, BorderLayout.SOUTH);
    WindowUtils.openInMode(expl, "TestTreeTableExplorer");
    expl.requestFocus();
}
Also used : JPanel(javax.swing.JPanel) TreeTableExplorer(cern.gp.explorer.TreeTableExplorer)

Aggregations

TreeTableExplorer (cern.gp.explorer.TreeTableExplorer)3 RecursiveChildrenListManager (cern.gp.explorer.test.helpers.RecursiveChildrenListManager)2 SimpleDemoBean (cern.gp.explorer.test.helpers.SimpleDemoBean)2 GPNode (cern.gp.nodes.GPNode)2 IntrospectionException (java.beans.IntrospectionException)1 JPanel (javax.swing.JPanel)1