I’m using Xerces-1.3.0 on Windows 2000 with JDK 1.3.0.

 

I cannot use org.w3c.dom.Document.importNode. It’s in the API doc and it’s in the source, but the Java compiler cannot resolve it. Here’s some sample code:

 

  import org.w3c.dom.Node;

  import org.w3c.dom.Element;

  import org.w3c.dom.Document;

 

  public Node testClone(Document d, Node n, boolean b)

  {

     return d.importNode(n, b); 

  }

 

Here’s the error message:

 

C:\…\util\sample.java:156: cannot resolve symbol

symbol  : method importNode  (org.w3c.dom.Node,boolean)

location: interface org.w3c.dom.Document

            return d.importNode(n, b);

 

I also cannot use some other methods such as getElementsByTagNameNS which are marked as DOM Level 2 in the API Doc. What’s wrong? Shouldn’t I be able to use these methods?

 

Any help would be appreciated.

Thanks,

 

Alan Crocker

 

Reply via email to