org.apache.batik.svggen

Class AbstractSVGConverter

public abstract class AbstractSVGConverter extends Object implements SVGConverter, ErrorConstants

Abstract class with common utility methods used by subclasses for specific convertion operations. It holds a reference to a domFactory Document, which many implementations use, and provides a convenience method, to offers a convertion of double values to String that remove the trailing '.' character on integral values.
Field Summary
protected ListdefSet
Set of definitions to interpret the values of the attributes generated by this converter since its creation
protected MapdescMap
Map of descriptions already processed by this converter.
protected SVGGeneratorContextgeneratorContext
Used by converters to create Elements and other DOM objects
Constructor Summary
AbstractSVGConverter(SVGGeneratorContext generatorContext)
Method Summary
StringdoubleString(double value)
Utility method for subclasses.
ListgetDefinitionSet()

Field Detail

defSet

protected List defSet
Set of definitions to interpret the values of the attributes generated by this converter since its creation

descMap

protected Map descMap
Map of descriptions already processed by this converter. The key type is left to the implementations

generatorContext

protected SVGGeneratorContext generatorContext
Used by converters to create Elements and other DOM objects

Constructor Detail

AbstractSVGConverter

public AbstractSVGConverter(SVGGeneratorContext generatorContext)

Parameters: generatorContext can be used by the SVGConverter extensions to create Elements and other types of DOM objects.

Method Detail

doubleString

public final String doubleString(double value)
Utility method for subclasses.

getDefinitionSet

public List getDefinitionSet()

Returns: set of definitions referenced by the attribute values created by the implementation since its creation. The return value should never be null. If no definition is needed, an empty set should be returned.

Copyright B) 2008 Apache Software Foundation. All Rights Reserved.