package edu.rice.hj.example.comp322.assignments.hw2; /** * This file contains the definition of the GeneralizedReduceApp interface. * Any parallel reduction implementation (such as SumReduction) must implement * this interface. *

* Do not alter this file for your homework submission. * * @author Vivek Sarkar (vsarkar@rice.edu) */ public interface GeneralizedReduceApp { /** * return identity element for clients reduction operation * * @return a T object. */ T init(); /** * perform associative operation on left and right operands, in accordance with the * clients reduction operation, and return the result * * @param left a T object. * @param right a T object. * @return a T object. */ T combine(T left, T right); }