private void updateTreeNodes(StatsProviderRegistryElement spre, boolean enable) {
//Enable/Disable the child TreeNodes
String parentNodePath = spre.getParentTreeNodePath();
List<String> childNodeNames = spre.getChildTreeNodeNames();
TreeNode rootNode = mrdr.get(instanceName);
if (rootNode != null) {
// This has to return one node
List<TreeNode> nodeList = rootNode.getNodes(parentNodePath, false, true);
TreeNode parentNode = nodeList.get(0);
//For each child Node, enable it
Collection<TreeNode> childNodes = parentNode.getChildNodes();
boolean hasUpdatedNode = false;
for (TreeNode childNode : childNodes) {
if (childNodeNames.contains(childNode.getName())) {
//Enabling or Disabling the child node (based on enable flag)
if (childNode.isEnabled() != enable) {