sorts a string list

@param list list to sort
@param sortType sort type (numeric,text,textnocase)
@param sortOrder sort order (asc,desc)
@param delimiter list delimiter
@return sorted list
@throws PageException
545617
public static String sort(String list, String sortType, String sortOrder, String delimiter) throws PageException {
	return _sort(toStringArray(listToArray(list, delimiter)), sortType, sortOrder, delimiter);
    }
942829
public void sortRows(Comparator<List<String>> comparator)
	{
		if(data.isEmpty())
			return;
		
		Collections.sort(data, comparator);
	}
208570
public static <T> Stream<T> sort(Stream<T> list) {
        return list.sorted(COMPARATOR);
    }
471574
public static <E extends Comparable<E>> void sort(List<E> list) {
        Quicksort.sort(list, 0, list.size() - 1, false);
    }
12874
protected void appendSort(SolrQuery solrQuery, @Nullable Sort sort, @Nullable Class<?> domainType) {

		if (sort == null) {
			return;
		}

		for (Order order : sort) {
			solrQuery.addSort(getMappedFieldName(order.getProperty(), domainType),
					order.isAscending() ? ORDER.asc : ORDER.desc);
		}
	}
208313
public static int listFindNoCase(String list, String value, String delimiter) {
	return listFindNoCase(list, value, delimiter, true);
    }
193447
boolean handleSortOrder(final List<SortMeta> sortOrder) {
		boolean changed = false;

		if (sortOrder == null) {
			if (multiSortBy != null) {
				adaptee.clearSorting();
				multiSortBy = null;
				lastSorting = null;
				changed = true;
			}
		} else {
			final List<SortProperty> newSorting = convert2SortProperty(sortOrder);
			if (!newSorting.equals(lastSorting)) {
				adaptee.setSorting(newSorting);
				multiSortBy = sortOrder;
				lastSorting = newSorting;
				changed = true;
			}
		}

		return changed;
	}
456911
public static String arrayToList(Array array, String delimiter) throws PageException {
	if (array.size() == 0) return "";
	StringBuilder sb = new StringBuilder(Caster.toString(array.get(1, "")));
	int len = array.size();

	for (int i = 2; i <= len; i++) {
	    sb.append(delimiter);
	    sb.append(Caster.toString(array.get(i, "")));
	}
	return sb.toString();
    }
1108603
@Nonnull
    @Restricted(NoExternalUse.class)
    @SuppressWarnings("unused") // invoked from stapler view
    public List<View> sort(@Nonnull List<? extends View> views) {
        List<View> result = new ArrayList<>(views);
        result.sort(new Comparator<View>() {
            @Override
            public int compare(View o1, View o2) {
                return o1.getDisplayName().compareTo(o2.getDisplayName());
            }
        });
        return result;
    }
145222
public static <E extends Comparable<E>> void sortDescending(List<E> list) {
        Quicksort.sort(list, 0, list.size() - 1, true);
    }
883265
public static void writeToList(CodedOutputStream out, int order, FieldType type, List list) throws IOException {
        writeToList(out, order, type, list, false);
    }
310377
public static void writeToList(CodedOutputStream out, int order, FieldType type, List list) throws IOException {
        if (list == null) {
            return;
        }
        for (Object object : list) {
            writeObject(out, order, type, object, true);
        }

    }
571366
@Override
    public ListT<W,T> sorted(final Comparator<? super T> c) {

        return (ListT<W,T>) FoldableTransformerSeq.super.sorted(c);
    }
935272
public static <T> List<T> sortByProperty(List<T> list, String property) {
		return sort(list, new PropertyComparator<>(property));
	}
376897
public <T extends Comparable<T>> void sort(List<T> list)
    {
        sort(list, defaultComp);
    }
942792
public static CharSequence join(Iterable<CharSequence> list) {
        // final CharSequence delimiter = Resources.getSystem().getText(R.string.list_delimeter);
        CharSequence delimiter = ",";
        return join(delimiter, list);
    }
817275
public List<Rc> sortByTitleAndFilterDoubles(List<Rc> rcList) {
    List<Rc> result = new ArrayList<Rc>();
    List<Rc> sorted = new ArrayList<Rc>();
    sorted.addAll(rcList);
    Collections.sort(sorted, new Comparator<Rc>() {
      @Override
      public int compare(Rc lRc, Rc rRc) {
        int result = lRc.getTitle().compareTo(rRc.getTitle());
        if (result == 0) {
          result = rRc.getTimestamp().compare(lRc.getTimestamp());
        }
        return result;
      }
    });
    Rc previous = null;
    for (Rc rc : sorted) {
      if (previous == null || (!rc.getTitle().equals(previous.getTitle()))) {
        result.add(rc);
      }
      previous = rc;
    }
    Collections.sort(result, new Comparator<Rc>() {
      @Override
      public int compare(Rc lRc, Rc rRc) {
        int result = rRc.getTimestamp().compare(lRc.getTimestamp());
        return result;
      }
    });
    return result;
  }