Skip to content

Commit d44dc8b

Browse files
committed
Add back ctor for 1.6 to keep binary compatibility.
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/codec/trunk@1201520 13f79535-47bb-0310-9956-ffa450edef68
1 parent d48d89f commit d44dc8b

1 file changed

Lines changed: 10 additions & 0 deletions

File tree

src/main/java/org/apache/commons/codec/StringEncoderComparator.java

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,16 @@ public class StringEncoderComparator implements Comparator {
3434
*/
3535
private final StringEncoder stringEncoder;
3636

37+
/**
38+
* Constructs a new instance.
39+
*
40+
* @deprecated Creating an instance without a {@link StringEncoder} leads to a {@link NullPointerException}. Will be
41+
* removed in 2.0.
42+
*/
43+
public StringEncoderComparator() {
44+
this.stringEncoder = null; // Trying to use this will cause things to break
45+
}
46+
3747
/**
3848
* Constructs a new instance with the given algorithm.
3949
*

0 commit comments

Comments
 (0)