public static String genDpid(long index) {
        if (index < 0) {
            return null;
        }

        String hexStr = Long.toHexString(index);

        StringBuilder zeroPadding = new StringBuilder();
        for (int i = 0; i < HEX_LENGTH - hexStr.length(); i++) {
            zeroPadding.append(ZERO);
        }

        return OF_PREFIX + zeroPadding.toString() + hexStr;
    }
@Test
    public void testGenDpid() {
        long one = 1;
        long ten = 10;
        long sixteen = 16;
        long seventeen = 17;
        long minus = -1;

        assertEquals("of:0000000000000001", genDpid(one));
        assertEquals("of:000000000000000a", genDpid(ten));
        assertEquals("of:0000000000000010", genDpid(sixteen));
        assertEquals("of:0000000000000011", genDpid(seventeen));
        assertNull(genDpid(minus));
    }