My favorites | Sign in
Project Logo
                
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
package org.hamcrestcollections;

/**
* <p>
* A {@code Reducer} quite literally reduces two arguments down to one. Used as part of a {@link Reduction}.
* </p>
*
* <p>
* Examples of a {@code Reducer} might include a sum function that adds all the items of a list together, or a
* string builder used to concatinate many strings together
* </p?
*
* @see Reduction
* @author Sam Newman (sam-newman@magpiebrain.com)
*/
public interface Reducer<T> {
T apply(T first, T second);
}
Show details Hide details

Change log

r3 by sam.newman on Aug 09, 2007   Diff
Initial Checkin
Go to: 
Project members, sign in to write a code review

Older revisions

All revisions of this file

File info

Size: 509 bytes, 18 lines
Hosted by Google Code