5 #include "textparser.hxx"
6 #include "htmlparser.hxx"
7 #include "latexparser.hxx"
8 #include "xmlparser.hxx"
15 main(int argc, char** argv)
18 /* first parse the command line options */
21 fprintf(stderr,"correct syntax is:\n");
22 fprintf(stderr,"testparser file\n");
23 fprintf(stderr,"example: testparser /dev/stdin\n");
27 /* open the words to check list */
28 f = fopen(argv[1],"r");
30 fprintf(stderr,"Error - could not open file of words to check\n");
34 TextParser * p = new TextParser("qwertzuiopasdfghjklyxcvbnméáúõûóüöíQWERTZUIOPASDFGHJKLYXCVBNMÍÉÁÕÚÖÜÓÛ");
39 while(fgets(buf,MAXLNLEN,f)) {
41 p->set_url_checking(1);
42 while ((next=p->next_token())) {
43 fprintf(stdout,"token: %s\n",next);