クラス RenderedImageFactory


  • public class RenderedImageFactory
    extends Object
    作成者:
    sshaw Factory class for generating RenderedImage objects
    • コンストラクタの概要

      コンストラクタ 
      コンストラクタ 説明
      RenderedImageFactory()  
    • メソッドの概要

      すべてのメソッド staticメソッド concreteメソッド 
      修飾子とタイプ メソッド 説明
      static org.eclipse.gmf.runtime.draw2d.ui.render.RenderInfo createInfo​(int width, int height, boolean maintainAspectRatio, boolean antialias, org.eclipse.swt.graphics.RGB fill, org.eclipse.swt.graphics.RGB outline)
      createInfo static Utility to create a RenderInfo object.
      static org.eclipse.gmf.runtime.draw2d.ui.render.RenderedImage getInstance​(byte[] buffer)
      getInstance static constructor method for retrieving the appropriate instance of the immutable class RenderedImage.
      static org.eclipse.gmf.runtime.draw2d.ui.render.RenderedImage getInstance​(byte[] buffer, org.eclipse.gmf.runtime.draw2d.ui.render.RenderInfo info)
      getInstance static constructor method for retrieving the appropriate instance of the immutable class RenderedImage.
      static org.eclipse.gmf.runtime.draw2d.ui.render.RenderedImage getInstance​(byte[] buffer, org.eclipse.gmf.runtime.draw2d.ui.render.RenderInfo info, String url)
      getInstance static constructor method for retrieving the appropriate instance of the immutable class RenderedImage.
      static org.eclipse.gmf.runtime.draw2d.ui.render.RenderedImage getInstance​(String szFilePath)
      getInstance static constructor method for retrieving the appropriate instance of the immutable class RenderedImage.
      static org.eclipse.gmf.runtime.draw2d.ui.render.RenderedImage getInstance​(String szFilePath, org.eclipse.gmf.runtime.draw2d.ui.render.RenderInfo info)
      getInstance static constructor method for retrieving the appropriate instance of the immutable class RenderedImage.
      static org.eclipse.gmf.runtime.draw2d.ui.render.RenderedImage getInstance​(URL theURL)
      getInstance static constructor method for retrieving the appropriate instance of the immutable class RenderedImage.
      static org.eclipse.gmf.runtime.draw2d.ui.render.RenderedImage getInstance​(URL theURL, org.eclipse.gmf.runtime.draw2d.ui.render.RenderInfo info)
      getInstance static constructor method for retrieving the appropriate instance of the immutable class RenderedImage.
      static org.eclipse.gmf.runtime.draw2d.ui.render.RenderedImage getRelatedInstance​(org.eclipse.gmf.runtime.draw2d.ui.render.RenderedImage image, org.eclipse.gmf.runtime.draw2d.ui.render.RenderInfo info)
      Returns a related instance of the given RenderedImage that is based on the same byte stream or file info but instrumented for the passed in RenderInfo object
    • コンストラクタの詳細

      • RenderedImageFactory

        public RenderedImageFactory()
    • メソッドの詳細

      • createInfo

        public static org.eclipse.gmf.runtime.draw2d.ui.render.RenderInfo createInfo​(int width,
                                                                                     int height,
                                                                                     boolean maintainAspectRatio,
                                                                                     boolean antialias,
                                                                                     org.eclipse.swt.graphics.RGB fill,
                                                                                     org.eclipse.swt.graphics.RGB outline)
        createInfo static Utility to create a RenderInfo object.
        パラメータ:
        width - the width of the rendered image to set
        height - the height of the rendered image to set
        maintainAspectRatio - boolean true if aspect ratio of original vector file is maintained, false otherwise
        antialias - boolean true if the image is to be rendered using anti-aliasing (removing "jaggies" producing smoother lines), false otherwise
        fill - the RGB of the fill that could instrumented into image formats that support dynamic color replacement. Typically, this would replace colors in the image which are "white" i.e. RGB(255,255,255)
        outline - the RGB of the outline that could instrumented into image formats that support dynamic color replacement. Typically, this would replace colors in the image which are "black" i.e. RGB(0,0,0)
        戻り値:
        RenderInfo object that contains information about the rendered image.
      • getInstance

        public static org.eclipse.gmf.runtime.draw2d.ui.render.RenderedImage getInstance​(URL theURL)
        getInstance static constructor method for retrieving the appropriate instance of the immutable class RenderedImage. This method is used to read svg images from JARs.
        パラメータ:
        theURL - URL of the SVG image. Normally in a JAR
        戻り値:
        RenderedImage instance with the size dimensions requested.
      • getInstance

        public static org.eclipse.gmf.runtime.draw2d.ui.render.RenderedImage getInstance​(URL theURL,
                                                                                         org.eclipse.gmf.runtime.draw2d.ui.render.RenderInfo info)
        getInstance static constructor method for retrieving the appropriate instance of the immutable class RenderedImage. This method is used to read svg images from JARs.
        パラメータ:
        theURL - URL of the SVG image.
        info - object containing information about the size and general data regarding how the image will be rendered.
        戻り値:
        RenderedImage instance with the size dimensions requested.
      • getInstance

        public static org.eclipse.gmf.runtime.draw2d.ui.render.RenderedImage getInstance​(byte[] buffer,
                                                                                         org.eclipse.gmf.runtime.draw2d.ui.render.RenderInfo info,
                                                                                         String url)
        getInstance static constructor method for retrieving the appropriate instance of the immutable class RenderedImage.
        パラメータ:
        buffer - byte[] array containing an cached SVG image file.
        info - object containing information about the size and general data regarding how the image will be rendered.
        url - the url of the image (filename url - should be there for SVG, since it may have external references)
        戻り値:
        RenderedImage instance with the size dimensions requested.
        導入されたバージョン:
        2.1
      • getInstance

        public static org.eclipse.gmf.runtime.draw2d.ui.render.RenderedImage getInstance​(String szFilePath)
        getInstance static constructor method for retrieving the appropriate instance of the immutable class RenderedImage.
        パラメータ:
        szFilePath - String file path of svg file
        戻り値:
        RenderedImage instance with the size dimensions requested.
      • getInstance

        public static org.eclipse.gmf.runtime.draw2d.ui.render.RenderedImage getInstance​(String szFilePath,
                                                                                         org.eclipse.gmf.runtime.draw2d.ui.render.RenderInfo info)
        getInstance static constructor method for retrieving the appropriate instance of the immutable class RenderedImage.
        パラメータ:
        szFilePath - String file path of svg file
        info - RenderInfo object containing information about the size and general data regarding how the image will be rendered.
        戻り値:
        RenderedImage instance with the size dimensions requested.
      • getInstance

        public static org.eclipse.gmf.runtime.draw2d.ui.render.RenderedImage getInstance​(byte[] buffer)
        getInstance static constructor method for retrieving the appropriate instance of the immutable class RenderedImage.
        パラメータ:
        buffer - byte[] array containing an cached SVG image file.
        戻り値:
        the RenderedImage that encapsulates the contents of the given byte buffer.
      • getRelatedInstance

        public static org.eclipse.gmf.runtime.draw2d.ui.render.RenderedImage getRelatedInstance​(org.eclipse.gmf.runtime.draw2d.ui.render.RenderedImage image,
                                                                                                org.eclipse.gmf.runtime.draw2d.ui.render.RenderInfo info)
        Returns a related instance of the given RenderedImage that is based on the same byte stream or file info but instrumented for the passed in RenderInfo object
        パラメータ:
        image - RenderedImage that is used as a base to retrieve the related instance.
        info - RenderInfo object containing information about the size and general data regarding how the image will be rendered.
        戻り値:
        RenderedImage instance with the size dimensions requested. May return null if no related instance can be found or if the original buffer cannot be retrieved.
      • getInstance

        public static org.eclipse.gmf.runtime.draw2d.ui.render.RenderedImage getInstance​(byte[] buffer,
                                                                                         org.eclipse.gmf.runtime.draw2d.ui.render.RenderInfo info)
        getInstance static constructor method for retrieving the appropriate instance of the immutable class RenderedImage.
        パラメータ:
        buffer - byte[] array containing an cached SVG image file.
        info - object containing information about the size and general data regarding how the image will be rendered.
        戻り値:
        RenderedImage instance with the size dimensions requested.