You are viewing a plain text version of this content. The canonical link for it is here.
Posted to batik-dev@xmlgraphics.apache.org by Batik User <ba...@bilbao.com> on 2001/09/05 16:46:32 UTC

Problems with TestSVGGen

Hi!

First of all, thank you very much for answering.

I'm using BATIK 1.0.

When trying to compile:

---------//-----
import java.awt.Rectangle;
import java.awt.Graphics2D;
import java.awt.Color;
import java.io.Writer;
import java.io.OutputStreamWriter;
import java.io.IOException;
import org.apache.batik.svggen.SVGGraphics2D;
import org.apache.batik.dom.GenericDOMImplementation;
import org.w3c.dom.Document;
import org.w3c.dom.DOMImplementation;
...
Document document = domImpl.createDocument(null, "svg",
null);
...
-----------//-------

I get this error

Method createDocument not found in interface
org.w3c.dom.DomImplementation

Any suggestion???
_______________________________________________________________________
¿Sabes que puedes redireccionar tu correo de HispaVista a donde tú quieras?
http://www.hispavista.com/altascorreo/

---------------------------------------------------------------------
To unsubscribe, e-mail: batik-dev-unsubscribe@xml.apache.org
For additional commands, e-mail: batik-dev-help@xml.apache.org


createDocument not found in interface org.w3c.dom.DOMImplementation

Posted by Thomas E Deweese <th...@kodak.com>.
>>>>> "BU" == Batik User <ba...@bilbao.com> writes:

BU> Here you are the complete code (Proba.java):

    You most likely have your class path setup wrong.  The batik.jar
files must come before xerces or any other source of a W3C DOM
implementation, since we need a stylable DOM implementation.

BU> ---------------//------------------------ import
BU> java.io.IOException; import
BU> org.apache.batik.dom.svg.SVGDOMImplementation; import
BU> org.w3c.dom.Document; import org.w3c.dom.Element; import
BU> org.w3c.dom.DOMImplementation;
 
BU> public class Proba {

BU> 	public static void main(String [] args) throws IOException {
		
BU> 		DOMImplementation impl =
BU> SVGDOMImplementation.getDOMImplementation(); String svgNS =
BU> SVGDOMImplementation.SVG_NAMESPACE_URI; Document doc =
BU> impl.createDocument(svgNS, "svg", null); } }
BU> --------------------//------------------

BU> The error message is:

BU> createDocument not found in interface
BU> org.w3c.dom.DOMImplementation
BU> _______________________________________________________________________
BU> ¿Sabes que puedes redireccionar tu correo de HispaVista a donde tú
BU> quieras?  http://www.hispavista.com/altascorreo/

BU> ---------------------------------------------------------------------
BU> To unsubscribe, e-mail: batik-dev-unsubscribe@xml.apache.org For
BU> additional commands, e-mail: batik-dev-help@xml.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: batik-dev-unsubscribe@xml.apache.org
For additional commands, e-mail: batik-dev-help@xml.apache.org


Re: createDocument not found in interface org.w3c.dom.DOMImplementation

Posted by Batik User <ba...@bilbao.com>.
THANK YOU VERY MACH.

I was to blame.

You have to include batik JAR's before others.
_______________________________________________________________________
¿Sabes que puedes redireccionar tu correo de HispaVista a donde tú quieras?
http://www.hispavista.com/altascorreo/

---------------------------------------------------------------------
To unsubscribe, e-mail: batik-dev-unsubscribe@xml.apache.org
For additional commands, e-mail: batik-dev-help@xml.apache.org


Re: createDocument not found in interface org.w3c.dom.DOMImplementation

Posted by Thierry Kormann <tk...@ilog.fr>.
On Wednesday 05 September 2001 18:05, you wrote:
> Here you are the complete code (Proba.java):
>
> ---------------//------------------------
> import java.io.IOException;
> import org.apache.batik.dom.svg.SVGDOMImplementation;
> import org.w3c.dom.Document;
> import org.w3c.dom.Element;
> import org.w3c.dom.DOMImplementation;
>
> public class Proba {
>
> 	public static void main(String [] args) throws IOException
> {
>
> 		DOMImplementation impl = SVGDOMImplementation.getDOMImplementation();
> 		String svgNS = SVGDOMImplementation.SVG_NAMESPACE_URI;
> 		Document doc = impl.createDocument(svgNS, "svg", null);
> 	}
> }
> --------------------//------------------
>
> The error message is:
>
> createDocument not found in interface
> org.w3c.dom.DOMImplementation


Your code works fine and is correct. Please check your classpath (all jar 
files from batik should be first in your classpath, especially if you already 
have some other DOM bindings).

Thierry.


---------------------------------------------------------------------
To unsubscribe, e-mail: batik-dev-unsubscribe@xml.apache.org
For additional commands, e-mail: batik-dev-help@xml.apache.org


createDocument not found in interface org.w3c.dom.DOMImplementation

Posted by Batik User <ba...@bilbao.com>.
Here you are the complete code (Proba.java):

---------------//------------------------
import java.io.IOException;
import org.apache.batik.dom.svg.SVGDOMImplementation;
import org.w3c.dom.Document;
import org.w3c.dom.Element;
import org.w3c.dom.DOMImplementation;
 
public class Proba {

	public static void main(String [] args) throws IOException
{
		
		DOMImplementation impl = SVGDOMImplementation.getDOMImplementation();
		String svgNS = SVGDOMImplementation.SVG_NAMESPACE_URI;
		Document doc = impl.createDocument(svgNS, "svg", null);
	}	
}
--------------------//------------------

The error message is:

createDocument not found in interface
org.w3c.dom.DOMImplementation
_______________________________________________________________________
¿Sabes que puedes redireccionar tu correo de HispaVista a donde tú quieras?
http://www.hispavista.com/altascorreo/

---------------------------------------------------------------------
To unsubscribe, e-mail: batik-dev-unsubscribe@xml.apache.org
For additional commands, e-mail: batik-dev-help@xml.apache.org