[Htmlparser-cvs] htmlparser/src/org/htmlparser/util NodeList.java,1.23,1.24
Brought to you by:
derrickoswald
From: <der...@us...> - 2003-05-11 04:48:14
|
Update of /cvsroot/htmlparser/htmlparser/src/org/htmlparser/util In directory sc8-pr-cvs1:/tmp/cvs-serv24541/org/htmlparser/util Modified Files: NodeList.java Log Message: Fixed bug #735183 Problem in Label Scanning A NodeReader now prepends the pre-read tags onto the internal list, maintaining the correct order in recursively analysing unclosed tags. Also fixed OptionTagScanner tag enders. Index: NodeList.java =================================================================== RCS file: /cvsroot/htmlparser/htmlparser/src/org/htmlparser/util/NodeList.java,v retrieving revision 1.23 retrieving revision 1.24 diff -C2 -d -r1.23 -r1.24 *** NodeList.java 7 May 2003 22:00:09 -0000 1.23 --- NodeList.java 11 May 2003 04:48:11 -0000 1.24 *************** *** 57,60 **** --- 57,73 ---- } + /** + * Insert the given node at the head of the list. + * @param node The new first element. + */ + public void prepend(Node node) + { + if (size==capacity) + adjustVectorCapacity(); + System.arraycopy (nodeData, 0, nodeData, 1, size); + size++; + nodeData[0]=node; + } + private void adjustVectorCapacity() { capacity += capacityIncrement; |