jdk/src/share/classes/java/util/function/BinaryOperator.java
changeset 16011 890a7ed97f6c
parent 15647 314007859004
child 16036 a30224365db2
--- a/jdk/src/share/classes/java/util/function/BinaryOperator.java	Tue Feb 19 10:34:26 2013 -0800
+++ b/jdk/src/share/classes/java/util/function/BinaryOperator.java	Tue Feb 19 11:56:49 2013 -0800
@@ -25,24 +25,14 @@
 package java.util.function;
 
 /**
- * An operation upon two operands yielding a result. The operands and the result
- * are all of the same type.
+ * An operation upon two operands yielding a result. This is a specialization of
+ * {@code BiFunction} where the operands and the result are all of the same type.
  *
- * @param <T> the type of operands to {@code operate} and of the result
+ * @param <T> the type of operands to {@code apply} and of the result
  *
+ * @see BiFunction.
  * @since 1.8
  */
 @FunctionalInterface
-public interface BinaryOperator<T> {
-
-    /**
-     * Returns the result of the operation upon the operands.
-     * The operands are named {@code left} and {@code right} for operations
-     * where the order of operands matters.
-     *
-     * @param left the left operand
-     * @param right the right operand
-     * @return the result of the operation
-     */
-    public T operate(T left, T right);
+public interface BinaryOperator<T> extends BiFunction<T,T,T> {
 }