![JAR search and dependency download from the Maven repository](/logo.png)
net.sourceforge.plantuml.security.SImageIO Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of plantuml-mit Show documentation
Show all versions of plantuml-mit Show documentation
PlantUML is a component that allows to quickly write diagrams from text.
// THIS FILE HAS BEEN GENERATED BY A PREPROCESSOR.
package net.sourceforge.plantuml.security;
import java.awt.image.BufferedImage;
import java.awt.image.RenderedImage;
import java.io.ByteArrayInputStream;
import java.io.IOException;
import java.io.InputStream;
import java.io.OutputStream;
import java.util.Iterator;
import javax.imageio.ImageReader;
import javax.imageio.ImageWriter;
import javax.imageio.stream.ImageInputStream;
import javax.imageio.stream.ImageOutputStream;
public class SImageIO {
// ::comment when __CORE__
public static ImageOutputStream createImageOutputStream(OutputStream os) throws IOException {
return javax.imageio.ImageIO.createImageOutputStream(os);
}
public static void write(RenderedImage image, String format, OutputStream os) throws IOException {
javax.imageio.ImageIO.write(image, format, os);
}
// ::comment when __CORE__
public static void write(RenderedImage image, String format, SFile file) throws IOException {
javax.imageio.ImageIO.write(image, format, file.conv());
}
public static BufferedImage read(java.io.File file) throws IOException {
return javax.imageio.ImageIO.read(file);
}
public static BufferedImage read(SFile file) throws IOException {
return javax.imageio.ImageIO.read(file.conv());
}
public static BufferedImage read(InputStream is) throws IOException {
return javax.imageio.ImageIO.read(is);
}
public static BufferedImage read(byte[] bytes) throws IOException {
return javax.imageio.ImageIO.read(new ByteArrayInputStream(bytes));
}
// ::comment when __CORE__
public static ImageInputStream createImageInputStream(SFile file) throws IOException {
return javax.imageio.ImageIO.createImageInputStream(file.conv());
}
public static ImageInputStream createImageInputStream(Object obj) throws IOException {
if (obj instanceof SFile)
obj = ((SFile) obj).conv();
return javax.imageio.ImageIO.createImageInputStream(obj);
}
public static ImageInputStream createImageInputStream(InputStream is) throws IOException {
return javax.imageio.ImageIO.createImageInputStream(is);
}
public static Iterator getImageReaders(ImageInputStream iis) {
return javax.imageio.ImageIO.getImageReaders(iis);
}
public static Iterator getImageWritersBySuffix(String string) {
return javax.imageio.ImageIO.getImageWritersBySuffix(string);
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy