Package com.itstherules.image

Examples of com.itstherules.image.IImage.save()


    String directory = (String) parameters.get("directory");
    String imageName = (String) parameters.get("image");
    IImage image = new AWTImage(PathResolver.resolve("photos/"+directory+"/"+imageName, PhotosController.class));
    image.rotate(getIntParameter(parameters.get("rotation")));
    image.scale(getIntParameter(parameters.get("width")), getIntParameter(parameters.get("height")), true, true);
    image.save();
    try {
      IImage thumbnailImage = new AWTImage(PathResolver.resolve("photos/"+directory+"/thumbnails/"+imageName, PhotosController.class));
        thumbnailImage.rotate(getIntParameter(parameters.get("rotation")));
        thumbnailImage.save();
    } catch(FileNotFoundException e){
View Full Code Here


    image.scale(getIntParameter(parameters.get("width")), getIntParameter(parameters.get("height")), true, true);
    image.save();
    try {
      IImage thumbnailImage = new AWTImage(PathResolver.resolve("photos/"+directory+"/thumbnails/"+imageName, PhotosController.class));
        thumbnailImage.rotate(getIntParameter(parameters.get("rotation")));
        thumbnailImage.save();
    } catch(FileNotFoundException e){
    }
    PrintWriter writer = response.getWriter();
    writer.write("saved=true");
    writer.close();
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.