MCPcopy Create free account
hub / github.com/apache/storm / getRepeat

Method getRepeat

storm-client/src/jvm/org/apache/storm/utils/Utils.java:963–976  ·  view source on GitHub ↗
(List<String> list)

Source from the content-addressed store, hash-verified

961 }
962
963 public static List<String> getRepeat(List<String> list) {
964 List<String> rtn = new ArrayList<String>();
965 Set<String> idSet = new HashSet<String>();
966
967 for (String id : list) {
968 if (idSet.contains(id)) {
969 rtn.add(id);
970 } else {
971 idSet.add(id);
972 }
973 }
974
975 return rtn;
976 }
977
978 public static GlobalStreamId getGlobalStreamId(String componentId, String streamId) {
979 if (streamId == null) {

Callers 1

validateIdsMethod · 0.95

Calls 2

containsMethod · 0.65
addMethod · 0.65

Tested by

no test coverage detected