docs: public int getCodec(final Class<?> clazz) {
      if (clazz == null) {
        throw new IllegalArgumentException("Clazz cannot be null.");
      }
      final Integer id = codecs_ids.get(clazz);
      if (id == null) {
        throw new IllegalArgumentException("No codec ID assigned to class " 
            + clazz);
      }
      return id;
    }