*/
private GraphicsDocument createLabelDocument(StringWriter writer, LabelStyleInfo labelStyleInfo)
throws RenderException {
if (TileMetadata.PARAM_SVG_RENDERER.equalsIgnoreCase(renderer)) {
DefaultSvgDocument document = new DefaultSvgDocument(writer, false);
document.setMaximumFractionDigits(MAXIMUM_FRACTION_DIGITS);
document.registerWriter(InternalTileImpl.class, new SvgLabelTileWriter(getTransformer(), labelStyleInfo,
geoService, textService));
return document;
} else if (TileMetadata.PARAM_VML_RENDERER.equalsIgnoreCase(renderer)) {
DefaultVmlDocument document = new DefaultVmlDocument(writer);
int coordWidth = tile.getScreenWidth();
int coordHeight = tile.getScreenHeight();
document.registerWriter(InternalFeatureImpl.class, new VmlFeatureWriter(getTransformer(), coordWidth,
coordHeight));
document.registerWriter(InternalTileImpl.class, new VmlLabelTileWriter(coordWidth, coordHeight,
getTransformer(), labelStyleInfo, geoService, textService));
document.setMaximumFractionDigits(MAXIMUM_FRACTION_DIGITS);
return document;
} else {
throw new RenderException(ExceptionCode.RENDERER_TYPE_NOT_SUPPORTED, renderer);
}
}