@Test public void assertNotNullNoopWhenNotNull() { String value = Assert.requireNonNull("definitely not null", "oh no"); assertThat(value).isEqualTo("definitely not null"); }
public static <T> T requireNonNull(@Nullable T t, String message) { if (t == null) { throw new IllegalArgumentException(message); } return t; }
Assert { public static <T> T requireNonNull(@Nullable T t, String message) { if (t == null) { throw new IllegalArgumentException(message); } return t; } }
Assert { public static <T> T requireNonNull(@Nullable T t, String message) { if (t == null) { throw new IllegalArgumentException(message); } return t; } private  Assert(); }
Assert { public static <T> T requireNonNull(@Nullable T t, String message) { if (t == null) { throw new IllegalArgumentException(message); } return t; } private  Assert(); static T requireNonNull(@Nullable T t, String message); static ByteString requireNonEmpty(@Nullable ByteString s, String message); static String requireNonEmpty(@Nullable String s, String message); }
Assert { public static <T> T requireNonNull(@Nullable T t, String message) { if (t == null) { throw new IllegalArgumentException(message); } return t; } private  Assert(); static T requireNonNull(@Nullable T t, String message); static ByteString requireNonEmpty(@Nullable ByteString s, String message); static String requireNonEmpty(@Nullable String s, String message);  }