code: private void populateBean(Object bean, Map<String, Object> values) throws PropertyException
      {
          BeanDescriptor beanDescriptor = getBeanDescriptor(bean.getClass());
  
          // Lower case provided properties to easily ignore properties name case
          Map<String, String> lowerKeyMap = new HashMap<String, String>(values.size());
          for (Map.Entry<String, ?> entry : values.entrySet()) {
              lowerKeyMap.put(entry.getKey().toLowerCase(), entry.getKey());
          }
  
          for (PropertyDescriptor propertyDescriptor : beanDescriptor.getProperties()) {
              String propertyId = propertyDescriptor.getId();
              Object value = values.get(propertyId);
  
              if (value == null) {
                  propertyId = propertyId.toLowerCase();
                  value = values.get(lowerKeyMap.get(propertyId));
              }
  
              if (value != null) {
                  try {
                      // Convert
                      Object convertedValue = this.converterManager.convert(propertyDescriptor.getPropertyType(), value);
  
                      if (propertyDescriptor.getWriteMethod() != null) {
                          Method writerMethod = propertyDescriptor.getWriteMethod();
  
                          setAccessibleSafely(writerMethod);
  
                          // Invoke the method
                          writerMethod.invoke(bean, convertedValue);
                      } else if (propertyDescriptor.getField() != null) {
                          Field field = propertyDescriptor.getField();
  
                          setAccessibleSafely(field);
  
                          // Set the field
                          field.set(bean, convertedValue);
                      }
                  } catch (Exception e) {
                      throw new PropertyException("Failed to populate property [" + propertyId + "]", e);
                  }
  
                  // "Tick" already populated properties
                  values.remove(propertyId);
              } else if (propertyDescriptor.isMandatory()) {
                  throw new PropertyMandatoryException(propertyId);
              }
          }
      }
docs: Populate the provided bean with provided values.
  <p>
  <code>values</code> is "consumed": when method executing is finished it only contains not populated properties.
  
  @param bean the java bean to populate
  @param values the values to convert and inject in the java bean
  @throws PropertyException error when populating the bean