You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@maven.apache.org by el...@apache.org on 2020/06/08 10:47:51 UTC

[maven-shared-utils] branch master updated: deprecate defaultString since it's now in the JDK (#51)

This is an automated email from the ASF dual-hosted git repository.

elharo pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/maven-shared-utils.git


The following commit(s) were added to refs/heads/master by this push:
     new cd25a37  deprecate defaultString since it's now in the JDK (#51)
cd25a37 is described below

commit cd25a3712e54d7d79efb0ad743af32ee61f0f4f6
Author: Elliotte Rusty Harold <el...@users.noreply.github.com>
AuthorDate: Mon Jun 8 06:47:37 2020 -0400

    deprecate defaultString since it's now in the JDK (#51)
---
 src/main/java/org/apache/maven/shared/utils/StringUtils.java | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/src/main/java/org/apache/maven/shared/utils/StringUtils.java b/src/main/java/org/apache/maven/shared/utils/StringUtils.java
index 4f56e1b..24fd30a 100644
--- a/src/main/java/org/apache/maven/shared/utils/StringUtils.java
+++ b/src/main/java/org/apache/maven/shared/utils/StringUtils.java
@@ -1888,7 +1888,9 @@ public class StringUtils
      * @param obj the Object to check
      * @return the passed in Object's toString, or blank if it was
      *         <code>null</code>
+     * @deprecated use {@code java.lang.Objects.toString()}
      */
+    @Deprecated
     @Nonnull public static String defaultString( Object obj )
     {
         return defaultString( obj, "" );
@@ -1904,7 +1906,9 @@ public class StringUtils
      *                      <code>null</code>
      * @return the passed in string, or the default if it was
      *         <code>null</code>
+     * @deprecated use {@code java.lang.Objects.toString()}
      */
+    @Deprecated
     @Nonnull public static String defaultString( Object obj, @Nonnull String defaultString )
     {
         return ( obj == null ) ? defaultString : obj.toString();