Lines Matching refs:node1
116 private void diffLog(String errMsg, Node node1, Node node2) { in diffLog() argument
121 if (node1 != null) { in diffLog()
122 node1Str = "[Type]:" + nodeInfo(node1) + in diffLog()
123 " [Name]:" + node1.getNodeName(); in diffLog()
124 if (node1.getNodeValue() != null) in diffLog()
125 node1Str += " [Value]:" + node1.getNodeValue(); in diffLog()
198 private boolean attributesEqual(Node node1, Node node2) { in attributesEqual() argument
202 private boolean compareNode(Node node1, Node node2) { in compareNode() argument
207 if (node1 == null && node2 == null) { in compareNode()
210 } else if (node1 == null || node2 == null) { in compareNode()
211 diffLog("DIFF: one of the node is null", node1, node2); in compareNode()
215 if (node1.getNodeType() != node2.getNodeType()) { in compareNode()
216 diffLog("DIFF: nodetype is different", node1, node2); in compareNode()
220 if (node1.getNodeName() == null && node2.getNodeName() == null) { in compareNode()
222 } else if (node1.getNodeName() == null || in compareNode()
224 diffLog("DIFF: one of the nodeName is null", node1, node2); in compareNode()
226 } else if (!node1.getNodeName().equals(node2.getNodeName())) { in compareNode()
227 diffLog("DIFF: nodeName is different", node1, node2); in compareNode()
231 if (ignoreTag(node1.getNodeName())) { in compareNode()
232 diffLog("DIFF: Some tag(s) is ignored", node1, node2); in compareNode()
237 if (node1.getNodeValue() == null && node2.getNodeValue() == null) { in compareNode()
239 } else if (node1.getNodeValue() == null || in compareNode()
241 diffLog("DIFF: one of the nodevalue is null", node1, node2); in compareNode()
243 } else if (!node1.getNodeValue().equals(node2.getNodeValue())) { in compareNode()
244 diffLog("DIFF: nodeValue is different", node1, node2); in compareNode()
249 if (!attributesEqual(node1, node2)) in compareNode()
252 NodeList node1Children = node1.getChildNodes(); in compareNode()
262 diffLog("DIFF: one node's children is null", node1, node2); in compareNode()
267 diffLog("DIFF: num of children is different", node1, node2); in compareNode()