public static void writeElementList(XMLOutput xmlOutput,String tagName,Iterator<String> listValueIterator) throws IOException {
  while (listValueIterator.hasNext()) {
    xmlOutput.openTag(tagName);
    xmlOutput.writeText(listValueIterator.next());
    xmlOutput.closeTag(tagName);
  }
}

public static void writeElementList ( XMLOutput xmlOutput , String tagName , Iterator < String > listValueIterator ) throws IOException { while ( listValueIterator . hasNext ( ) ) { xmlOutput . openTag ( tagName ) ; xmlOutput . writeText ( listValueIterator . next ( ) ) ; xmlOutput . closeTag ( tagName ) ; } }
write a list of strings to document as elements with given tag name .
