Back to project page Muse.
The source code is released under:
Apache License
If you think the Android project Muse listed in this page is inappropriate, such as containing malicious code/tools or violating the copyright, please email info at java2s dot com, thanks.
package com.prt2121.muse; //w w w .j av a2 s. c o m import java.util.ArrayList; import java.util.Collections; import java.util.LinkedList; /** * Provides static methods for creating {@code List} instances easily, and other * utility methods for working with lists. */ public final class Lists { /** This class is never instantiated */ public Lists() { } /** * Creates an empty {@code ArrayList} instance. * <p> * <b>Note:</b> if you only need an <i>immutable</i> empty List, use * {@link Collections#emptyList} instead. * * @return a newly-created, initially-empty {@code ArrayList} */ public static final <E> ArrayList<E> newArrayList() { return new ArrayList<E>(); } /** * Creates an empty {@code LinkedList} instance. * <p> * <b>Note:</b> if you only need an <i>immutable</i> empty List, use * {@link Collections#emptyList} instead. * * @return a newly-created, initially-empty {@code LinkedList} */ public static final <E> LinkedList<E> newLinkedList() { return new LinkedList<E>(); } }