code: private List<String> convertObjectToListOfStringValues(Object value) {
          if (value != null) {
              List<String> valueList = new ArrayList<>();
              if (value instanceof Collection) {
                  Collection valueCollection = (Collection) value;
                  for (Object val : valueCollection) {
                      if (val == null) {
                          valueList.add(null);
                      } else {
                          valueList.add(val.toString());
                      }
                  }
  
              } else if (value instanceof Object[]) {
                  Object[] valueArray = (Object[]) value;
                  for (Object val : valueArray) {
                      if (val == null) {
                          valueList.add(null);
                      } else {
                          valueList.add(val.toString());
                      }
                  }
              } else {
                  valueList.add(value.toString());
              }
  
              return valueList;
          } else {
              return null;
          }
      }
docs: Converts any input object to a list of string values. If the input object is a collection or an array, then each element in the input is treated as a separate object to be added to the result.
  In any other case, simple {@code toString()} method of the object is used.
  
  @param value Input object
  @return List of string values