private static void validateTextString(String id) {
        if ( ! Text.isValidTextString(id)) {
            throw new IllegalArgumentException("Unparseable id '" + id + "': Contains illegal code point 0x" +
                    Integer.toHexString(Text.validateTextString(id).getAsInt()).toUpperCase());
        }
    }
Creates a IdString based on the given serialized document id string.

The document id string can not contain 0x0 byte characters.
document/src/main/java/com/yahoo/document/idstring/IdString.java