Java List Sort sortList(java.util.List types)

Here you can find the source of sortList(java.util.List types)

Description

sort List

License

Open Source License

Declaration

public static java.util.List sortList(java.util.List types) 

Method Source Code

//package com.java2s;
/*******************************************************************************
 * Copyright (c) 2001, 2007 IBM Corporation and others.
 * All rights reserved. This program and the accompanying materials
 * are made available under the terms of the Eclipse Public License v1.0
 * which accompanies this distribution, and is available at
 * http://www.eclipse.org/legal/epl-v10.html
 * /*  w  ww  .ja v  a  2  s.  co m*/
 * Contributors:
 *     IBM Corporation - initial API and implementation
 *******************************************************************************/

public class Main {
    public static java.util.List sortList(java.util.List types) {
        try {
            java.util.Collections.sort(types); // performance?  n*log(n)
        } catch (Exception e) {
            //      XSDEditorPlugin.getPlugin().getMsgLogger().write("Sort failed");
        }
        return types;
    }
}

Related

  1. sortIfUnsorted(List genomes)
  2. sortInputQueryKeys(List l)
  3. sortItems(List items, String putOnTop)
  4. sortList(ArrayList list)
  5. sortList(Collection list)
  6. sortList(List list)
  7. sortList(List items)
  8. sortList(List list, boolean asc)
  9. sortListAlphabetically(List list)