/* (non-Javadoc)
@see org.apache.hadoop.io.Writable#readFields(java.io.DataInput)
169617
public void readFields(DataInput in) throws IOException {
    resetForm();

    int numDeleteTerms = in.readInt();
    for (int i = 0; i < numDeleteTerms; i++) {
      String field = Text.readString(in);
      String text = Text.readString(in);
      deleteList.add(new Term(field, text));
    }

    RAMDirectoryUtil.readRAMFiles(in, dir);
  }
903758
public void setupFields()
    {
        FieldInfo field = null;
        field = new FieldInfo(this, ID, Constants.DEFAULT_FIELD_LENGTH, null, null);
        field.setDataClass(Integer.class);
    }
700912
void readFieldsFromFSEditLog(DataInput in) throws IOException {
    this.name = UTF8.readString(in);
    this.storageID = UTF8.readString(in);
    this.infoPort = in.readShort() & 0x0000ffff;

    this.capacity = in.readLong();
    this.dfsUsed = in.readLong();
    this.remaining = in.readLong();
    this.lastUpdate = in.readLong();
    this.xceiverCount = in.readInt();
    this.location = Text.readString(in);
    this.hostName = Text.readString(in);
    setAdminState(WritableUtils.readEnum(in, AdminStates.class));
  }
676684
@Override
  public void readFields(DataInput in) throws IOException {
    this.filename = Text.readString(in);
    this.jobid = Text.readString(in);
    this.isJobConfFile = in.readBoolean();
    this.isJobHistoryFile = in.readBoolean();
  }
1339636
private static String forEachFields(final Set<String> fields, OnFieldListener listener) {
		StringBuilder builder = new StringBuilder();
		{
			String comma = "";
			for (String item : fields) {
				builder.append(comma + listener.onField(item));
				comma = ", ";
			}
		}

		return builder.toString();
	}
241433
private void readObject(java.io.ObjectInputStream s)
        throws java.io.IOException, ClassNotFoundException {

        // Read in all fields
        s.defaultReadObject();
        compile();
    }
51625
@Override
	public void read(final DataInput in) throws IOException {

		synchronized (this.confData) {

			final int numberOfProperties = in.readInt();

			for (int i = 0; i < numberOfProperties; i++) {
				final String key = StringRecord.readString(in);
				final String value = StringRecord.readString(in);
				this.confData.put(key, value);
			}
		}
	}
192353
public void readFields(DataInput in) throws IOException {
    byte version = in.readByte();                 // read version
    if (version != getVersion())
      throw new VersionMismatchException(getVersion(), version);
  }
552119
private void readObject(ObjectInputStream in) throws IOException, ClassNotFoundException {
		in.defaultReadObject();
		this.nullMask = new boolean[fieldSerializers.length];
	}
1258606
private static void readFully(final DataInput input, final int[] ints) throws IOException {
        if (input instanceof ImageInputStream) {
            // Optimization for ImageInputStreams, read all in one go
            ((ImageInputStream) input).readFully(ints, 0, ints.length);
        } else {
            for (int i = 0; i < ints.length; i++) {
                ints[i] = input.readInt();
            }
        }
    }
1241029
public void setSelectFields(java.util.Collection<FieldInfo> selectFields) {
        if (selectFields == null) {
            this.selectFields = null;
            return;
        }

        this.selectFields = new com.amazonaws.internal.SdkInternalList<FieldInfo>(selectFields);
    }
766019
@Override
    public void configFields(Configuration conf, String[] fields) 
            throws IllegalArgumentException, IOException {
        if (null != fields) {
            super.configFields(conf, fields);
        } else {
            throw new IOException("Fields not defined");
        }
        
        datatypeMap = new HashMap<String,ColumnDataType>();
        for (String s: fields) {
            datatypeMap.put(s, ColumnDataType.STRING);
        }
        String list = conf.get(ConfigConstants.CONF_DELIMITED_DATA_TYPE);
        if (list == null) {
            return;
        }
        String pairs[] = list.split(",");
        for (int i = 0; i < pairs.length; i += 2) {
            String colName = pairs[i].trim();
            String colDataType = pairs[i+1].trim();
            if (!datatypeMap.containsKey(colName)) {
                throw new IllegalArgumentException("Column name " + colName + " not found.");
            }
            if ("Number".equalsIgnoreCase(colDataType)) {
                datatypeMap.put(colName, ColumnDataType.NUMBER);
            } else if ("Boolean".equalsIgnoreCase(colDataType)) {
                datatypeMap.put(colName, ColumnDataType.BOOLEAN);
            } else if (!"String".equalsIgnoreCase(colDataType)) {
                throw new IllegalArgumentException("Unsupported column data type " + colDataType);
            }
        }
    }
413511
public void addReadFields2(FieldSet readFields) {
		if(this.readFields2 == null) {
			this.readFields2 = new FieldSet(readFields);
		} else {
			this.readFields2.addAll(readFields);
		}
	}
579716
@Override
  public void readFields(DataInput in) throws IOException {
    super.readFields(in);
    int numEntries = getPartialListing().length;
    blockLocations = new LocatedBlocks[numEntries];
    for (int i=0; i<numEntries; i++) {
      blockLocations[i] = new LocatedBlocks();
      blockLocations[i].readFields(in);
    }
  }
1361071
public void readFields(DataInput in) throws IOException {
        DataInputStream dis = new DataInputStream(new DataInputWrapperStream(in));
        byte header = dis.readByte();
        if (header != NDARRAY_SER_VERSION_HEADER && header != NDARRAY_SER_VERSION_HEADER_NULL) {
            throw new IllegalStateException("Unexpected NDArrayWritable version header - stream corrupt?");
        }

        if (header == NDARRAY_SER_VERSION_HEADER_NULL) {
            array = null;
            return;
        }

        array = Nd4j.read(dis);
        hash = null;
    }
440824
public void addReadFields(FieldSet readFields) {
		if (this.readFields == null) {
			this.readFields = readFields;
		} else {
			this.readFields = this.readFields.addFields(readFields);
		}
	}
683758
public void setupFields()
    {
        FieldInfo field = null;
        field = new FieldInfo(this, ID, Constants.DEFAULT_FIELD_LENGTH, null, null);
        field.setDataClass(Integer.class);
        field.setHidden(true);
        field = new FieldInfo(this, LAST_CHANGED, Constants.DEFAULT_FIELD_LENGTH, null, null);
        field.setDataClass(Date.class);
        field.setHidden(true);
        field = new FieldInfo(this, DELETED, 10, null, new Boolean(false));
        field.setDataClass(Boolean.class);
        field.setHidden(true);
        field = new FieldInfo(this, CODE, 30, null, null);
        field = new FieldInfo(this, DESCRIPTION, 50, null, null);
        field = new FieldInfo(this, QUEUE_NAME_ID, Constants.DEFAULT_FIELD_LENGTH, null, null);
        field.setDataClass(Integer.class);
        field = new FieldInfo(this, REPLY_MESSAGE_PROCESS_INFO_ID, Constants.DEFAULT_FIELD_LENGTH, null, null);
        field.setDataClass(Integer.class);
        field = new FieldInfo(this, LOCAL_MESSAGE_PROCESS_INFO_ID, Constants.DEFAULT_FIELD_LENGTH, null, null);
        field.setDataClass(Integer.class);
        field = new FieldInfo(this, MESSAGE_INFO_ID, Constants.DEFAULT_FIELD_LENGTH, null, null);
        field.setDataClass(Integer.class);
        field = new FieldInfo(this, MESSAGE_TYPE_ID, Constants.DEFAULT_FIELD_LENGTH, null, null);
        field.setDataClass(Integer.class);
        field = new FieldInfo(this, PROCESS_TYPE_ID, Constants.DEFAULT_FIELD_LENGTH, null, null);
        field.setDataClass(Integer.class);
        field = new FieldInfo(this, PROCESSOR_CLASS, 127, null, null);
        field = new FieldInfo(this, PROPERTIES, Constants.DEFAULT_FIELD_LENGTH, null, null);
        field = new FieldInfo(this, DEFAULT_MESSAGE_TRANSPORT_ID, Constants.DEFAULT_FIELD_LENGTH, null, null);
        field.setDataClass(Integer.class);
        field = new FieldInfo(this, INITIAL_MESSAGE_STATUS_ID, Constants.DEFAULT_FIELD_LENGTH, null, null);
        field.setDataClass(Integer.class);
    }