docs: public InstanceId restoreFromBuffer(ByteBuffer buf)
              throws IOException
      {
          buf.rewind();
  
          // Assumes config data is the last field.
          int dataSize = buf.remaining() - OFFSET_DATA;
          if (dataSize <= 0) {
              throw new IOException("Hashinator snapshot data is too small.");
          }
  
          // Get the CRC, zero out its buffer field, and compare to calculated CRC.
          long crcHeader = buf.getLong(OFFSET_CRC);
          buf.putLong(OFFSET_CRC, 0);
          final PureJavaCrc32 crcBuffer = new PureJavaCrc32();
          assert(buf.hasArray());
          crcBuffer.update(buf.array());
          if (crcHeader != crcBuffer.getValue()) {
              throw new IOException("Hashinator snapshot data CRC mismatch.");
          }
  
          // Slurp the data.
          int coord = buf.getInt(OFFSET_INSTID_COORD);
          long timestamp = buf.getLong(OFFSET_INSTID_TIMESTAMP);
          InstanceId instId = new InstanceId(coord, timestamp);
          m_version = buf.getLong(OFFSET_VERSION);
          m_serData = new byte[dataSize];
          buf.position(OFFSET_DATA);
          buf.get(m_serData);
  
          return instId;
      }