X-Git-Url: https://git.opendaylight.org/gerrit/gitweb?a=blobdiff_plain;f=opendaylight%2Fconfig%2Fconfig-manager-facade-xml%2Fsrc%2Fmain%2Fjava%2Forg%2Fopendaylight%2Fcontroller%2Fconfig%2Ffacade%2Fxml%2Fruntime%2FRuntime.java;h=1a5d1053142acf71911661e0fad665e699313352;hb=refs%2Fchanges%2F40%2F62940%2F4;hp=f58a9d8d37c48a6376e266975c323c035bcb0ae6;hpb=b197d75e803beac663033287d769dce62c108490;p=controller.git diff --git a/opendaylight/config/config-manager-facade-xml/src/main/java/org/opendaylight/controller/config/facade/xml/runtime/Runtime.java b/opendaylight/config/config-manager-facade-xml/src/main/java/org/opendaylight/controller/config/facade/xml/runtime/Runtime.java index f58a9d8d37..1a5d105314 100644 --- a/opendaylight/config/config-manager-facade-xml/src/main/java/org/opendaylight/controller/config/facade/xml/runtime/Runtime.java +++ b/opendaylight/config/config-manager-facade-xml/src/main/java/org/opendaylight/controller/config/facade/xml/runtime/Runtime.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved. + * Copyright (c) 2015, 2017 Cisco Systems, Inc. and others. All rights reserved. * * This program and the accompanying materials are made available under the * terms of the Eclipse Public License v1.0 which accompanies this distribution, @@ -52,19 +52,20 @@ public class Runtime { multimap.put(instanceName, objectName); } - return retVal; } - public Element toXml(Set instancesToMap, Set configBeans, Document document, final EnumResolver enumResolver) { + public Element toXml(Set instancesToMap, Set configBeans, Document document, + final EnumResolver enumResolver) { Element root = XmlUtil.createElement(document, XmlMappingConstants.DATA_KEY, Optional.absent()); - Element modulesElement = XmlUtil.createElement(document, XmlMappingConstants.MODULES_KEY, Optional.of(XmlMappingConstants.URN_OPENDAYLIGHT_PARAMS_XML_NS_YANG_CONTROLLER_CONFIG)); + Element modulesElement = XmlUtil.createElement(document, XmlMappingConstants.MODULES_KEY, + Optional.of(XmlMappingConstants.URN_OPENDAYLIGHT_PARAMS_XML_NS_YANG_CONTROLLER_CONFIG)); root.appendChild(modulesElement); Map> moduleToRuntimeInstance = mapInstancesToModules(instancesToMap); - Map>> moduleToConfigInstance = Config - .getMappedInstances(configBeans, moduleConfigs); + Map>> moduleToConfigInstance = Config.getMappedInstances(configBeans, + moduleConfigs); for (String localNamespace : moduleConfigs.keySet()) { @@ -78,7 +79,7 @@ public class Runtime { Element runtimeXml; ModuleConfig moduleConfig = moduleConfigs.get(localNamespace).get(moduleName); - if(instanceToRbe==null || !instanceToRbe.containsKey(instanceName)) { + if (instanceToRbe == null || !instanceToRbe.containsKey(instanceName)) { runtimeXml = moduleConfig.toXml(instanceON, document, localNamespace, enumResolver); } else { ModuleRuntime moduleRuntime = moduleRuntimes.get(localNamespace).get(moduleName); @@ -90,8 +91,6 @@ public class Runtime { } } - return root; } - }