public void readFields(DataInput in) throws IOException {
fields.clear();
byte version = in.readByte();
if (version != VERSION) {
throw new VersionMismatchException(VERSION, version);
}
int size = WritableUtils.readVInt(in);
for (int i = 0; i < size; i++) {
String name = Text.readString(in);
NutchField field = new NutchField();