Methods Summary |
---|
public MockXmlNode | addAttribute(java.lang.String namespace, java.lang.String localName, java.lang.String value)
MockXmlNode node = new MockXmlNode(namespace, localName, value);
if (namespace == null) {
namespace = ""; // no namespace
}
// get the map for the namespace
HashMap<String, Node> map = mNodeMap.get(namespace);
if (map == null) {
map = new HashMap<String, Node>();
mNodeMap.put(namespace, map);
}
map.put(localName, node);
mNodeList.add(node);
return node;
|
public int | getLength()
return mNodeList.size();
|
public org.w3c.dom.Node | getNamedItem(java.lang.String name)
HashMap<String, Node> map = mNodeMap.get(""); // no namespace
if (map != null) {
return map.get(name);
}
return null;
|
public org.w3c.dom.Node | getNamedItemNS(java.lang.String namespaceURI, java.lang.String localName)
if (namespaceURI == null) {
namespaceURI = ""; //no namespace
}
HashMap<String, Node> map = mNodeMap.get(namespaceURI);
if (map != null) {
return map.get(localName);
}
return null;
|
public org.w3c.dom.Node | item(int index)
return mNodeList.get(index);
|
public org.w3c.dom.Node | removeNamedItem(java.lang.String name)
throw new NotImplementedException();
|
public org.w3c.dom.Node | removeNamedItemNS(java.lang.String namespaceURI, java.lang.String localName)
throw new NotImplementedException();
|
public org.w3c.dom.Node | setNamedItem(org.w3c.dom.Node arg)
throw new NotImplementedException();
|
public org.w3c.dom.Node | setNamedItemNS(org.w3c.dom.Node arg)
throw new NotImplementedException();
|