Hi!

 

I'm developing a applet that shows an image ( SVG ) that changes according to some events that i'm not going to mention to be more brief.

 

The image is changed by replacing nodes of the Document (image representation on memory - DOM).

 

Here is what i do to change the Document.

 

First i load a xml file to memory:

 

 

 

public static Document parseXmlFile(String filename, boolean validating, boolean ns) {

        try {

 

            // Create a builder factory

            DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance();

            factory.setValidating(validating);

            factory.setNamespaceAware(ns);

 

 

            // Create the builder and parse the file

            //Document doc_temp = factory.newDocumentBuilder().parse(new File(filename));

 

            Document doc_temp = factory.newDocumentBuilder().parse(filename);

           

           

            return doc_temp;

        } catch (SAXException e) {

            // A parsing error occurred; the xml input is not valid

        e.printStackTrace();

        } catch (ParserConfigurationException e) {

        //

        e.printStackTrace();

        } catch (IOException e) {

        //

        e.printStackTrace();

        }

        return null;

    }

 

 

Then i replace the document loaded with the desire node on the image Document (DOM).

 

 

 

//Make a copy of the element subtree suitable for inserting into doc2

    Node dup = doc.importNode(gElement, true);

       

    // Insert the copy into doc2

    EventTarget all = (EventTarget)element;

    all.removeEventListener("click", new mouseClickListener(), false);

   

    element.getParentNode().replaceChild(dup,element);

 

 

My problem is:

 

Whe i load my applet some computer i have noticed that when i change something on the image my applet uses some bandwith (say 700 bytes ). I have looked into apache html server log and the requests are:

 

 

 

GET /java/html/svgprototype/META-INF/services/com.sun.org.apache.xalan.internal.xsltc.dom.XSLTCDTMManager HTTP/1.1" 404 371

 

GET /java/html/svgprototype/META-INF/services/javax.xml.soap.MessageFactory HTTP/1.1" 404 341

 

 

The first i'm pretty sure that he needs it to build the soap message the acces to my webservice. But i don't know the reason of the second.

 

What is it?? can you help me?? How can i make my applet independent from these calls??

Reply via email to