commons-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From t.@apache.org
Subject svn commit: r1361597 - /commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/
Date Sat, 14 Jul 2012 22:13:12 GMT
Author: tn
Date: Sat Jul 14 22:13:11 2012
New Revision: 1361597

URL: http://svn.apache.org/viewvc?rev=1361597&view=rev
Log:
Cleanup of list package.

Added:
    commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/package-info.java
      - copied, changed from r1356960, commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/package.html
Removed:
    commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/package.html
Modified:
    commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/AbstractLinkedList.java
    commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/AbstractListDecorator.java
    commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/AbstractSerializableListDecorator.java
    commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/CursorableLinkedList.java
    commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/FixedSizeList.java
    commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/GrowthList.java
    commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/LazyList.java
    commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/NodeCachingLinkedList.java
    commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/PredicatedList.java
    commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/SetUniqueList.java
    commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/SynchronizedList.java
    commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/TransformedList.java
    commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/TreeList.java
    commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/UnmodifiableList.java

Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/AbstractLinkedList.java
URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/AbstractLinkedList.java?rev=1361597&r1=1361596&r2=1361597&view=diff
==============================================================================
--- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/AbstractLinkedList.java
(original)
+++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/AbstractLinkedList.java
Sat Jul 14 22:13:11 2012
@@ -39,11 +39,7 @@ import org.apache.commons.collections.Or
  * is here.
  *
  * @since Commons Collections 3.0
- * @version $Revision$
- *
- * @author Rich Dougherty
- * @author Phil Steitz
- * @author Stephen Colebourne
+ * @version $Id$
  */
 public abstract class AbstractLinkedList<E> implements List<E> {
 

Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/AbstractListDecorator.java
URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/AbstractListDecorator.java?rev=1361597&r1=1361596&r2=1361597&view=diff
==============================================================================
--- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/AbstractListDecorator.java
(original)
+++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/AbstractListDecorator.java
Sat Jul 14 22:13:11 2012
@@ -23,18 +23,16 @@ import java.util.ListIterator;
 import org.apache.commons.collections.collection.AbstractCollectionDecorator;
 
 /**
- * Decorates another <code>List</code> to provide additional behaviour.
+ * Decorates another {@link List} to provide additional behaviour.
  * <p>
  * Methods are forwarded directly to the decorated list.
  *
  * @param <E> the type of the elements in the list
  * @since Commons Collections 3.0
- * @version $Revision$
- *
- * @author Stephen Colebourne
+ * @version $Id$
  */
-public abstract class AbstractListDecorator<E> extends AbstractCollectionDecorator<E>
implements
-        List<E> {
+public abstract class AbstractListDecorator<E> extends AbstractCollectionDecorator<E>
+        implements List<E> {
 
     /** Serialization version--necessary in an abstract class? */
     private static final long serialVersionUID = 4500739654952315623L;

Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/AbstractSerializableListDecorator.java
URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/AbstractSerializableListDecorator.java?rev=1361597&r1=1361596&r2=1361597&view=diff
==============================================================================
--- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/AbstractSerializableListDecorator.java
(original)
+++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/AbstractSerializableListDecorator.java
Sat Jul 14 22:13:11 2012
@@ -26,8 +26,8 @@ import java.util.List;
 /**
  * Serializable subclass of AbstractListDecorator.
  *
- * @author Stephen Colebourne
  * @since Commons Collections 3.1
+ * @version $Id$
  */
 public abstract class AbstractSerializableListDecorator<E>
         extends AbstractListDecorator<E>
@@ -37,7 +37,10 @@ public abstract class AbstractSerializab
     private static final long serialVersionUID = 2684959196747496299L;
 
     /**
-     * Constructor.
+     * Constructor that wraps (not copies).
+     *
+     * @param list  the list to decorate, must not be null
+     * @throws IllegalArgumentException if list is null
      */
     protected AbstractSerializableListDecorator(List<E> list) {
         super(list);

Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/CursorableLinkedList.java
URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/CursorableLinkedList.java?rev=1361597&r1=1361596&r2=1361597&view=diff
==============================================================================
--- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/CursorableLinkedList.java
(original)
+++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/CursorableLinkedList.java
Sat Jul 14 22:13:11 2012
@@ -53,12 +53,7 @@ import java.util.ListIterator;
  *
  * @see java.util.LinkedList
  * @since Commons Collections 1.0
- * @version $Revision$
- *
- * @author Rodney Waldhoff
- * @author Janek Bogucki
- * @author Simon Kitching
- * @author Stephen Colebourne
+ * @version $Id$
  */
 public class CursorableLinkedList<E> extends AbstractLinkedList<E> implements
Serializable {
 

Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/FixedSizeList.java
URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/FixedSizeList.java?rev=1361597&r1=1361596&r2=1361597&view=diff
==============================================================================
--- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/FixedSizeList.java
(original)
+++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/FixedSizeList.java
Sat Jul 14 22:13:11 2012
@@ -34,10 +34,7 @@ import org.apache.commons.collections.it
  * This class is Serializable from Commons Collections 3.1.
  *
  * @since Commons Collections 3.0
- * @version $Revision$
- *
- * @author Stephen Colebourne
- * @author Paul Jack
+ * @version $Id$
  */
 public class FixedSizeList<E>
         extends AbstractSerializableListDecorator<E>

Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/GrowthList.java
URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/GrowthList.java?rev=1361597&r1=1361596&r2=1361597&view=diff
==============================================================================
--- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/GrowthList.java
(original)
+++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/GrowthList.java
Sat Jul 14 22:13:11 2012
@@ -50,10 +50,7 @@ import java.util.List;
  *
  * @see LazyList
  * @since Commons Collections 3.2
- * @version $Revision$
- *
- * @author Stephen Colebourne
- * @author Paul Legato
+ * @version $Id$
  */
 public class GrowthList<E> extends AbstractSerializableListDecorator<E> {
 

Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/LazyList.java
URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/LazyList.java?rev=1361597&r1=1361596&r2=1361597&view=diff
==============================================================================
--- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/LazyList.java
(original)
+++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/LazyList.java
Sat Jul 14 22:13:11 2012
@@ -33,16 +33,16 @@ import org.apache.commons.collections.Fa
  * For instance:
  *
  * <pre>
- * Factory factory = new Factory() {
- *     public Object create() {
+ * Factory&lt;Date&gt; factory = new Factory&lt;Date&gt;() {
+ *     public Date create() {
  *         return new Date();
  *     }
  * }
- * List lazy = LazyList.decorate(new ArrayList(), factory);
- * Object obj = lazy.get(3);
+ * List&lt;Date&gt; lazy = LazyList.decorate(new ArrayList&lt;Date&gt;(),
factory);
+ * Date date = lazy.get(3);
  * </pre>
  *
- * After the above code is executed, <code>obj</code> will contain
+ * After the above code is executed, <code>date</code> will contain
  * a new <code>Date</code> instance.  Furthermore, that <code>Date</code>
  * instance is the fourth element in the list.  The first, second, 
  * and third element are all set to <code>null</code>.
@@ -55,11 +55,7 @@ import org.apache.commons.collections.Fa
  *
  * @see GrowthList
  * @since Commons Collections 3.0
- * @version $Revision$
- *
- * @author Stephen Colebourne
- * @author Arron Bates
- * @author Paul Jack
+ * @version $Id$
  */
 public class LazyList<E> extends AbstractSerializableListDecorator<E> {
 
@@ -108,7 +104,6 @@ public class LazyList<E> extends Abstrac
      * placeholder that is replaced with a factory object when requested.
      * 
      * @param index  the index to retrieve
-     * {@inheritDoc}
      */
     @Override
     public E get(int index) {

Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/NodeCachingLinkedList.java
URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/NodeCachingLinkedList.java?rev=1361597&r1=1361596&r2=1361597&view=diff
==============================================================================
--- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/NodeCachingLinkedList.java
(original)
+++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/NodeCachingLinkedList.java
Sat Jul 14 22:13:11 2012
@@ -37,12 +37,7 @@ import java.util.Collection;
  * <b>Note that this implementation is not synchronized.</b>
  *
  * @since Commons Collections 3.0
- * @version $Revision$
- *
- * @author Jeff Varszegi
- * @author Rich Dougherty
- * @author Phil Steitz
- * @author Stephen Colebourne
+ * @version $Id$
  */
 public class NodeCachingLinkedList<E> extends AbstractLinkedList<E> implements
Serializable {
 

Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/PredicatedList.java
URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/PredicatedList.java?rev=1361597&r1=1361596&r2=1361597&view=diff
==============================================================================
--- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/PredicatedList.java
(original)
+++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/PredicatedList.java
Sat Jul 14 22:13:11 2012
@@ -38,10 +38,7 @@ import java.util.ListIterator;
  * This class is Serializable from Commons Collections 3.1.
  *
  * @since Commons Collections 3.0
- * @version $Revision$
- *
- * @author Stephen Colebourne
- * @author Paul Jack
+ * @version $Id$
  */
 public class PredicatedList<E> extends PredicatedCollection<E> implements List<E>
{
 

Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/SetUniqueList.java
URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/SetUniqueList.java?rev=1361597&r1=1361596&r2=1361597&view=diff
==============================================================================
--- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/SetUniqueList.java
(original)
+++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/SetUniqueList.java
Sat Jul 14 22:13:11 2012
@@ -45,11 +45,7 @@ import org.apache.commons.collections.se
  * This class is Serializable from Commons Collections 3.1.
  *
  * @since Commons Collections 3.0
- * @version $Revision$
- *
- * @author Matthew Hawthorne
- * @author Stephen Colebourne
- * @author Tom Dunham
+ * @version $Id$
  */
 public class SetUniqueList<E> extends AbstractSerializableListDecorator<E> {
 

Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/SynchronizedList.java
URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/SynchronizedList.java?rev=1361597&r1=1361596&r2=1361597&view=diff
==============================================================================
--- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/SynchronizedList.java
(original)
+++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/SynchronizedList.java
Sat Jul 14 22:13:11 2012
@@ -31,9 +31,7 @@ import org.apache.commons.collections.co
  * This class is Serializable from Commons Collections 3.1.
  *
  * @since Commons Collections 3.0
- * @version $Revision$
- *
- * @author Stephen Colebourne
+ * @version $Id$
  */
 public class SynchronizedList<E> extends SynchronizedCollection<E> implements
List<E> {
 

Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/TransformedList.java
URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/TransformedList.java?rev=1361597&r1=1361596&r2=1361597&view=diff
==============================================================================
--- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/TransformedList.java
(original)
+++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/TransformedList.java
Sat Jul 14 22:13:11 2012
@@ -35,9 +35,7 @@ import org.apache.commons.collections.it
  * This class is Serializable from Commons Collections 3.1.
  *
  * @since Commons Collections 3.0
- * @version $Revision$
- *
- * @author Stephen Colebourne
+ * @version $Id$
  */
 public class TransformedList<E> extends TransformedCollection<E> implements List<E>
{
 

Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/TreeList.java
URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/TreeList.java?rev=1361597&r1=1361596&r2=1361597&view=diff
==============================================================================
--- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/TreeList.java
(original)
+++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/TreeList.java
Sat Jul 14 22:13:11 2012
@@ -51,10 +51,7 @@ import org.apache.commons.collections.Or
  * does use slightly more memory.
  *
  * @since Commons Collections 3.1
- * @version $Revision$
- *
- * @author Joerg Schmuecker
- * @author Stephen Colebourne
+ * @version $Id$
  */
 public class TreeList<E> extends AbstractList<E> {
 //    add; toArray; iterator; insert; get; indexOf; remove

Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/UnmodifiableList.java
URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/UnmodifiableList.java?rev=1361597&r1=1361596&r2=1361597&view=diff
==============================================================================
--- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/UnmodifiableList.java
(original)
+++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/UnmodifiableList.java
Sat Jul 14 22:13:11 2012
@@ -33,9 +33,7 @@ import org.apache.commons.collections.it
  * Attempts to modify it will result in an UnsupportedOperationException. 
  *
  * @since Commons Collections 3.0
- * @version $Revision$
- *
- * @author Stephen Colebourne
+ * @version $Id$
  */
 public final class UnmodifiableList<E>
         extends AbstractSerializableListDecorator<E>

Copied: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/package-info.java
(from r1356960, commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/package.html)
URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/package-info.java?p2=commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/package-info.java&p1=commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/package.html&r1=1356960&r2=1361597&rev=1361597&view=diff
==============================================================================
--- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/package.html
(original)
+++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections/list/package-info.java
Sat Jul 14 22:13:11 2012
@@ -1,45 +1,42 @@
-<!-- $Id$ -->
- <!--
-   Licensed to the Apache Software Foundation (ASF) under one or more
-  contributor license agreements.  See the NOTICE file distributed with
-  this work for additional information regarding copyright ownership.
-  The ASF licenses this file to You under the Apache License, Version 2.0
-  (the "License"); you may not use this file except in compliance with
-  the License.  You may obtain a copy of the License at
-
-       http://www.apache.org/licenses/LICENSE-2.0
-
-   Unless required by applicable law or agreed to in writing, software
-   distributed under the License is distributed on an "AS IS" BASIS,
-   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-   See the License for the specific language governing permissions and
-   limitations under the License.
-  -->
-<BODY>
-<p>
-This package contains implementations of the
-{@link java.util.List List} interface.
-</p>
-<p>
-The following implementations are provided in the package:
-<ul>
-<li>TreeList - a list that is optimised for insertions and removals at any index in
the list</li>
-<li>CursorableLinkedList - a list that can be modified while the listIterator (cursor)
is being used</li>
-<li>NodeCachingLinkedList - a linked list that caches the storage nodes for a performance
gain</li>
-</ul>
-</p>
-<p>
-The following decorators are provided in the package:
-<ul>
-<li>Synchronized - synchronizes method access for multi-threaded environments</li>
-<li>Unmodifiable - ensures the collection cannot be altered</li>
-<li>Predicated - ensures that only elements that are valid according to a predicate
can be added</li>
-<li>Typed - ensures that only elements that are of a specific type can be added</li>
-<li>Transformed - transforms each element added</li>
-<li>FixedSize - ensures that the size of the list cannot change</li>
-<li>Lazy - creates objects in the list on demand</li>
-<li>Growth - grows the list instead of erroring when set/add used with index beyond
the list size</li>
-<li>SetUnique - a list that avoids duplicate entries like a Set</li>
-</ul>
-</p>
-</BODY>
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+/**
+ * This package contains implementations of the {@link java.util.List List} interface.
+ * <p>
+ * The following implementations are provided in the package:
+ * <ul>
+ *   <li>TreeList - a list that is optimised for insertions and removals at any index
in the list</li>
+ *   <li>CursorableLinkedList - a list that can be modified while the listIterator
(cursor) is being used</li>
+ *   <li>NodeCachingLinkedList - a linked list that caches the storage nodes for a
performance gain</li>
+ * </ul>
+ * <p>
+ * The following decorators are provided in the package:
+ * <ul>
+ *   <li>Synchronized - synchronizes method access for multi-threaded environments</li>
+ *   <li>Unmodifiable - ensures the collection cannot be altered</li>
+ *   <li>Predicated - ensures that only elements that are valid according to a predicate
can be added</li>
+ *   <li>Typed - ensures that only elements that are of a specific type can be added</li>
+ *   <li>Transformed - transforms each element added</li>
+ *   <li>FixedSize - ensures that the size of the list cannot change</li>
+ *   <li>Lazy - creates objects in the list on demand</li>
+ *   <li>Growth - grows the list instead of erroring when set/add used with index beyond
the list size</li>
+ *   <li>SetUnique - a list that avoids duplicate entries like a Set</li>
+ * </ul>
+ *
+ * @version $Id$
+ */
+package org.apache.commons.collections.list;



Mime
View raw message