public static long hash64(Object o) {
        if (o == null) {
            return 0l;
        } else if (o instanceof String) {
            final byte[] bytes = ((String) o).getBytes();
            return hash64(bytes, bytes.length);
        } else if (o instanceof byte[]) {
            final byte[] bytes = (byte[]) o;
            return hash64(bytes, bytes.length);
        }
        return hash64(o.toString());
    }
@Test
    public void testHash64ByteArrayOverload() {
        String input = "hashthis";
        byte[] inputBytes = input.getBytes();

        long hashOfString = MurmurHash.hash64(input);
        assertEquals("MurmurHash.hash64(byte[]) did not match MurmurHash.hash64(String)",
                     hashOfString, MurmurHash.hash64(inputBytes));

        Object bytesAsObject = inputBytes;
        assertEquals("MurmurHash.hash64(Object) given a byte[] did not match MurmurHash.hash64(String)",
                     hashOfString, MurmurHash.hash64(bytesAsObject));
    }