Update of /cvsroot/babeldoc/babeldoc/modules/jfreereports/src/com/babeldoc/utils
In directory sc8-pr-cvs1:/tmp/cvs-serv10917/modules/jfreereports/src/com/babeldoc/utils
Modified Files:
Tag: TEMP_MIKEA
XMLTableModel.java
Log Message:
Removed the gotXXXCount internal variables, now using -1 to indicate values not calculated yet.
Index: XMLTableModel.java
===================================================================
RCS file: /cvsroot/babeldoc/babeldoc/modules/jfreereports/src/com/babeldoc/utils/Attic/XMLTableModel.java,v
retrieving revision 1.1.2.1
retrieving revision 1.1.2.2
diff -C2 -d -r1.1.2.1 -r1.1.2.2
*** XMLTableModel.java 21 Nov 2003 09:17:04 -0000 1.1.2.1
--- XMLTableModel.java 25 Nov 2003 08:01:31 -0000 1.1.2.2
***************
*** 21,25 ****
import org.w3c.dom.NamedNodeMap;
import org.w3c.dom.Node;
- import org.w3c.dom.traversal.NodeIterator;
import org.dom4j.io.DOMWriter;
--- 21,24 ----
***************
*** 50,57 ****
private Document xmlData;
! private boolean gotColumnCount = false;
! private int columnCount;
! private boolean gotRowCount = false;
! private int rowCount;
public XMLTableModel() {
--- 49,54 ----
private Document xmlData;
! private int columnCount = -1;
! private int rowCount = -1;
public XMLTableModel() {
***************
*** 74,78 ****
if (xmlData == null) return (0);
! if (gotColumnCount) return (columnCount);
// This is the xpath for the count of columns in the first row
--- 71,75 ----
if (xmlData == null) return (0);
! if (columnCount >= 0) return (columnCount);
// This is the xpath for the count of columns in the first row
***************
*** 93,97 ****
// Get the result value from the node and cache
columnCount = new Integer(n.getNodeValue()).intValue();
- gotColumnCount = true;
return (columnCount);
--- 90,93 ----
***************
*** 105,109 ****
if (xmlData == null) return (0);
! if (gotRowCount) return (rowCount);
// This is the xpath for the count of columns in the first row
--- 101,105 ----
if (xmlData == null) return (0);
! if (rowCount >= 0) return (rowCount);
// This is the xpath for the count of columns in the first row
***************
*** 123,127 ****
// Get the result value from the node and cache
rowCount = new Integer(n.getNodeValue()).intValue();
- gotRowCount = true;
return (rowCount);
--- 119,122 ----
|