class CollectionUtils {
    /** Class can't be constructed. */
    private CollectionUtils() {
        // Empty
    }

    /**
     * Sort a collection if it is not empty (to prevent {@link ConcurrentModificationException} if an immutable
     * empty list that has been returned more than once is being sorted in one thread and iterated through in
     * another thread -- #334).
     *
     * @param <T>
     *            the element type
     * @param list
     *            the list
     */
    public static <T extends Comparable<? super T>> void sortIfNotEmpty(final List<T> list) {
        if (list.size() > 1) {
            Collections.sort(list);
        }
    }

    /**
     * Sort a collection if it is not empty (to prevent {@link ConcurrentModificationException} if an immutable
     * empty list that has been returned more than once is being sorted in one thread and iterated through in
     * another thread -- #334).
     *
     * @param <T>
     *            the element type
     * @param list
     *            the list
     * @param comparator
     *            the comparator
     */
    public static <T> void sortIfNotEmpty(final List<T> list, final Comparator<? super T> comparator) {
        if (list.size() > 1) {
            Collections.sort(list, comparator);
        }
    }

    /**
     * Copy and sort a collection.
     *
     * @param elts
     *            the collection to copy and sort
     * @return a sorted copy of the collection
     */
    public static <T extends Comparable<T>> List<T> sortCopy(final Collection<T> elts) {<FILL_FUNCTION_BODY>}
}

        final List<T> sortedCopy = new ArrayList<>(elts);
        if (sortedCopy.size() > 1) {
            Collections.sort(sortedCopy);
        }
        return sortedCopy;
    
<no_super_class>