@Override
      public ElemType read(final @NotNull DataInput in) throws IOException {
        final int ordinal = DataInputOutputUtil.readINT(in);
        for (ElemType value : ElemType.values()) {
          if (value.ordinal() == ordinal) {
            return value;
          }
        }
        throw new IOException("Error reading ElementType enum value; unknown ordinal: " + ordinal);
      }
@Override
      public ElemType read(final @NotNull DataInput in)