From 4289521fba5dd08a32a74c8d9f27fd42f3a26ea4 Mon Sep 17 00:00:00 2001 From: Joe Schmetzer Date: Sun, 17 Nov 2024 13:39:45 +1100 Subject: [PATCH] Restore public constructors for compatibility CoreMatchers, MatcherAssert, and Matchers had private contructors added to fix javadoc warnings. Unfortunately, this can break existig users of the classes. Fixes #427 --- hamcrest/src/main/java/org/hamcrest/CoreMatchers.java | 5 ++++- hamcrest/src/main/java/org/hamcrest/MatcherAssert.java | 5 ++++- hamcrest/src/main/java/org/hamcrest/Matchers.java | 5 ++++- 3 files changed, 12 insertions(+), 3 deletions(-) diff --git a/hamcrest/src/main/java/org/hamcrest/CoreMatchers.java b/hamcrest/src/main/java/org/hamcrest/CoreMatchers.java index 6dadcc52..f00a6e54 100644 --- a/hamcrest/src/main/java/org/hamcrest/CoreMatchers.java +++ b/hamcrest/src/main/java/org/hamcrest/CoreMatchers.java @@ -13,7 +13,10 @@ @SuppressWarnings("UnusedDeclaration") public class CoreMatchers { - private CoreMatchers() { + /** + * Unused + */ + public CoreMatchers() { } /** diff --git a/hamcrest/src/main/java/org/hamcrest/MatcherAssert.java b/hamcrest/src/main/java/org/hamcrest/MatcherAssert.java index 574f4f61..29d3364e 100644 --- a/hamcrest/src/main/java/org/hamcrest/MatcherAssert.java +++ b/hamcrest/src/main/java/org/hamcrest/MatcherAssert.java @@ -6,7 +6,10 @@ */ public class MatcherAssert { - private MatcherAssert() { + /** + * Unused. + */ + public MatcherAssert() { } /** diff --git a/hamcrest/src/main/java/org/hamcrest/Matchers.java b/hamcrest/src/main/java/org/hamcrest/Matchers.java index 714777c2..dcc88366 100644 --- a/hamcrest/src/main/java/org/hamcrest/Matchers.java +++ b/hamcrest/src/main/java/org/hamcrest/Matchers.java @@ -22,7 +22,10 @@ @SuppressWarnings({"unused", "WeakerAccess"}) public class Matchers { - private Matchers() { + /** + * Unused + */ + public Matchers() { } /**