Search in sources :

Example 1 with ViewingState

use of com.evolveum.midpoint.studio.ui.trace.ViewingState in project midpoint-studio by Evolveum.

the class OpOverviewTreePanel method updateModel.

@Override
void updateModel(OpNode node) {
    super.updateModel(node);
    ViewingState initialState = new ViewingState();
    DefaultMutableTreeTableNode root = new DefaultMutableTreeTableNode();
    if (node != null) {
        root.add(new TextNode("Operation", node.getLabel()));
        if (node.getType() != null) {
            try {
                // noinspection unchecked
                ((AbstractOpNodePresentation<OpNode>) node.getPresentation()).getOverviewProvider().provideOverview(node, root, initialState);
            } catch (SchemaException e) {
                TextNode.create("Couldn't provide overview", e.getMessage(), root);
            }
        }
    }
    updateTreeModel(root);
    setViewingState(initialState);
}
Also used : SchemaException(com.evolveum.midpoint.util.exception.SchemaException) ViewingState(com.evolveum.midpoint.studio.ui.trace.ViewingState) TextNode(com.evolveum.midpoint.studio.ui.trace.entry.TextNode) OpNode(com.evolveum.midpoint.schema.traces.OpNode) DefaultMutableTreeTableNode(org.jdesktop.swingx.treetable.DefaultMutableTreeTableNode)

Aggregations

OpNode (com.evolveum.midpoint.schema.traces.OpNode)1 ViewingState (com.evolveum.midpoint.studio.ui.trace.ViewingState)1 TextNode (com.evolveum.midpoint.studio.ui.trace.entry.TextNode)1 SchemaException (com.evolveum.midpoint.util.exception.SchemaException)1 DefaultMutableTreeTableNode (org.jdesktop.swingx.treetable.DefaultMutableTreeTableNode)1