Checkstyle: DeclarationOrder, IDE autoformat
Project: http://git-wip-us.apache.org/repos/asf/logging-log4j2/repo Commit: http://git-wip-us.apache.org/repos/asf/logging-log4j2/commit/e69732dc Tree: http://git-wip-us.apache.org/repos/asf/logging-log4j2/tree/e69732dc Diff: http://git-wip-us.apache.org/repos/asf/logging-log4j2/diff/e69732dc Branch: refs/heads/LOG4J2-1136 Commit: e69732dcad8f71b39f3307c0ea0f3b898aec080b Parents: f9195ce Author: rpopma <[email protected]> Authored: Thu Sep 24 10:44:17 2015 +0200 Committer: Ralph Goers <[email protected]> Committed: Sun Sep 27 10:47:29 2015 -0700 ---------------------------------------------------------------------- .../org/apache/logging/log4j/util/Strings.java | 29 ++++++++------------ 1 file changed, 11 insertions(+), 18 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/logging-log4j2/blob/e69732dc/log4j-api/src/main/java/org/apache/logging/log4j/util/Strings.java ---------------------------------------------------------------------- diff --git a/log4j-api/src/main/java/org/apache/logging/log4j/util/Strings.java b/log4j-api/src/main/java/org/apache/logging/log4j/util/Strings.java index 5b1c8eb..27f71a9 100644 --- a/log4j-api/src/main/java/org/apache/logging/log4j/util/Strings.java +++ b/log4j-api/src/main/java/org/apache/logging/log4j/util/Strings.java @@ -23,6 +23,10 @@ package org.apache.logging.log4j.util; */ public final class Strings { + private Strings() { + // empty + } + /** * The empty string. */ @@ -31,8 +35,7 @@ public final class Strings { /** * Returns a double quoted string. * - * @param str - * a String + * @param str a String * @return {@code "str"} */ public static String dquote(final String str) { @@ -43,8 +46,7 @@ public final class Strings { * Checks if a String is blank. A blank string is one that is {@code null}, empty, or when trimmed using * {@link String#trim()} is empty. * - * @param s - * the String to check, may be {@code null} + * @param s the String to check, may be {@code null} * @return {@code true} if the String is {@code null}, empty, or trims to empty. */ public static boolean isBlank(final String s) { @@ -73,8 +75,7 @@ public final class Strings { * Copied from Apache Commons Lang org.apache.commons.lang3.StringUtils.isEmpty(CharSequence) * </p> * - * @param cs - * the CharSequence to check, may be null + * @param cs the CharSequence to check, may be null * @return {@code true} if the CharSequence is empty or null */ public static boolean isEmpty(final CharSequence cs) { @@ -84,8 +85,7 @@ public final class Strings { /** * Checks if a String is not blank. The opposite of {@link #isBlank(String)}. * - * @param s - * the String to check, may be {@code null} + * @param s the String to check, may be {@code null} * @return {@code true} if the String is non-{@code null} and has content after being trimmed. */ public static boolean isNotBlank(final String s) { @@ -109,8 +109,7 @@ public final class Strings { * Copied from Apache Commons Lang org.apache.commons.lang3.StringUtils.isNotEmpty(CharSequence) * </p> * - * @param cs - * the CharSequence to check, may be null + * @param cs the CharSequence to check, may be null * @return {@code true} if the CharSequence is not empty and not null */ public static boolean isNotEmpty(final CharSequence cs) { @@ -120,8 +119,7 @@ public final class Strings { /** * Returns a quoted string. * - * @param str - * a String + * @param str a String * @return {@code 'str'} */ public static String quote(final String str) { @@ -149,16 +147,11 @@ public final class Strings { * Copied from Apache Commons Lang org.apache.commons.lang3.StringUtils.trimToNull(String) * </p> * - * @param str - * the String to be trimmed, may be null + * @param str the String to be trimmed, may be null * @return the trimmed String, {@code null} if only chars <= 32, empty or null String input */ public static String trimToNull(final String str) { final String ts = str == null ? null : str.trim(); return isEmpty(ts) ? null : ts; } - - private Strings() { - // empty - } }
