Skip to content

Commit cc3138b

Browse files
committed
HADOOP-7078. Improve javadocs for RawComparator interface. Contributed by Harsh J Chouraria.
git-svn-id: https://svn.apache.org/repos/asf/hadoop/common/trunk@1052933 13f79535-47bb-0310-9956-ffa450edef68
1 parent 1a12911 commit cc3138b

File tree

2 files changed

+15
-0
lines changed

2 files changed

+15
-0
lines changed

CHANGES.txt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,9 @@ Trunk (unreleased changes)
3636

3737
HADOOP-7059. Remove "unused" warning in native code. (Noah Watkins via eli)
3838

39+
HADOOP-7078. Improve javadocs for RawComparator interface.
40+
(Harsh J Chouraria via todd)
41+
3942
OPTIMIZATIONS
4043

4144
BUG FIXES

src/java/org/apache/hadoop/io/RawComparator.java

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,18 @@
3636
@InterfaceStability.Stable
3737
public interface RawComparator<T> extends Comparator<T> {
3838

39+
/**
40+
* Compare two objects in binary.
41+
* b1[s1:l1] is the first object, and b2[s2:l2] is the second object.
42+
*
43+
* @param b1 The first byte array.
44+
* @param s1 The position index in b1. The object under comparison's starting index.
45+
* @param l1 The length of the object in b1.
46+
* @param b2 The second byte array.
47+
* @param s2 The position index in b2. The object under comparison's starting index.
48+
* @param l2 The length of the object under comparison in b2.
49+
* @return An integer result of the comparison.
50+
*/
3951
public int compare(byte[] b1, int s1, int l1, byte[] b2, int s2, int l2);
4052

4153
}

0 commit comments

Comments
 (0)