@Test public void shouldReturnAnEmptyListIfTheStringToTokenizeIsNull() { Set<String> set = StringTokenizer.tokenize(" "); assertThat(set).isEmpty(); }
public static Set<String> tokenize(String input) { return StringUtils.isBlank(input) ? new HashSet<String>() : new HashSet<String>(Arrays.asList(input.trim().split("\\s*,\\s*"))); }
StringTokenizer { public static Set<String> tokenize(String input) { return StringUtils.isBlank(input) ? new HashSet<String>() : new HashSet<String>(Arrays.asList(input.trim().split("\\s*,\\s*"))); } }
StringTokenizer { public static Set<String> tokenize(String input) { return StringUtils.isBlank(input) ? new HashSet<String>() : new HashSet<String>(Arrays.asList(input.trim().split("\\s*,\\s*"))); } private  StringTokenizer(); }
StringTokenizer { public static Set<String> tokenize(String input) { return StringUtils.isBlank(input) ? new HashSet<String>() : new HashSet<String>(Arrays.asList(input.trim().split("\\s*,\\s*"))); } private  StringTokenizer(); static Set<String> tokenize(String input); }
StringTokenizer { public static Set<String> tokenize(String input) { return StringUtils.isBlank(input) ? new HashSet<String>() : new HashSet<String>(Arrays.asList(input.trim().split("\\s*,\\s*"))); } private  StringTokenizer(); static Set<String> tokenize(String input);  }