Added more configuration options for NetconfDeviceSimulator
[netconf.git] / netconf / tools / netconf-testtool / src / main / java / org / opendaylight / netconf / test / tool / TestToolUtils.java
index b2c6ca0c319ba6f4973783cdb84e69ac8a231d11..15fd535de8c3d0eadf876935720884f2dbd6bf0b 100644 (file)
@@ -8,19 +8,23 @@
 
 package org.opendaylight.netconf.test.tool;
 
-public class TestToolUtils {
+import java.io.InputStream;
+
+public final class TestToolUtils {
 
     public static String getMac(long mac) {
         final StringBuilder builder = new StringBuilder(Long.toString(mac, 16));
-
         for (int i = builder.length(); i < 12; i++) {
             builder.insert(0, "0");
         }
-
         for (int j = builder.length() - 2; j >= 2; j -= 2) {
             builder.insert(j, ":");
         }
-
         return builder.toString();
     }
+
+    public static InputStream getDataAsStream(final String path) {
+        return TestToolUtils.class.getClassLoader().getResourceAsStream(path);
+    }
+
 }