private RE unionREs(Set<RE> coll) throws InterruptedException {
  if (coll.isEmpty()) {
    return RE.empty;
  }
  RE acc=RE.empty;
  for (  RE re : coll) {
    acc=acc.union(re);
  }
  return acc;
}

private RE unionREs ( Set < RE > coll ) throws InterruptedException { if ( coll . isEmpty ( ) ) { return RE . empty ; } RE acc = RE . empty ; for ( RE re : coll ) { acc = acc . union ( re ) ; } return acc ; }
combines a set of regular expressions into a single regular expression .
