diff --git a/src/main/java/org/apache/commons/collections4/ArrayStack.java b/src/main/java/org/apache/commons/collections4/ArrayStack.java index 2a28451353..f10f96f86c 100644 --- a/src/main/java/org/apache/commons/collections4/ArrayStack.java +++ b/src/main/java/org/apache/commons/collections4/ArrayStack.java @@ -28,7 +28,7 @@ *
* The removal order of an {@code ArrayStack} is based on insertion * order: The most recently added element is removed first. The iteration - * order is not the same as the removal order. The iterator returns + * order is not the same as the removal order. The iterator returns * elements from the bottom up. *
*diff --git a/src/main/java/org/apache/commons/collections4/Bag.java b/src/main/java/org/apache/commons/collections4/Bag.java index e86b1918c7..1869340161 100644 --- a/src/main/java/org/apache/commons/collections4/Bag.java +++ b/src/main/java/org/apache/commons/collections4/Bag.java @@ -29,8 +29,8 @@ * calling {@link #uniqueSet()} would return {@code {a, b, c}}. *
*
- * NOTE: This interface violates the {@link Collection} contract.
- * The behavior specified in many of these methods is not the same
+ * NOTE: This interface violates the {@link Collection} contract.
+ * The behavior specified in many of these methods is not the same
* as the behavior specified by {@code Collection}.
* The non-compliant methods are clearly marked with "(Violation)".
* Exercise caution when using a bag as a {@code Collection}.
@@ -47,7 +47,7 @@
public interface Bag
* If the object is already in the {@link #uniqueSet()} then increment its
@@ -82,7 +82,7 @@ public interface Bag
* The {@link Collection#containsAll(Collection)} method specifies
- * that cardinality should not be respected; this method should
+ * that cardinality should not be respected; this method should
* return true if the bag contains at least one of every object contained
* in the given collection.
*
* This will also remove the object from the {@link #uniqueSet()}.
*
* According to the {@link Collection#remove(Object)} method,
- * this method should only remove the first occurrence of the
- * given object, not all occurrences.
+ * this method should only remove the first occurrence of the
+ * given object, not all occurrences.
*
* The {@link Collection#removeAll(Collection)} method specifies
- * that cardinality should not be respected; this method should
- * remove all occurrences of every object contained in the
+ * that cardinality should not be respected; this method should
+ * remove all occurrences of every object contained in the
* given collection.
*
* The {@link Collection#retainAll(Collection)} method specifies
- * that cardinality should not be respected; this method should
- * keep all occurrences of every object contained in the
+ * that cardinality should not be respected; this method should
+ * keep all occurrences of every object contained in the
* given collection.
*
* In other words, this method returns {@code true} iff the
- * {@link #intersection} of coll1 and coll2 has the same cardinality as
+ * {@link #intersection} of coll1 and coll2 has the same cardinality as
* the set of unique values from {@code coll2}. In case {@code coll2} is empty, {@code true}
* will be returned.
*
* In other words, this method returns {@code true} iff the
- * {@link #intersection} of coll1 and coll2 is not empty.
+ * {@link #intersection} of coll1 and coll2 is not empty.
*
* In other words, this method returns {@code true} iff the
- * {@link #intersection} of coll1 and coll2 is not empty.
+ * {@link #intersection} of coll1 and coll2 is not empty.
*
- * The cardinality of each element e in the returned
+ * The cardinality of each element e in the returned
* {@link Collection} will be equal to
- *
* This is equivalent to
@@ -1189,9 +1189,9 @@ public static boolean isEmpty(final Collection> coll) {
* Returns {@code true} iff the given {@link Collection}s contain
* exactly the same elements with exactly the same cardinalities.
*
- * That is, iff the cardinality of e in a is
- * equal to the cardinality of e in b,
- * for each element e in a or b.
+ * That is, iff the cardinality of e in a is
+ * equal to the cardinality of e in b,
+ * for each element e in a or b.
*
- * That is, iff the cardinality of e in a is
- * equal to the cardinality of e in b,
- * for each element e in a or b.
+ * That is, iff the cardinality of e in a is
+ * equal to the cardinality of e in b,
+ * for each element e in a or b.
*
* Note: from version 4.1 onwards this method requires the input
@@ -1303,24 +1303,24 @@ public static boolean isNotEmpty(final Collection> coll) {
}
/**
- * Returns {@code true} iff a is a proper sub-collection of b,
- * that is, iff the cardinality of e in a is less
- * than or equal to the cardinality of e in b,
- * for each element e in a, and there is at least one
- * element f such that the cardinality of f in b
- * is strictly greater than the cardinality of f in a.
+ * Returns {@code true} iff a is a proper sub-collection of b,
+ * that is, iff the cardinality of e in a is less
+ * than or equal to the cardinality of e in b,
+ * for each element e in a, and there is at least one
+ * element f such that the cardinality of f in b
+ * is strictly greater than the cardinality of f in a.
*
* The implementation assumes
*
- * The cardinality of each element e in the returned {@link Collection}
- * that satisfies the predicate condition will be the cardinality of e in a
- * minus the cardinality of e in b, or zero, whichever is greater.
+ * The cardinality of each element e in the returned {@link Collection}
+ * that satisfies the predicate condition will be the cardinality of e in a
+ * minus the cardinality of e in b, or zero, whichever is greater.
*
- * The cardinality of each element e in the returned {@link Collection} that does not
- * satisfy the predicate condition will be equal to the cardinality of e in a.
+ * The cardinality of each element e in the returned {@link Collection} that does not
+ * satisfy the predicate condition will be equal to the cardinality of e in a.
*
- * The returned list may be modifiable, but updates will not be
+ * The returned list may be modifiable, but updates will not be
* propagated to this list-valued map. In case no mapping was stored for the
* specified key, an empty, unmodifiable list will be returned.
*
diff --git a/src/main/java/org/apache/commons/collections4/MultiValuedMap.java b/src/main/java/org/apache/commons/collections4/MultiValuedMap.java
index 1e0c1cf603..5b1d6268e4 100644
--- a/src/main/java/org/apache/commons/collections4/MultiValuedMap.java
+++ b/src/main/java/org/apache/commons/collections4/MultiValuedMap.java
@@ -286,7 +286,7 @@ public interface MultiValuedMap
- * The returned collection may be modifiable, but updates will not be propagated
+ * The returned collection may be modifiable, but updates will not be propagated
* to this multivalued map. In case no mapping was stored for the specified
* key, an empty, unmodifiable collection will be returned.
*
- * The returned set may be modifiable, but updates will not be
+ * The returned set may be modifiable, but updates will not be
* propagated to this set-valued map. In case no mapping was stored for the
* specified key, an empty, unmodifiable set will be returned.
*
* Since this method always increases the size of the bag, it
@@ -82,7 +82,7 @@ public boolean add(final E object) {
}
/**
- * (Change)
+ * (Change)
* Adds {@code count} copies of the specified object to the Bag.
*
* Since this method always increases the size of the bag, it
@@ -111,7 +111,7 @@ public boolean addAll(final Collection extends E> coll) {
}
/**
- * (Change)
+ * (Change)
* Returns {@code true} if the bag contains all elements in
* the given collection, not respecting cardinality. That is,
* if the given collection {@code coll} contains at least one of
@@ -140,7 +140,7 @@ private void readObject(final ObjectInputStream in) throws IOException, ClassNot
}
/**
- * (Change)
+ * (Change)
* Removes the first occurrence of the given object from the bag.
*
* This will also remove the object from the {@link #uniqueSet()} if the
@@ -155,9 +155,9 @@ public boolean remove(final Object object) {
}
/**
- * (Change)
+ * (Change)
* Remove all elements represented in the given collection,
- * not respecting cardinality. That is, remove all
+ * not respecting cardinality. That is, remove all
* occurrences of every object contained in the given collection.
*
* @param coll the collection to remove
@@ -178,9 +178,9 @@ public boolean removeAll(final Collection> coll) {
}
/**
- * (Change)
+ * (Change)
* Remove any members of the bag that are not in the given collection,
- * not respecting cardinality. That is, any object in the given
+ * not respecting cardinality. That is, any object in the given
* collection {@code coll} will be retained in the bag with the same
* number of copies prior to this operation. All other objects will be
* completely removed from this bag.
diff --git a/src/main/java/org/apache/commons/collections4/collection/CompositeCollection.java b/src/main/java/org/apache/commons/collections4/collection/CompositeCollection.java
index 0442dd8172..a24dacda31 100644
--- a/src/main/java/org/apache/commons/collections4/collection/CompositeCollection.java
+++ b/src/main/java/org/apache/commons/collections4/collection/CompositeCollection.java
@@ -499,7 +499,7 @@ public
* Clients are encouraged to use the value returned from
* this method instead of constructing a new instance
@@ -112,8 +112,8 @@ public BooleanComparator() {
/**
* Creates a {@code BooleanComparator} that sorts
- * {@code trueFirst} values before
- * {@code !trueFirst} values.
+ * {@code trueFirst} values before
+ * {@code !trueFirst} values.
*
* Please use the static factories instead whenever possible.
*
@@ -142,12 +142,12 @@ public int compare(final Boolean b1, final Boolean b2) {
}
/**
- * Returns {@code true} iff that Object is
+ * Returns {@code true} iff that Object is
* a {@link Comparator} whose ordering is known to be
* equivalent to mine.
*
* This implementation returns {@code true}
- * iff {@code that} is a {@link BooleanComparator}
+ * iff {@code that} is a {@link BooleanComparator}
* whose value of {@link #sortsTrueFirst()} is equal to mine.
*
* @param object the object to compare to
diff --git a/src/main/java/org/apache/commons/collections4/comparators/ComparableComparator.java b/src/main/java/org/apache/commons/collections4/comparators/ComparableComparator.java
index fcd03fb782..2e0a109cc0 100644
--- a/src/main/java/org/apache/commons/collections4/comparators/ComparableComparator.java
+++ b/src/main/java/org/apache/commons/collections4/comparators/ComparableComparator.java
@@ -82,9 +82,9 @@ public ComparableComparator() {
* @param obj1 the first object to compare
* @param obj2 the second object to compare
* @return negative if obj1 is less, positive if greater, zero if equal
- * @throws NullPointerException if obj1 is {@code null},
+ * @throws NullPointerException if obj1 is {@code null},
* or when {@code ((Comparable)obj1).compareTo(obj2)} does
- * @throws ClassCastException if obj1 is not a {@code Comparable},
+ * @throws ClassCastException if obj1 is not a {@code Comparable},
* or when {@code ((Comparable)obj1).compareTo(obj2)} does
*/
@Override
@@ -93,11 +93,11 @@ public int compare(final E obj1, final E obj2) {
}
/**
- * Returns {@code true} iff that Object is a {@link Comparator Comparator}
+ * Returns {@code true} iff that Object is a {@link Comparator Comparator}
* whose ordering is known to be equivalent to mine.
*
* This implementation returns {@code true} iff
- * {@code object.{@link Object#getClass() getClass()}} equals
+ * {@code object.{@link Object#getClass() getClass()}} equals
* {@code this.getClass()}. Subclasses may want to override this behavior to remain
* consistent with the {@link Comparator#equals(Object)} contract.
*
diff --git a/src/main/java/org/apache/commons/collections4/comparators/ComparatorChain.java b/src/main/java/org/apache/commons/collections4/comparators/ComparatorChain.java
index 37db15cb4a..947eec6330 100644
--- a/src/main/java/org/apache/commons/collections4/comparators/ComparatorChain.java
+++ b/src/main/java/org/apache/commons/collections4/comparators/ComparatorChain.java
@@ -38,13 +38,13 @@
*
* Calling a method that adds new Comparators or changes the ascend/descend sort
- * after compare(Object, Object) has been called will result in an
- * UnsupportedOperationException. However, take care to not alter the
+ * after compare(Object, Object) has been called will result in an
+ * UnsupportedOperationException. However, take care to not alter the
* underlying List of Comparators or the BitSet that defines the sort order.
*
* Instances of ComparatorChain are not synchronized. The class is not
- * thread-safe at construction time, but it is thread-safe to perform
+ * thread-safe at construction time, but it is thread-safe to perform
* multiple comparisons after all the setup operations are complete.
*
* This implementation returns {@code true}
- * iff {@code object.{@link Object#getClass() getClass()}}
+ * iff {@code object.{@link Object#getClass() getClass()}}
* equals {@code this.getClass()}, and the underlying
* comparators and order bits are equal.
* Subclasses may want to override this behavior to remain consistent
diff --git a/src/main/java/org/apache/commons/collections4/comparators/ReverseComparator.java b/src/main/java/org/apache/commons/collections4/comparators/ReverseComparator.java
index 3ae2db6a47..3066c70d47 100644
--- a/src/main/java/org/apache/commons/collections4/comparators/ReverseComparator.java
+++ b/src/main/java/org/apache/commons/collections4/comparators/ReverseComparator.java
@@ -75,12 +75,12 @@ public int compare(final E obj1, final E obj2) {
}
/**
- * Returns {@code true} iff that Object is
+ * Returns {@code true} iff that Object is
* a {@link Comparator} whose ordering is known to be
* equivalent to mine.
*
* This implementation returns {@code true}
- * iff {@code object.{@link Object#getClass() getClass()}}
+ * iff {@code object.{@link Object#getClass() getClass()}}
* equals {@code this.getClass()}, and the underlying
* comparators are equal.
* Subclasses may want to override this behavior to remain consistent
diff --git a/src/main/java/org/apache/commons/collections4/comparators/TransformingComparator.java b/src/main/java/org/apache/commons/collections4/comparators/TransformingComparator.java
index b8dbe4f0ec..5d6b180275 100644
--- a/src/main/java/org/apache/commons/collections4/comparators/TransformingComparator.java
+++ b/src/main/java/org/apache/commons/collections4/comparators/TransformingComparator.java
@@ -87,12 +87,12 @@ public int compare(final I obj1, final I obj2) {
}
/**
- * Returns {@code true} iff that Object is
+ * Returns {@code true} iff that Object is
* a {@link Comparator} whose ordering is known to be
* equivalent to mine.
*
* This implementation returns {@code true}
- * iff {@code that} is a {@link TransformingComparator}
+ * iff {@code that} is a {@link TransformingComparator}
* whose attributes are equal to mine.
*
* @param object the object to compare to
diff --git a/src/main/java/org/apache/commons/collections4/iterators/CollatingIterator.java b/src/main/java/org/apache/commons/collections4/iterators/CollatingIterator.java
index 59dc9cb11c..2e1c12901c 100644
--- a/src/main/java/org/apache/commons/collections4/iterators/CollatingIterator.java
+++ b/src/main/java/org/apache/commons/collections4/iterators/CollatingIterator.java
@@ -204,7 +204,7 @@ private void checkNotStarted() throws IllegalStateException {
/**
* Clears the {@link #values} and {@link #valueSet} attributes at position
- * i.
+ * i.
*/
private void clear(final int i) {
values.set(i, null);
@@ -321,8 +321,8 @@ public void remove() {
/**
* Sets the {@link #values} and {@link #valueSet} attributes at position
- * i to the next value of the {@link #iterators iterator} at position
- * i, or clear them if the ith iterator has no next
+ * i to the next value of the {@link #iterators iterator} at position
+ * i, or clear them if the ith iterator has no next
* value.
*
* @return {@code false} iff there was no value to set
diff --git a/src/main/java/org/apache/commons/collections4/list/CursorableLinkedList.java b/src/main/java/org/apache/commons/collections4/list/CursorableLinkedList.java
index 285098ff7c..5b646c1a16 100644
--- a/src/main/java/org/apache/commons/collections4/list/CursorableLinkedList.java
+++ b/src/main/java/org/apache/commons/collections4/list/CursorableLinkedList.java
@@ -122,7 +122,7 @@ protected void checkModCount() {
* Mark this cursor as no longer being needed. Any resources
* associated with this cursor are immediately released.
* In previous versions of this class, it was mandatory to close
- * all cursor objects to avoid memory leaks. It is no longer
+ * all cursor objects to avoid memory leaks. It is no longer
* necessary to call this close method; an instance of this class
* can now be treated exactly like a normal iterator.
*/
diff --git a/src/main/java/org/apache/commons/collections4/list/SetUniqueList.java b/src/main/java/org/apache/commons/collections4/list/SetUniqueList.java
index 2f7d318f9e..0b75ccce4d 100644
--- a/src/main/java/org/apache/commons/collections4/list/SetUniqueList.java
+++ b/src/main/java/org/apache/commons/collections4/list/SetUniqueList.java
@@ -177,7 +177,7 @@ protected SetUniqueList(final List
- * (Violation) The {@code List} interface requires that this
+ * (Violation) The {@code List} interface requires that this
* method returns {@code true} always. However, this class may return
* {@code false} because of the {@code Set} behavior.
*
@@ -200,7 +200,7 @@ public boolean add(final E object) {
* Adds an element to a specific index in the list if it is not already
* present.
*
- * (Violation) The {@code List} interface makes the assumption
+ * (Violation) The {@code List} interface makes the assumption
* that the element is always inserted. This may not happen with this
* implementation.
*
@@ -222,7 +222,7 @@ public void add(final int index, final E object) {
* Only elements that are not already in this list will be added, and
* duplicates from the specified collection will be ignored.
*
- * (Violation) The {@code List} interface makes the assumption
+ * (Violation) The {@code List} interface makes the assumption
* that the elements are always inserted. This may not happen with this
* implementation.
*
@@ -241,7 +241,7 @@ public boolean addAll(final Collection extends E> coll) {
* Only elements that are not already in this list will be added, and
* duplicates from the specified collection will be ignored.
*
- * (Violation) The {@code List} interface makes the assumption
+ * (Violation) The {@code List} interface makes the assumption
* that the elements are always inserted. This may not happen with this
* implementation.
*
diff --git a/src/main/java/org/apache/commons/collections4/map/AbstractReferenceMap.java b/src/main/java/org/apache/commons/collections4/map/AbstractReferenceMap.java
index e08302356d..632233495d 100644
--- a/src/main/java/org/apache/commons/collections4/map/AbstractReferenceMap.java
+++ b/src/main/java/org/apache/commons/collections4/map/AbstractReferenceMap.java
@@ -69,7 +69,7 @@
* hard keys and soft values, providing a memory-sensitive cache.
*
- * This {@link Map} implementation does not allow null elements.
+ * This {@link Map} implementation does not allow null elements.
* Attempting to add a null key or value to the map will raise a
* {@code NullPointerException}.
*
- * This {@link java.util.Map Map} implementation does not allow null elements.
+ * This {@link java.util.Map Map} implementation does not allow null elements.
* Attempting to add a null key or value to the map will raise a {@code NullPointerException}.
*
diff --git a/src/main/java/org/apache/commons/collections4/map/ReferenceMap.java b/src/main/java/org/apache/commons/collections4/map/ReferenceMap.java
index 5f98bb6d60..c94ce1b5f5 100644
--- a/src/main/java/org/apache/commons/collections4/map/ReferenceMap.java
+++ b/src/main/java/org/apache/commons/collections4/map/ReferenceMap.java
@@ -47,7 +47,7 @@
* It differs in that keys and values in this class are compared using {@code equals()}.
*
- * This {@link java.util.Map Map} implementation does not allow null elements.
+ * This {@link java.util.Map Map} implementation does not allow null elements.
* Attempting to add a null key or value to the map will raise a {@code NullPointerException}.
*
diff --git a/src/main/java/org/apache/commons/collections4/map/SingletonMap.java b/src/main/java/org/apache/commons/collections4/map/SingletonMap.java
index dce5b9f2ee..4922cfd7bc 100644
--- a/src/main/java/org/apache/commons/collections4/map/SingletonMap.java
+++ b/src/main/java/org/apache/commons/collections4/map/SingletonMap.java
@@ -38,7 +38,7 @@
*
* The single key/value pair is specified at creation.
* The map is fixed size so any action that would change the size is disallowed.
- * However, the {@code put} or {@code setValue} methods can change
+ * However, the {@code put} or {@code setValue} methods can change
* the value associated with the key.
*
diff --git a/src/main/java/org/apache/commons/collections4/map/StaticBucketMap.java b/src/main/java/org/apache/commons/collections4/map/StaticBucketMap.java
index 441436f86f..2abd65ab1a 100644
--- a/src/main/java/org/apache/commons/collections4/map/StaticBucketMap.java
+++ b/src/main/java/org/apache/commons/collections4/map/StaticBucketMap.java
@@ -41,7 +41,7 @@
* number of entries exceeds the number of buckets or if the hash codes of the
* objects are not uniformly distributed, these operations have a worst case
* scenario that is proportional to the number of elements in the map
- * (O(n)).
+ * (O(n)).
*
* Each bucket in the hash table has its own monitor, so two threads can
@@ -52,7 +52,7 @@
* that this map implementation behaves in ways you may find disconcerting.
* Bulk operations, such as {@link #putAll(Map) putAll} or the
* {@link Collection#retainAll(Collection) retainAll} operation in collection
- * views, are not atomic. If two threads are simultaneously
+ * views, are not atomic. If two threads are simultaneously
* executing
*
- * The iterators returned by the collection views of this class are not
- * fail-fast. They will never raise a
+ * The iterators returned by the collection views of this class are not
+ * fail-fast. They will never raise a
* {@link java.util.ConcurrentModificationException}. Keys and values
* added to the map after the iterator is created do not necessarily appear
* during iteration. Similarly, the iterator does not necessarily fail to
@@ -86,7 +86,7 @@
*
* Finally, unlike {@link java.util.HashMap}-style implementations, this
- * class never rehashes the map. The number of buckets is fixed
+ * class never rehashes the map. The number of buckets is fixed
* at construction time and never altered. Performance may degrade if
* you do not allocate enough buckets upfront.
* max(cardinality(e,a),cardinality(e,b)) - min(cardinality(e,a),
- * cardinality(e,b))
.
+ * max(cardinality(e,a),cardinality(e,b)) - min(cardinality(e,a),
+ * cardinality(e,b))
.
*
*
*
* @param a the first (sub?) collection, must not be null
* @param b the second (super?) collection, must not be null
- * @return {@code true} iff a is a proper sub-collection of b
+ * @return {@code true} iff a is a proper sub-collection of b
* @throws NullPointerException if either collection is null
* @see #isSubCollection
* @see Collection#containsAll
@@ -1332,14 +1332,14 @@ public static boolean isProperSubCollection(final Collection> a, final Collect
}
/**
- * Returns {@code true} iff a is a sub-collection of b,
- * that is, iff the cardinality of e in a is less than or
- * equal to the cardinality of e in b, for each element e
- * in a.
+ * Returns {@code true} iff a is a sub-collection of b,
+ * that is, iff the cardinality of e in a is less than or
+ * equal to the cardinality of e in b, for each element e
+ * in a.
*
* @param a the first (sub?) collection, must not be null
* @param b the second (super?) collection, must not be null
- * @return {@code true} iff a is a sub-collection of b
+ * @return {@code true} iff a is a sub-collection of b
* @throws NullPointerException if either collection is null
* @see #isProperSubCollection
* @see Collection#containsAll
@@ -1946,10 +1946,10 @@ public static boolean sizeIsEmpty(final Object object) {
}
/**
- * Returns a new {@link Collection} containing {@code a - b}.
- * The cardinality of each element e in the returned {@link Collection}
- * will be the cardinality of e in a minus the cardinality
- * of e in b, or zero, whichever is greater.
+ * Returns a new {@link Collection} containing {@code a - b}.
+ * The cardinality of each element e in the returned {@link Collection}
+ * will be the cardinality of e in a minus the cardinality
+ * of e in b, or zero, whichever is greater.
*
* @param a the collection to subtract from, must not be null
* @param b the collection to subtract, must not be null
@@ -1964,23 +1964,23 @@ public static (e1==null ? e2==null :
+ * the two lists are equal. (Two elements {@code e1} and
+ * {@code e2} are equal if
(e1==null ? e2==null :
* e1.equals(e2))
.) In other words, two lists are defined to be
* equal if they contain the same elements in the same order. This
* definition ensures that the equals method works properly across
diff --git a/src/main/java/org/apache/commons/collections4/ListValuedMap.java b/src/main/java/org/apache/commons/collections4/ListValuedMap.java
index 22d7c1fe25..75079bd328 100644
--- a/src/main/java/org/apache/commons/collections4/ListValuedMap.java
+++ b/src/main/java/org/apache/commons/collections4/ListValuedMap.java
@@ -53,7 +53,7 @@ public interface ListValuedMap