code: private Iterator<String> filterOutEmptyStrings(final Iterator<String> splitted) {
          return new Iterator<String>() {
              String next = getNext();
              @Override
              public boolean hasNext() {
                  return next != null;
              }
  
              @Override
              public String next() {
                  if ( !hasNext() ) throw new NoSuchElementException();
                  String result = next;
                  next = getNext();
                  return result;
              }
  
              public String getNext() {
                  while (splitted.hasNext()) {
                      String value = splitted.next();
                      if ( value != null && !value.isEmpty() ) {
                          return value;
                      }
                  }
                  return null;
              }
  
              @Override
              public void remove() {
                  throw new UnsupportedOperationException();
              }
          };
      }
docs: Its easier to understand if the logic for omit empty sequences is a filtering iterator
  
  @param splitted - the results of a splittingIterator
  
  @return iterator with no empty values