fields.put(new Integer(field.getField()), field);
Integer key = new Integer(field.getField()); StringField replacedField = (StringField)fields.put(key, field);
    public void setField(StringField field) {        if (field.getValue() == null) {            throw new NullPointerException("Null field values are not allowed.");        }        fields.put(new Integer(field.getField()), field);    }