resizeImage

session.resizeImageFixWidth( String originalFile, String newFile, int newWidthSize, boolean deleteOriginalFile ) (enterprise edition only)
session.resizeImageFixHeight( String originalFile, String newFile, int newHeightSize, boolean deleteOriginalFile ) (enterprise edition only)
session.resizeImageFixWidthAndHeight( String originalFile, String newFile, int newWidthSize, int newHeightSize, boolean deleteOriginalFile ) (enterprise edition only)
Description
Causes an image file to be resized. Depending on the method that gets invoked the height, width, or both can be fixed. If one of the dimensions is fixed, the aspect ratio of the resulting image will still be retained. The originalFile refers to the existing path on the file system to the image and the newFile is the path to the resized image. The deleteOriginalFile indicates whether or not the original file should be deleted once the image has been resized.
Example
// Resizes a JPG to 100 pixels wide, maintaining the
// aspect ratio. After the image is resized, the original
// will be deleted.
session.resizeImageFixWidth( "C:/my_image.jpg", "C:/my_image_thumbnail.jpg", 100, true );