View Javadoc

1   package org.springbyexample.util.image;
2   
3   import java.io.File;
4   import java.io.IOException;
5   import java.io.InputStream;
6   import java.io.OutputStream;
7   
8   /**
9    * Image processor.
10   * 
11   * @author David Winterfeldt
12   */
13  public interface ImageProcessor {
14  
15      /**
16       * Gets image width for scaling.
17       */
18      public int getImageScaleWidth();
19      
20      /**
21       * Sets image width for scaling.
22       */
23      public void setImageScaleWidth(int imageScaleWidth);
24          
25      /**
26       * Creates a scaled new file.
27       */
28  	public void scaleImage(File imageFile, File newFile) 
29  			throws IOException;
30  
31      /**
32       * Creates a scaled new file.
33       */
34      public void scaleImage(InputStream in, OutputStream out, String formatName) 
35              throws IOException;
36  
37  }