WebSphere Message Broker, Version 8.0.0.7 Operating Systems: AIX, HP-Itanium, Linux, Solaris, Windows, z/OS

See information about the latest product version

Copying a node

Use the Message Broker Java™ API when developing message flow applications to copy a node or subflow node to a message flow.

You can copy a built-in or subflow node by using the clone() method. In the following example, a new MQInput node mqinNode is created and properties on the node are set. A new MQInput node mqinNode1 is then created by copying mqinNode by using the clone() method. When the node is copied, the node properties are also copied:
File msgFlow = new File("main.msgflow");
MessageFlow mf1 = FlowRendererMSGFLOW.read(msgFlow);
MQInputNode mqinNode = new MQInputNode();
mqinNode.setNodeName("My Input Node");
mqinNode.setQueueName("INPUTQ");
MQInputNode mqinNode1 = (MQInputNode) mqinNode.clone();
mqinNode1.setNodeName("Copy of My Input Node");
mf1.addNode(mqinNode1);
Notices | Trademarks | Downloads | Library | Support | Feedback

Copyright IBM Corporation 1999, 2016Copyright IBM Corporation 1999, 2016.

        
        Last updated:
        
        Last updated: 2016-05-23 14:47:55


Task topicTask topic | Version 8.0.0.7 | bc31580_