- Sort Score
- Result 10 results
- Languages All
Results 1 - 3 of 3 for nullToEmpty (0.04 sec)
-
android/guava-tests/test/com/google/common/base/StringsTest.java
* @author Kevin Bourrillion */ @NullMarked @GwtCompatible public class StringsTest extends TestCase { public void testNullToEmpty() { assertEquals("", Strings.nullToEmpty(null)); assertEquals("", Strings.nullToEmpty("")); assertEquals("a", Strings.nullToEmpty("a")); } public void testEmptyToNull() { assertNull(Strings.emptyToNull(null)); assertNull(Strings.emptyToNull(""));
Registered: Fri Sep 05 12:43:10 UTC 2025 - Last Modified: Wed Aug 27 17:53:41 UTC 2025 - 10.5K bytes - Viewed (0) -
android/guava/src/com/google/common/base/Strings.java
* * @param string the string to test and possibly return * @return {@code string} itself if it is non-null; {@code ""} if it is null */ public static String nullToEmpty(@Nullable String string) { return Platform.nullToEmpty(string); } /** * Returns the given string if it is nonempty; {@code null} otherwise. * * @param string the string to test and possibly return
Registered: Fri Sep 05 12:43:10 UTC 2025 - Last Modified: Wed Aug 27 17:53:41 UTC 2025 - 12.2K bytes - Viewed (0) -
android/guava/src/com/google/common/base/Platform.java
* * @param string the string to test and possibly return * @return {@code string} if it is not null; {@code ""} otherwise */ static String nullToEmpty(@Nullable String string) { return (string == null) ? "" : string; } /** * Returns the string if it is not empty, or a null string otherwise. * * @param string the string to test and possibly return
Registered: Fri Sep 05 12:43:10 UTC 2025 - Last Modified: Thu Aug 07 16:05:33 UTC 2025 - 4.1K bytes - Viewed (0)