ilog.views.svg
Class SVGOutputStream

java.lang.Object
  extended by ilog.views.io.IlvOutputStream
      extended by ilog.views.svg.SVGOutputStream

public class SVGOutputStream
extends IlvOutputStream

This class is an IlvOutputStream that allows you to save the contents of an IlvManager to an XML file using SVG grammar specifications. This is done in two steps: building a DOM tree with SVG elements corresponding to ILOG JViews graphic objects and then dumping the tree to the OutputStream.

See Also:
SVGStreamFactory, SVGDocumentBuilder

Constructor Summary
SVGOutputStream(OutputStream stream, SVGStreamFactory factory)
          Builds an SVGOutputStream from an OutputStream using information found in the given SVGStreamFactory.
 
Method Summary
 void write(IlvManager manager)
          Writes the contents of the manager to a stream using SVG grammar.
 
Methods inherited from class ilog.views.io.IlvOutputStream
filterObjects, flush, getBinary, getManager, setBinary, write, write, write, write, write, write, write, write, write, write, write, write, write, write, write, write, write, write, write, write, write, write, write, write, write, write, write, write, write, write, write, write, write, write, write, write, write, write, write, write, write, write, writeExtensions, writeGradient, writePattern, writeStroke, writeTexture
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SVGOutputStream

public SVGOutputStream(OutputStream stream,
                       SVGStreamFactory factory)
Builds an SVGOutputStream from an OutputStream using information found in the given SVGStreamFactory. If the IlvOutputStream.getBinary() method returns true, a GZIPOutputStream will be used to compress the OutputStream.

Parameters:
stream - The output stream.
factory - The SVG stream factory.
Method Detail

write

public void write(IlvManager manager)
           throws IOException
Writes the contents of the manager to a stream using SVG grammar. This is done by building the document, filling it with SVGElements translated from the IlvGraphic of the IlvManager, and then writing the document to the stream as an XML file.

Overrides:
write in class IlvOutputStream
Parameters:
manager - The manager to save.
Throws:
IOException - usual IO errors.
See Also:
SVGDocumentBuilder, SVGStreamFactory.createSVGDocumentBuilder()


Copyright © 1996-2007 ILOG S.A. All rights reserved.   Documentation homepage.   . All Rights Reserved.