com.liferay.portal.kernel.image
Class ImageToolUtil
java.lang.Object
com.liferay.portal.kernel.image.ImageToolUtil
public class ImageToolUtil
- extends Object
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ImageToolUtil
public ImageToolUtil()
convertImageType
public static BufferedImage convertImageType(BufferedImage sourceImage,
int type)
encodeGIF
public static void encodeGIF(RenderedImage renderedImage,
OutputStream os)
throws IOException
- Throws:
IOException
encodeWBMP
public static void encodeWBMP(RenderedImage renderedImage,
OutputStream os)
throws InterruptedException,
IOException
- Throws:
InterruptedException
IOException
getBufferedImage
public static BufferedImage getBufferedImage(RenderedImage renderedImage)
getBytes
public static byte[] getBytes(RenderedImage renderedImage,
String contentType)
throws IOException
- Throws:
IOException
getImageTool
public static ImageTool getImageTool()
read
public static ImageBag read(byte[] bytes)
throws IOException
- Throws:
IOException
read
public static ImageBag read(File file)
throws IOException
- Throws:
IOException
scale
public static RenderedImage scale(RenderedImage renderedImage,
int width)
scale
public static RenderedImage scale(RenderedImage renderedImage,
int maxHeight,
int maxWidth)
write
public static void write(RenderedImage renderedImage,
String contentType,
OutputStream os)
throws IOException
- Throws:
IOException
setImageTool
public void setImageTool(ImageTool imageTool)