Updated javadoc

This commit is contained in:
Klemek
2019-01-20 15:10:49 +01:00
parent 58c14039a4
commit 489068049e
6 changed files with 28 additions and 10 deletions
@@ -19,7 +19,9 @@ public class BetterArrayList<T> extends ArrayList<T> implements BetterList<T> {
* Constructs a list containing the elements of the specified collection, in the
* order they are returned by the collection's iterator.
*
* @param <T> - the type of List
* @param c - the collection whose elements are to be placed into this list
* @return the constructed list
*/
public static <T> BetterArrayList<T> fromList(Collection<T> c) {
return new BetterArrayList<>(c);
@@ -28,7 +30,9 @@ public class BetterArrayList<T> extends ArrayList<T> implements BetterList<T> {
/**
* Constructs a list containing the elements given in argument.
*
* @param <T> - the type of List
* @param a - the elements to be placed into this list
* @return the constructed list
*/
public static <T> BetterArrayList<T> asList(T... a) {
return new BetterArrayList<>(a);
@@ -83,8 +87,8 @@ public class BetterArrayList<T> extends ArrayList<T> implements BetterList<T> {
* @param fromIndex - low endpoint (inclusive) of the subList
* @param toIndex - high endpoint (exclusive) of the subList
* @return a view of the specified range within this list
* @throws IndexOutOfBoundsException for an illegal endpoint index value (fromIndex < 0 || toIndex >
* size || fromIndex > toIndex)
* @throws IndexOutOfBoundsException for an illegal endpoint index value (fromIndex &lt; 0 || toIndex &gt;
* size || fromIndex &gt; toIndex)
* @see java.util.List
*/
@Override
@@ -20,7 +20,9 @@ public class BetterCopyOnWriteArrayList<T> extends CopyOnWriteArrayList<T> imple
* Constructs a list containing the elements of the specified collection, in the
* order they are returned by the collection's iterator.
*
* @param <T> - the type of List
* @param c - the collection whose elements are to be placed into this list
* @return the constructed list
*/
public static <T> BetterCopyOnWriteArrayList<T> fromList(Collection<T> c) {
return new BetterCopyOnWriteArrayList<>(c);
@@ -29,7 +31,9 @@ public class BetterCopyOnWriteArrayList<T> extends CopyOnWriteArrayList<T> imple
/**
* Constructs a list containing the elements given in argument.
*
* @param <T> - the type of List
* @param a - the elements to be placed into this list
* @return the constructed list
*/
public static <T> BetterCopyOnWriteArrayList<T> asList(T... a) {
return new BetterCopyOnWriteArrayList<>(a);
@@ -75,8 +79,8 @@ public class BetterCopyOnWriteArrayList<T> extends CopyOnWriteArrayList<T> imple
* @param fromIndex - low endpoint (inclusive) of the subList
* @param toIndex - high endpoint (exclusive) of the subList
* @return a view of the specified range within this list
* @throws IndexOutOfBoundsException for an illegal endpoint index value (fromIndex < 0 || toIndex >
* size || fromIndex > toIndex)
* @throws IndexOutOfBoundsException for an illegal endpoint index value (fromIndex &lt; 0 || toIndex &gt;
* size || fromIndex &gt; toIndex)
* @see java.util.List
*/
@Override
@@ -19,7 +19,9 @@ public class BetterLinkedList<T> extends LinkedList<T> implements BetterList<T>
* Constructs a list containing the elements of the specified collection, in the
* order they are returned by the collection's iterator.
*
* @param <T> - the type of List
* @param c - the collection whose elements are to be placed into this list
* @return the constructed list
*/
public static <T> BetterLinkedList<T> fromList(Collection<T> c) {
return new BetterLinkedList<>(c);
@@ -28,7 +30,9 @@ public class BetterLinkedList<T> extends LinkedList<T> implements BetterList<T>
/**
* Constructs a list containing the elements given in argument.
*
* @param <T> - the type of List
* @param a - the elements to be placed into this list
* @return the constructed list
*/
public static <T> BetterLinkedList<T> asList(T... a) {
return new BetterLinkedList<>(a);
@@ -74,8 +78,8 @@ public class BetterLinkedList<T> extends LinkedList<T> implements BetterList<T>
* @param fromIndex - low endpoint (inclusive) of the subList
* @param toIndex - high endpoint (exclusive) of the subList
* @return a view of the specified range within this list
* @throws IndexOutOfBoundsException for an illegal endpoint index value (fromIndex < 0 || toIndex >
* size || fromIndex > toIndex)
* @throws IndexOutOfBoundsException for an illegal endpoint index value (fromIndex &lt; || toIndex &gt;
* size || fromIndex &gt; toIndex)
* @see java.util.List
*/
@Override
@@ -247,6 +247,7 @@ public interface BetterList<T> extends List<T> {
/**
* Sorts the elements of a sequence in ascending order by using a specified comparer.
*
* @param <E> The type of the projected values lists
* @param selector - A transform function to apply to each element.
* @return a List whose elements are sorted according to a key.
*/
@@ -260,6 +261,7 @@ public interface BetterList<T> extends List<T> {
/**
* Sorts the elements of a sequence in descending order by using a specified comparer.
*
* @param <E> The type of the projected values lists
* @param selector - A transform function to apply to each element.
* @return a List whose elements are sorted according to a key.
*/
@@ -34,8 +34,8 @@ public class BetterStack<T> extends Stack<T> implements BetterList<T> {
* @param fromIndex - low endpoint (inclusive) of the subList
* @param toIndex - high endpoint (exclusive) of the subList
* @return a view of the specified range within this list
* @throws IndexOutOfBoundsException for an illegal endpoint index value (fromIndex < 0 || toIndex >
* size || fromIndex > toIndex)
* @throws IndexOutOfBoundsException for an illegal endpoint index value (fromIndex &lt; || toIndex &gt;
* size || fromIndex &gt; toIndex)
* @see java.util.List
*/
@Override
@@ -19,7 +19,9 @@ public class BetterVector<T> extends Vector<T> implements BetterList<T> {
* Constructs a vector containing the elements of the specified collection, in
* the order they are returned by the collection's iterator.
*
* @param <T> - the type of List
* @param c - the collection whose elements are to be placed into this vector
* @return the constructed list
*/
public static <T> BetterVector<T> fromList(Collection<T> c) {
return new BetterVector<>(c);
@@ -28,7 +30,9 @@ public class BetterVector<T> extends Vector<T> implements BetterList<T> {
/**
* Constructs a vector containing the elements given in argument.
*
* @param <T> - the type of List
* @param a - the elements to be placed into this vector
* @return the constructed list
*/
public static <T> BetterVector<T> asVector(T... a) {
return new BetterVector<>(a);
@@ -97,8 +101,8 @@ public class BetterVector<T> extends Vector<T> implements BetterList<T> {
* @param fromIndex - low endpoint (inclusive) of the subList
* @param toIndex - high endpoint (exclusive) of the subList
* @return a view of the specified range within this list
* @throws IndexOutOfBoundsException for an illegal endpoint index value (fromIndex < 0 || toIndex >
* size || fromIndex > toIndex)
* @throws IndexOutOfBoundsException for an illegal endpoint index value (fromIndex &lt; || toIndex &gt;
* size || fromIndex &gt; toIndex)
* @see java.util.List
*/
@Override