Search in sources :

Example 1 with DelegateInvocation

use of si.ijs.acs.objectexplorer.engine.BACI.DelegateInvocation in project ACS by ACS-Community.

the class TreeHandlerBean method addNode.

/**
	 * @author rbertoncelj
	 */
public void addNode(javax.swing.tree.TreeNode node, javax.swing.tree.TreeNode parentNode) {
    addNodes(new TreeNode[] { node }, parentNode);
    if (node instanceof BACIInvocation) {
        BACIInvocation invoc = (BACIInvocation) node;
        InvocationCouple ic = new InvocationCouple(invoc, null);
        ic.invocationByName = new DelegateInvocation(invoc, treeByName, (BACIRemoteAccess) remoteAccess);
        String curl = (String) ((OETreeNode) parentNode.getParent()).getUserObject() + ":" + parentNode.toString();
        RemoteNodeCouple rnc = (RemoteNodeCouple) devices.get(curl);
        if (rnc == null) {
            notifier.reportError("TreeHandlerBean::addNode - Unexpected null pointer (rnc).");
            return;
        }
        // yatagai : the name can not be the proper key -- does not work
        // when more than 1 sub node are added.
        // getInvList().put(invoc.getName(),ic);
        getInvList().put(invoc, ic);
        setNodesTreeByName(new TreeNode[] { ic.invocationByName }, rnc.deviceByName);
    //System.out.println("DEBUG Added to invList "+invoc.getName()+"!");
    }
}
Also used : InvocationCouple(si.ijs.acs.objectexplorer.engine.BACI.InvocationCouple) BACIInvocation(si.ijs.acs.objectexplorer.engine.BACI.BACIInvocation) BACIRemoteAccess(si.ijs.acs.objectexplorer.engine.BACI.BACIRemoteAccess) RemoteNodeCouple(si.ijs.acs.objectexplorer.engine.BACI.RemoteNodeCouple) DelegateInvocation(si.ijs.acs.objectexplorer.engine.BACI.DelegateInvocation)

Aggregations

BACIInvocation (si.ijs.acs.objectexplorer.engine.BACI.BACIInvocation)1 BACIRemoteAccess (si.ijs.acs.objectexplorer.engine.BACI.BACIRemoteAccess)1 DelegateInvocation (si.ijs.acs.objectexplorer.engine.BACI.DelegateInvocation)1 InvocationCouple (si.ijs.acs.objectexplorer.engine.BACI.InvocationCouple)1 RemoteNodeCouple (si.ijs.acs.objectexplorer.engine.BACI.RemoteNodeCouple)1