Class TestIntegerBinaryOperation

  • All Implemented Interfaces:
    IntegerBinaryOperation

    public class TestIntegerBinaryOperation
    extends java.lang.Object
    implements IntegerBinaryOperation
    A operation taking two operands of type int, and producing a value of type int. This interface attempts to mimic a first-class function of two variables.
    Since:
    Ptolemy II 2.0
    Version:
    $Id$
    Author:
    Christopher Hylands
    Pt.AcceptedRating:
    Red (ctsay)
    Pt.ProposedRating:
    Red (ctsay)
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      int operate​(int leftOperand, int rightOperand)
      Operate on the operands, returning a value of the same type.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • TestIntegerBinaryOperation

        public TestIntegerBinaryOperation()
    • Method Detail

      • operate

        public int operate​(int leftOperand,
                           int rightOperand)
        Operate on the operands, returning a value of the same type. Note that the operation need not be commutative.
        Specified by:
        operate in interface IntegerBinaryOperation
        Parameters:
        leftOperand - The left operand.
        rightOperand - The right operand.
        Returns:
        The results of the operation