org.apache.batik.apps.rasterizer
Class DefaultSVGConverterController

java.lang.Object
  extended by org.apache.batik.apps.rasterizer.DefaultSVGConverterController
All Implemented Interfaces:
SVGConverterController

public class DefaultSVGConverterController
extends Object
implements SVGConverterController

Default controller for the SVGConverter operation.


Constructor Summary
DefaultSVGConverterController()
           
 
Method Summary
 void onSourceTranscodingSuccess(SVGConverterSource source, File dest)
          Invoked when the rasterizer successfully transcoded the input source.
 boolean proceedOnSourceTranscodingFailure(SVGConverterSource source, File dest, String errorCode)
          Invoked when the rasterizer got an error while transcoding the input source.
 boolean proceedWithComputedTask(Transcoder transcoder, Map hints, List sources, List dest)
          Invoked when the rasterizer has computed the exact description of what it should do.
 boolean proceedWithSourceTranscoding(SVGConverterSource source, File dest)
          Invoked when the rasterizer is about to start transcoding of a given source.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DefaultSVGConverterController

public DefaultSVGConverterController()
Method Detail

proceedWithComputedTask

public boolean proceedWithComputedTask(Transcoder transcoder,
                                       Map hints,
                                       List sources,
                                       List dest)
Invoked when the rasterizer has computed the exact description of what it should do. The controller should return true if the transcoding process should proceed or false otherwise.

Specified by:
proceedWithComputedTask in interface SVGConverterController
Parameters:
transcoder - Transcoder which will be used for the conversion
hints - set of hints that were set on the transcoder
sources - list of SVG sources it will convert.
dest - list of destination file it will use

proceedWithSourceTranscoding

public boolean proceedWithSourceTranscoding(SVGConverterSource source,
                                            File dest)
Invoked when the rasterizer is about to start transcoding of a given source. The controller should return true if the source should be transcoded and false otherwise.

Specified by:
proceedWithSourceTranscoding in interface SVGConverterController

proceedOnSourceTranscodingFailure

public boolean proceedOnSourceTranscodingFailure(SVGConverterSource source,
                                                 File dest,
                                                 String errorCode)
Invoked when the rasterizer got an error while transcoding the input source. The controller should return true if the transcoding process should continue on other sources and it should return false if it should not.

Specified by:
proceedOnSourceTranscodingFailure in interface SVGConverterController
Parameters:
errorCode - see the SVGConverter error code descriptions.

onSourceTranscodingSuccess

public void onSourceTranscodingSuccess(SVGConverterSource source,
                                       File dest)
Invoked when the rasterizer successfully transcoded the input source.

Specified by:
onSourceTranscodingSuccess in interface SVGConverterController


Copyright © 2017 Apache Software Foundation. All Rights Reserved.