Set the behavior of marqueeToolEntry as below-
MarqueeToolEntry marquee = new MarqueeToolEntry();
marquee.setToolProperty(MarqueeSelectionTool.PROPERTY_MARQUEE_BEHAVIOR,
new Integer(MarqueeSelectionTool.BEHAVIOR_NODES_CONTAINED_AND_RELATED_CONNECTIONS));
This will select the nodes as well the related connections.