smithers.svg
Class SVG

java.lang.Object
  extended by smithers.svg.SVG

public class SVG
extends java.lang.Object

Represents a Scalable Vector Graphics (SVG) image.


Field Summary
 java.util.List<SVGElement> elements
           
 java.lang.String postamble
           
 java.lang.String preamble
           
 
Constructor Summary
SVG(java.lang.String width, java.lang.String height)
          Creates a new SVG image.
 
Method Summary
 void add(SVGElement e)
          Adds a new element to this SVG image.
 void write(java.io.File f)
          Writes this SVG image to a file.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

elements

public java.util.List<SVGElement> elements

preamble

public java.lang.String preamble

postamble

public java.lang.String postamble
Constructor Detail

SVG

public SVG(java.lang.String width,
           java.lang.String height)
Creates a new SVG image.

Parameters:
width - the width of the image
height - the height of the image
Method Detail

add

public void add(SVGElement e)
Adds a new element to this SVG image.

Parameters:
e - the element to add

write

public void write(java.io.File f)
           throws java.io.IOException
Writes this SVG image to a file.

Parameters:
f - the file
Throws:
java.io.IOException