/** * Get the types of the fields of a specific class type, * returns the method names without the "get"/"is" part and camelCased * @param type any class * @param filter (optional) indicates the fields to return the types for, can be null for defaults * @return a map of field name -> class type */ @SuppressWarnings("SameParameterValue") public Map<String, Class<?>> getFieldTypes(Class<?> type, FieldsFilter filter) { Map<String, Class<?>> types = getFieldUtils().getFieldTypes(type, filter); return types; }
/** * Get the types of the fields of a specific class type, * returns the method names without the "get"/"is" part and camelCased * @param type any class * @param filter (optional) indicates the fields to return the types for, can be null for defaults * @return a map of field name -> class type */ @SuppressWarnings("SameParameterValue") public Map<String, Class<?>> getFieldTypes(Class<?> type, FieldsFilter filter) { Map<String, Class<?>> types = getFieldUtils().getFieldTypes(type, filter); return types; }
values.putAll( fieldAdapterManager.getFieldAdapter().getFieldValues(obj, filter) ); } else { Map<String, Class<?>> types = getFieldTypes(obj.getClass(), filter); if (FieldsFilter.WRITEABLE.equals(filter)) { types.clear();
values.putAll( fieldAdapterManager.getFieldAdapter().getFieldValues(obj, filter) ); } else { Map<String, Class<?>> types = getFieldTypes(obj.getClass(), filter); if (FieldsFilter.WRITEABLE.equals(filter)) { types.clear();
throw new IllegalArgumentException("object and properties cannot be null"); Map<String, Class<?>> fieldTypes = getFieldUtils().getFieldTypes(object.getClass(), FieldsFilter.ALL); List<String> writtenFields = new ArrayList<String>(); for (Entry<String, Object> entry : properties.entrySet()) {
throw new IllegalArgumentException("object and properties cannot be null"); Map<String, Class<?>> fieldTypes = getFieldUtils().getFieldTypes(object.getClass(), FieldsFilter.ALL); List<String> writtenFields = new ArrayList<String>(); for (Entry<String, Object> entry : properties.entrySet()) {