code: public int getTypedNextSibling(int nodeHandle, int nodeType)
    {
    	if (nodeHandle == DTM.NULL)
    	return DTM.NULL;
    	int node = makeNodeIdentity(nodeHandle);
    	int eType;
    	while ((node = _nextsib(node)) != DTM.NULL && 
    	((eType = _exptype(node)) != nodeType && 
    	m_expandedNameTable.getType(eType)!= nodeType)); 
    	//_type(node) != nodeType));
          
      return (node == DTM.NULL ? DTM.NULL : makeNodeHandle(node));
    }
docs: Given a node handle, advance to its next sibling.
  If not yet resolved, waits for more nodes to be added to the document and
  tries again.
  @param nodeHandle int Handle of the node.
  @return int Node-number of next sibling,
  or DTM.NULL to indicate none exists.