Fix findbugs violations in netconf
[netconf.git] / netconf / tools / netconf-testtool / src / main / java / org / opendaylight / netconf / test / tool / rpc / SimulatedGetConfig.java
index e6db368b928cde01f861a58410c34bd9f71797a6..f7b942125e532fb2da446e5cf46dd5a2bd0138a7 100644 (file)
@@ -11,7 +11,6 @@ package org.opendaylight.netconf.test.tool.rpc;
 import com.google.common.base.Optional;
 import java.io.File;
 import java.io.IOException;
-import java.util.Collections;
 import java.util.List;
 import org.opendaylight.controller.config.util.xml.DocumentedException;
 import org.opendaylight.controller.config.util.xml.XmlElement;
@@ -43,14 +42,13 @@ public class SimulatedGetConfig extends AbstractConfigNetconfOperation {
         }
     }
 
-    private DataList loadInitialConfigXMLFile(final File file) {
+    private static DataList loadInitialConfigXMLFile(final File file) {
         LOG.info("Loading initial config xml file: {}", file.getName());
         DataList configData = new DataList();
-        List<XmlElement> xmlElementList = Collections.emptyList();
         try {
             Element element = XmlUtil.readXmlToElement(file);
             XmlElement xmlElement = XmlElement.fromDomElement(element);
-            xmlElementList = xmlElement.getChildElements();
+            List<XmlElement> xmlElementList = xmlElement.getChildElements();
             configData.setConfigList(xmlElementList);
         } catch (IOException e) {
             LOG.info("IO exception loading xml file: {} ", e.getMessage());