code: @SuppressWarnings("unchecked")
      protected void setParameters(PreparedStatement stmt, PropertyDesc[] propDescs, Object entity) throws SQLException {
          for (int i = 0; i < propDescs.length; i++) {
              PropertyDesc propertyDesc = propDescs[i];
              if(propertyDesc == null /*|| propertyDesc.getValue(entity) == null*/){
                  stmt.setObject(i + 1, null);
              } else {
                  Class<?> propertType = propertyDesc.getPropertyType();
                  @SuppressWarnings("rawtypes")
                  ValueType valueType = MirageUtil.getValueType(propertType, propertyDesc, dialect, valueTypes);
                  if(valueType != null){
                      valueType.set(propertType, stmt, propertyDesc.getValue(entity), i + 1);
                  } else {
                      if(logger.isWarnEnabled()) {
                          logger.warn("valueType for " + propertType.getName() + " not found.");
                      }
                  }
              }
          }
      }
docs: Sets parameters to the PreparedStatement.
  
  @param stmt the prepared statement
  @param propDescs the property descriptors
  @param entity the entity
  
  @throws SQLException if something goes wrong