Loading ...
Sorry, an error occurred while loading the content.

extract info from SVG using Java program

Expand Messages
  • begur_n_rao
    I am trying to read SVG file using Java and trying to extract all component information. Though SVG follow an XML standard, I do not see a proper XML schema in
    Message 1 of 3 , Jan 8, 2009
    • 0 Attachment
      I am trying to read SVG file using Java and trying to extract all
      component information. Though SVG follow an XML standard, I do not see
      a proper XML schema in the SVG file. Is it possible to extract
      information from SVG file using Batik? If so, can you please send me
      Java example? Are there any other methods to extract the information
      from SVG?
    • Cameron McCormack
      ... Even if you don’t have a schema that will generate handy classes for you to access the information stored in the document, since it’s XML, you can
      Message 2 of 3 , Jan 8, 2009
      • 0 Attachment
        begur_n_rao:
        > I am trying to read SVG file using Java and trying to extract all
        > component information. Though SVG follow an XML standard, I do not see
        > a proper XML schema in the SVG file. Is it possible to extract
        > information from SVG file using Batik? If so, can you please send me
        > Java example? Are there any other methods to extract the information
        > from SVG?

        Even if you don’t have a schema that will generate handy classes for you
        to access the information stored in the document, since it’s XML, you
        can always use the DOM. For that, you don’t need Batik in particular
        (although it does have a DOM implementation that you use).

        http://java.sun.com/javase/6/docs/api/javax/xml/parsers/DocumentBuilderFactory.html
        http://java.sun.com/javase/6/docs/api/javax/xml/parsers/DocumentBuilder.html
        http://java.sun.com/javase/6/docs/api/org/w3c/dom/Document.html

        --
        Cameron McCormack ≝ http://mcc.id.au/
      • Cameron McCormack
        ... *that you can use -- Cameron McCormack ≝ http://mcc.id.au/
        Message 3 of 3 , Jan 8, 2009
        • 0 Attachment
          Cameron McCormack:
          > For that, you don’t need Batik in particular (although it does have a
          > DOM implementation that you use).

          *that you can use

          --
          Cameron McCormack ≝ http://mcc.id.au/
        Your message has been successfully submitted and would be delivered to recipients shortly.