changeset 7789:7225a758c172

better docs for xor
author mduigou
date Mon, 01 Apr 2013 14:52:26 -0700
parents 1b67c524ecb9
children 4a987d5dc161
files src/share/classes/java/util/function/Predicate.java
diffstat 1 files changed, 3 insertions(+), 4 deletions(-) [+]
line wrap: on
line diff
--- a/src/share/classes/java/util/function/Predicate.java	Mon Apr 01 14:22:07 2013 -0700
+++ b/src/share/classes/java/util/function/Predicate.java	Mon Apr 01 14:52:26 2013 -0700
@@ -88,12 +88,11 @@
     }
 
     /**
-     * Returns a predicate that evaluates to {@code true} if both or neither of
-     * the component predicates evaluate to {@code true}.
+     * Returns a predicate which evaluates to {@code true} when the provided
+     * predicate evaluates to a different value than this predicate.
      *
      * @param p a predicate which will be logically-XORed with this predicate
-     * @return a predicate that evaluates to {@code true} if both or neither of
-     * the component predicates evaluate to {@code true}
+     * @return a predicate that performs a logical-XOR of two predicates.
      * @throws NullPointerException if p is null
      */
     public default Predicate<T> xor(Predicate<? super T> p) {