[Htmlparser-cvs] htmlparser/src/org/htmlparser/util IteratorImpl.java,1.33,1.34
Brought to you by:
derrickoswald
From: <der...@us...> - 2003-11-06 03:00:48
|
Update of /cvsroot/htmlparser/htmlparser/src/org/htmlparser/util In directory sc8-pr-cvs1:/tmp/cvs-serv6198/util Modified Files: IteratorImpl.java Log Message: The tags now own their ids, enders and end tag enders. The isTagToBeEndedFor logic is now uses information from the tags, not the scanners. The kludge to get the scanner from the NodeFactory is now gone too, this also comes from the tag. Index: IteratorImpl.java =================================================================== RCS file: /cvsroot/htmlparser/htmlparser/src/org/htmlparser/util/IteratorImpl.java,v retrieving revision 1.33 retrieving revision 1.34 diff -C2 -d -r1.33 -r1.34 *** IteratorImpl.java 28 Oct 2003 12:54:22 -0000 1.33 --- IteratorImpl.java 6 Nov 2003 03:00:40 -0000 1.34 *************** *** 70,78 **** { // now recurse if there is a scanner for this type of tag ! name = tag.getTagName (); ! // whoah! really cheat here to get the parser ! // maybe eventually the tag will know it's own scanner eh ! org.htmlparser.Parser parser = (org.htmlparser.Parser)mLexer.getNodeFactory (); ! scanner = parser.getScanner (name); if ((null != scanner) && scanner.evaluate (tag, null)) ret = scanner.scan (tag, mLexer.getPage ().getUrl (), mLexer); --- 70,74 ---- { // now recurse if there is a scanner for this type of tag ! scanner = tag.getThisScanner (); if ((null != scanner) && scanner.evaluate (tag, null)) ret = scanner.scan (tag, mLexer.getPage ().getUrl (), mLexer); |