static void PullAllNewsItems(urlconnection *urlconn, rssData *allData ) { streamtokenizer st; STNew(&st, urlconn->dataStream, kTextDelimiters, false); while (GetNextItemTag(&st)) { // if true is returned, then assume that <item ...> has just been read and pulled from the data stream ProcessSingleNewsItem(&st, allData ); } STDispose(&st); }
static void PullAllNewsItems(urlconnection *urlconn, hashset *stopWords, hashset *prevSeenArticles, hashset *wordCounts) { streamtokenizer st; STNew(&st, urlconn->dataStream, kTextDelimiters, false); while (GetNextItemTag(&st)) { // if true is returned, then assume that <item ...> has just been read and pulled from the data stream ProcessSingleNewsItem(&st, stopWords, prevSeenArticles, wordCounts); } STDispose(&st); }