Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.apache.batik.svggen
Interface GenericImageHandler

All Known Subinterfaces:
  CachedImageHandler

All Known Implementing Classes:
  CachedImageHandlerBase64Encoder, CachedImageHandlerJPEGEncoder, CachedImageHandlerPNGEncoder, DefaultCachedImageHandler, SimpleImageHandler

    public interface GenericImageHandler

Extends the default ImageHandler interface with calls to allow caching of raster images in generated SVG content.

Method Summary
`Element` | `createElement(SVGGeneratorContext generatorContext)` Creates an Element suitable for referring to images.
`AffineTransform` | `handleImage(Image image, Element imageElement, int x, int y, int width, int height, SVGGeneratorContext generatorContext)` The handler should set the xlink:href and return a transform
`AffineTransform` | `handleImage(RenderableImage image, Element imageElement, double x, double y, double width, double height, SVGGeneratorContext generatorContext)` The handler should set the xlink:href tag and return a transform
`AffineTransform` | `handleImage(RenderedImage image, Element imageElement, int x, int y, int width, int height, SVGGeneratorContext generatorContext)` The handler should set the xlink:href tag and return a transform
`void` | `setDOMTreeManager(DOMTreeManager domTreeManager)` Sets the DomTreeManager this image handler may need to interact with.

Method Detail

### setDOMTreeManager

    void setDOMTreeManager(DOMTreeManager domTreeManager)

  Sets the DomTreeManager this image handler may need to interact with.

### createElement

    Element createElement(SVGGeneratorContext generatorContext)

  Creates an Element suitable for referring to images. Note that no assumptions can be made about the name of this Element.

### handleImage

    AffineTransform handleImage(Image image,
                                Element imageElement,
                                int x,
                                int y,
                                int width,
                                int height,
                                SVGGeneratorContext generatorContext)

  The handler should set the xlink:href and return a transform

  Parameters:
    `image` - the image under consideration
    `imageElement` - the DOM Element for this image
    `x` - x coordinate
    `y` - y coordinate
    `width` - width for rendering
    `height` - height for rendering
    `generatorContext` - the SVGGeneratorContext
  Returns:
    transform converting the image dimension to rendered dimension

### handleImage

    AffineTransform handleImage(RenderedImage image,
                                Element imageElement,
                                int x,
                                int y,
                                int width,
                                int height,
                                SVGGeneratorContext generatorContext)

  The handler should set the xlink:href tag and return a transform

  Parameters:
    `image` - the image under consideration
    `imageElement` - the DOM Element for this image
    `x` - x coordinate
    `y` - y coordinate
    `width` - width for rendering
    `height` - height for rendering
    `generatorContext` - the SVGGeneratorContext
  Returns:
    transform converting the image dimension to rendered dimension

### handleImage

    AffineTransform handleImage(RenderableImage image,
                                Element imageElement,
                                double x,
                                double y,
                                double width,
                                double height,
                                SVGGeneratorContext generatorContext)

  The handler should set the xlink:href tag and return a transform

  Parameters:
    `image` - the image under consideration
    `imageElement` - the DOM Element for this image
    `x` - x coordinate
    `y` - y coordinate
    `width` - width for rendering
    `height` - height for rendering
    `generatorContext` - the SVGGeneratorContext
  Returns:
    transform converting the image dimension to rendered dimension

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2008 Apache Software Foundation. All Rights Reserved.