设置字段列表，用于限制加入的字段的值

@param fieldNames 字段列表
@return 自身
9381
public Entity setFieldNames(String... fieldNames) {
		if (ArrayUtil.isNotEmpty(fieldNames)) {
			this.fieldNames = CollectionUtil.newHashSet(fieldNames);
		}
		return this;
	}
481712
function(){
        var fieldNames = [], i, n = this._fieldCount;
        for (i = 0; i < n; i++) fieldNames[i] = this.fieldOrder[i];
        return fieldNames;
    }
1115437
@SuppressWarnings("unchecked")
	public Q includeFields(final Set<String> fields) {
		if (this.fields == null) {
			this.fields = new HashSet<>();
		}

		if (fields != null) {
			this.fields.addAll(fields);
		}

		return (Q) this;
	}
1080525
public FieldInfo getFieldInfo(final String fieldName) {
        for(FieldInfo item : fieldInfos) {
            if(item.getFieldName().equals(fieldName)) {
                return item;
            }
        }
        
        return null;
    }
1230634
public R setFields(String... fields) {
        if (fields.length == 1 && fields[0] == null){
            mQueryMap.remove(QUERY_FIELDS);
            return (R) this;
        }
        if (fields.length > 0) {
            StringBuilder sb = new StringBuilder();
            sb.append(fields[0]);
            for (int i = 1; i < fields.length; ++i) {
                sb.append(String.format(Locale.ENGLISH, ",%s", fields[i]));
            }
            mQueryMap.put(QUERY_FIELDS, sb.toString());
        }

        return (R) this;
    }
821297
public static synchronized void registerFieldsToFilter(Class<?> containingClass,
                                              String ... fieldNames) {
        fieldFilterMap =
            registerFilter(fieldFilterMap, containingClass, fieldNames);
    }
136609
@Nullable
	private FieldAnnotation getFieldAnnotation(final String fieldName) {
		JavaClass cls = getClassContext().getJavaClass();
		Field[] fields = cls.getFields();
		for (Field f : fields) {
			if (f.getName().equals(fieldName)) {
				return new FieldAnnotation(cls.getClassName(), fieldName, f.getSignature(), f.isStatic());
			}
		}
		return null; // shouldn't happen
	}
1351905
public String getHeaderField(String fieldName) {
        // headers map is null for all regular response calls except when made as a batch request
        if (this.headers == null) {
            if (this.connection != null) {
                return this.connection.getHeaderField(fieldName);
            } else {
                return null;
            }
        } else {
            return this.headers.get(fieldName);
        }
    }
552884
public Hit withFields(java.util.Map<String, java.util.List<String>> fields) {
        setFields(fields);
        return this;
    }
422741
public FieldStatsOptions addField(String fieldName) {

		Assert.hasText(fieldName, "Fieldname for statistics must not be blank.");

		return addField(new SimpleField(fieldName));
	}
801714
public String getString(final String fieldName) {
    try {
      return _jsonObject.getString(fieldName);
    } catch (JSONException ex) {
      throw new RuntimeException("Cannot find field", ex);
    }
  }
1136522
def fields(self, new_fieldnames):
        
        if len(new_fieldnames) != len(self.fields):
            raise Exception("Cannot replace fieldnames (len: %s) with list of "
                            "incorrect length (len: %s)" % (len(new_fieldnames),
                                                            len(self.fields)))
        for old_name, new_name in izip(self.fields, new_fieldnames):
            # use pop instead of `del` in case old_name == new_name
            self.__data[new_name] = self.__data.pop(old_name)
1049492
public String getString(String fieldName) {
		return hasValue(fieldName) ? String.valueOf(resultMap.get(fieldName)) : null;
	}
1353713
private static Document getProjection(List<String> fieldNames) {
		Document projection = new Document();
		for ( String column : fieldNames ) {
			projection.put( column, 1 );
		}

		return projection;
	}
95308
public Entity setFieldNames(Collection<String> fieldNames) {
		if (CollectionUtil.isNotEmpty(fieldNames)) {
			this.fieldNames = new HashSet<String>(fieldNames);
		}
		return this;
	}
329166
private Map<String, Field> populateRecordFields(Map<String, Field> fields) {
    if (fields == null) {
      return null;
    }

    Map<String, Schema> knownRecordSchemas = Maps.newHashMap();
    knownRecordSchemas.put(recordName, this);
    ImmutableMap.Builder<String, Field> builder = ImmutableMap.builder();

    for (Map.Entry<String, Field> fieldEntry : fields.entrySet()) {
      String fieldName = fieldEntry.getKey();
      Field field = fieldEntry.getValue();
      Schema fieldSchema = resolveSchema(field.getSchema(), knownRecordSchemas);

      if (fieldSchema == field.getSchema()) {
        builder.put(fieldName, field);
      } else {
        builder.put(fieldName, Field.of(fieldName, fieldSchema));
      }
    }

    return builder.build();
  }
28253
public ArrayList getFields(String fieldNames) throws NoSuchFieldException
    {
        ArrayList          result    = new ArrayList();
        FieldDescriptorDef fieldDef;
        String             name;

        for (CommaListIterator it = new CommaListIterator(fieldNames); it.hasNext();)
        {
            name = it.getNext();
            fieldDef = getField(name);
            if (fieldDef == null)
            {
                throw new NoSuchFieldException(name);
            }
            result.add(fieldDef);
        }
        return result;
    }