protected static char TWO_BYTES_CHARS_SHOWER = '?';
/**
- * Return meaningful value of <code>str</code>
- *
- * Return <code>null</code> if <code>str</code> has no implication
- *
- * @param str string to check
- *
- * @return meaningful string
- *
- * @see #trimToNull(String, String)
- */
- public static
- String
- trimToNull(
- final String str
- )
- {
- return trimToNull(str, null);
- }
-
- /**
- * Return meaningful value of <code>str</code>
- *
- * Return <code>def</code> if <code>str</code> has no implication
- *
- * @param str string to check
- *
- * @return meaningful string
- *
- * @see #getMeaningful(String)
- * @see #isEmpty(CharSequence)
- */
- public static String trimToNull(String str, String def) {
- final String meaningful = getMeaningful( str );
- return isEmpty( meaningful )?def:meaningful;
- }
-
- /**
* Convert <code>src</code> to {@link InputStream}
*
* @param src string to convert
protected static char TWO_BYTES_CHARS_SHOWER = '?';
/**
- * Return meaningful value of <code>str</code>
- *
- * Return <code>null</code> if <code>str</code> has no implication
- *
- * @param str string to check
- *
- * @return meaningful string
- *
- * @see #trimToNull(String, String)
- */
- public static
- String
- trimToNull(
- final String str
- )
- {
- return trimToNull(str, null);
- }
-
- /**
- * Return meaningful value of <code>str</code>
- *
- * Return <code>def</code> if <code>str</code> has no implication
- *
- * @param str string to check
- *
- * @return meaningful string
- *
- * @see #getMeaningful(String)
- * @see #isEmpty(CharSequence)
- */
- public static String trimToNull(String str, String def) {
- final String meaningful = getMeaningful( str );
- return isEmpty( meaningful )?def:meaningful;
- }
-
- /**
* Convert <code>src</code> to {@link InputStream}
*
* @param src string to convert