code: public static <T> List<DialogResponse<T>> toResponseList(T[] responses, T[] exclusions, T dflt) {
          List<DialogResponse<T>> list = new ArrayList<>();
          boolean forceDefault = dflt == null && responses.length == 1;
  
          for (T response : responses) {
              DialogResponse<T> rsp = new DialogResponse<>(response, response.toString(),
                      exclusions != null && ArrayUtils.contains(exclusions, response), forceDefault || response.equals(dflt));
              list.add(rsp);
          }
  
          return list;
      }
docs: Returns list of response objects created from a string of vertical bar delimited captions.
  
  @param <T> The type of response object.
  @param responses Response list.
  @param exclusions Exclusion list (may be null).
  @param dflt Default response (may be null).
  @return List of response objects corresponding to response list.