public abstract class Utils extends Object
Constructor and Description |
---|
Utils() |
Modifier and Type | Method and Description |
---|---|
static int |
byteArrayToInt(byte[] b,
int offset) |
static String |
byteArrayToStr(byte[] input) |
static String |
bytesToHexString(byte[] src) |
static byte[] |
intToByteArray(int integer) |
static com.google.protobuf.ByteString |
parseDeviceConfigInfo(String file)
Parses the device config file generated by the compiler.
|
static P4Info |
parseRuntimeInfo(String file)
Parses the device config and runtime resource files generated by compiler.
|
static byte[] |
strToByteArray(String str,
int len)
Only support ipv4 address, mac address and integer value.
|
public static P4Info parseRuntimeInfo(String file) throws IOException
IOException
public static com.google.protobuf.ByteString parseDeviceConfigInfo(String file) throws IOException
IOException
public static byte[] strToByteArray(String str, int len)
public static String byteArrayToStr(byte[] input)
public static byte[] intToByteArray(int integer)
public static int byteArrayToInt(byte[] b, int offset)
public static String bytesToHexString(byte[] src)
Copyright © 2018 OpenDaylight. All rights reserved.