public static String ifNullOrEmpty(final String original,final String defaultString){
  Reject.ifNull(defaultString,"Default string must not be null");
  return (original == null || original.isEmpty()) ? defaultString : original;
}

public static String ifNullOrEmpty ( final String original , final String defaultString ) { Reject . ifNull ( defaultString , "Default string must not be null" ) ; return ( original == null || original . isEmpty ( ) ) ? defaultString : original ; }
checks that the original string is not null nor empty , if so it returns the non - null default string instead .
