Documentation of 'org.jhotdraw.samples.svg.io.SVGFigureFactory' Java class
SVGFigureFactory
org.jhotdraw.samples.svg.io

Interface SVGFigureFactory

  • All Known Implementing Classes:
    DefaultSVGFigureFactory


    public interface SVGFigureFactory
    Creates Figures for SVG elements.

    Design pattern:
    Name: Abstract Factory.
    Role: Abstract Factory.
    Partners: SVGInputFormat as Client.

    • Method Detail

      • createRect

        Figure createRect(double x,
                          double y,
                          double width,
                          double height,
                          double rx,
                          double ry,
                          java.util.Map<AttributeKey,java.lang.Object> attributes)
      • createCircle

        Figure createCircle(double cx,
                            double cy,
                            double r,
                            java.util.Map<AttributeKey,java.lang.Object> attributes)
      • createEllipse

        Figure createEllipse(double cx,
                             double cy,
                             double rx,
                             double ry,
                             java.util.Map<AttributeKey,java.lang.Object> attributes)
      • createLine

        Figure createLine(double x1,
                          double y1,
                          double x2,
                          double y2,
                          java.util.Map<AttributeKey,java.lang.Object> attributes)
      • createPolyline

        Figure createPolyline(java.awt.geom.Point2D.Double[] points,
                              java.util.Map<AttributeKey,java.lang.Object> attributes)
      • createPolygon

        Figure createPolygon(java.awt.geom.Point2D.Double[] points,
                             java.util.Map<AttributeKey,java.lang.Object> attributes)
      • createText

        Figure createText(java.awt.geom.Point2D.Double[] coordinates,
                          double[] rotate,
                          javax.swing.text.StyledDocument text,
                          java.util.Map<AttributeKey,java.lang.Object> attributes)
      • createTextArea

        Figure createTextArea(double x,
                              double y,
                              double w,
                              double h,
                              javax.swing.text.StyledDocument doc,
                              java.util.Map<AttributeKey,java.lang.Object> attributes)
      • createImage

        Figure createImage(double x,
                           double y,
                           double width,
                           double height,
                           @Nullable
                           byte[] imageData,
                           @Nullable
                           java.awt.image.BufferedImage bufferedImage,
                           java.util.Map<AttributeKey,java.lang.Object> attributes)
        Creates a Figure from an image element.
        Parameters:
        x - The x coordinate.
        y - The y coordinate.
        width - The width.
        height - The height.
        imageData - Holds the image data. Can be null, if the buffered image has not been created from a file.
        bufferedImage - Holds the buffered image. Can be null, if the image data has not been interpreted.
        attributes - Figure attributes.
      • createLinearGradient

        Gradient createLinearGradient(double x1,
                                      double y1,
                                      double x2,
                                      double y2,
                                      double[] stopOffsets,
                                      java.awt.Color[] stopColors,
                                      double[] stopOpacities,
                                      boolean isRelativeToFigureBounds,
                                      java.awt.geom.AffineTransform tx)
      • createRadialGradient

        Gradient createRadialGradient(double cx,
                                      double cy,
                                      double fx,
                                      double fy,
                                      double r,
                                      double[] stopOffsets,
                                      java.awt.Color[] stopColors,
                                      double[] stopOpacities,
                                      boolean isRelativeToFigureBounds,
                                      java.awt.geom.AffineTransform tx)

DataMelt 3.0 © DataMelt by jWork.ORG

Ads help maintain this website.