LANG-1411: Add changes.xml entry and @since tags.

This fixes #342 from GitHub. Thanks to Alexander Tsvetkov.
This commit is contained in:
Benedikt Ritter 2018-08-20 19:01:46 +02:00
parent 44e32205a6
commit d1e72ebede
No known key found for this signature in database
GPG Key ID: 9DAADC1C9FCC82D0
2 changed files with 4 additions and 1 deletions

View File

@ -45,7 +45,8 @@ The <action> type attribute can be add,update,fix,remove.
</properties> </properties>
<body> <body>
<release version="3.8" date="????-??-??" description="??"> <release version="3.9" date="????-??-??" description="??">
<action issue="LANG-1411" type="add" dev="britter" due-to="Alexander Tsvetkov">Add isEmpty method to ObjectUtils</action>
</release> </release>
<release version="3.8" date="2018-08-15" description="New features and bug fixes. Requires Java 7, supports Java 8, 9, 10."> <release version="3.8" date="2018-08-15" description="New features and bug fixes. Requires Java 7, supports Java 8, 9, 10.">

View File

@ -103,6 +103,7 @@ public ObjectUtils() {
* @param object the {@code Object} to test, may be {@code null} * @param object the {@code Object} to test, may be {@code null}
* @return {@code true} if the object has a supported type and is empty or null, * @return {@code true} if the object has a supported type and is empty or null,
* {@code false} otherwise * {@code false} otherwise
* @since 3.9
*/ */
public static boolean isEmpty(final Object object) { public static boolean isEmpty(final Object object) {
if (object == null) { if (object == null) {
@ -146,6 +147,7 @@ public static boolean isEmpty(final Object object) {
* @param object the {@code Object} to test, may be {@code null} * @param object the {@code Object} to test, may be {@code null}
* @return {@code true} if the object has an unsupported type or is not empty * @return {@code true} if the object has an unsupported type or is not empty
* and not null, {@code false} otherwise * and not null, {@code false} otherwise
* @since 3.9
*/ */
public static boolean isNotEmpty(final Object object) { public static boolean isNotEmpty(final Object object) {
return !isEmpty(object); return !isEmpty(object);