public static String join(final CharSequence delimiter, final CharSequence... elements) {
        if (elements == null || elements.length == 0) {
            return "";
        } else {
            return String.join(delimiter, elements);
        }
    }
@return str trimmed or an empty string if str is null
stroom-util-shared/src/main/java/stroom/util/shared/NullSafe.java